change to setScript() since it does more than update

This commit is contained in:
ZappoMan 2013-12-30 15:55:46 -08:00
parent 8e6f924c73
commit cd11545613
2 changed files with 4 additions and 3 deletions

View file

@ -83,7 +83,7 @@ public:
float getEditedAgo() const { return (float)(usecTimestampNow() - _lastEdited) / (float)USECS_PER_SECOND; }
uint32_t getID() const { return _id; }
bool getShouldDie() const { return _shouldDie; }
QString getUpdateScript() const { return _script; }
QString getScript() const { return _script; }
uint32_t getCreatorTokenID() const { return _creatorTokenID; }
bool isNewlyCreated() const { return _newlyCreated; }
@ -100,7 +100,7 @@ public:
void setInHand(bool inHand) { _inHand = inHand; }
void setDamping(float value) { _damping = value; }
void setShouldDie(bool shouldDie) { _shouldDie = shouldDie; }
void setUpdateScript(QString updateScript) { _script = updateScript; }
void setScript(QString updateScript) { _script = updateScript; }
void setCreatorTokenID(uint32_t creatorTokenID) { _creatorTokenID = creatorTokenID; }
bool appendParticleData(OctreePacketData* packetData) const;
@ -191,6 +191,7 @@ public slots:
void setColor(xColor value) { _particle->setColor(value); }
void setRadius(float value) { _particle->setRadius(value); }
void setShouldDie(bool value) { _particle->setShouldDie(value); }
void setScript(const QString& script) { _particle->setScript(script); }
signals:
void update();

View file

@ -227,7 +227,7 @@ void ParticleCollisionSystem::applyHardCollision(Particle* particle, const glm::
ParticleEditHandle particleEditHandle(_packetSender, _particles, particle->getID());
particleEditHandle.updateParticle(position, particle->getRadius(), particle->getXColor(), velocity,
particle->getGravity(), particle->getDamping(), particle->getInHand(), particle->getUpdateScript());
particle->getGravity(), particle->getDamping(), particle->getInHand(), particle->getScript());
}