Subversion Repository Public Repository

Divide-Framework

This repository has no backups
This repository's network speed is throttled to 100KB/sec

Diff Revisions 630 vs 631 for /trunk/Source Code/Dynamics/Entities/Particles/ConcreteUpdaters/ParticleAttractorUpdater.cpp

Diff revisions: vs.
  @@ -2,8 +2,8 @@
2 2
3 3 namespace Divide {
4 4
5 - void ParticleAttractorUpdater::update(const U64 deltaTime, std::shared_ptr<ParticleData> p) {
6 - const U32 endID = p->aliveCount();
5 + void ParticleAttractorUpdater::update(const U64 deltaTime, ParticleData& p) {
6 + const U32 endID = p.aliveCount();
7 7 const vectorAlg::vecSize countAttractors = _attractors.size();
8 8
9 9 vec4<F32> offset;
  @@ -11,12 +11,12 @@
11 11 vectorAlg::vecSize a = 0;
12 12 for (U32 i = 0; i < endID; ++i) {
13 13 for (a = 0; a < countAttractors; ++a) {
14 - offset.set(_attractors[a].xyz() - p->_position[i].xyz(), 0.0f);
14 + offset.set(_attractors[a].xyz() - p._position[i].xyz(), 0.0f);
15 15 dist = offset.dot(offset);
16 16
17 17 // if (!IS_ZERO(DIST)) {
18 18 dist = _attractors[a].w / dist;
19 - p->_acceleration[i] += offset * dist;
19 + p._acceleration[i] += offset * dist;
20 20 //}
21 21 }
22 22 }