projects
/
physics.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
refactored effectManager
[physics.git]
/
src
/
effectManager.cpp
diff --git
a/src/effectManager.cpp
b/src/effectManager.cpp
index
a75e5d8
..
c11ffc3
100644
(file)
--- a/
src/effectManager.cpp
+++ b/
src/effectManager.cpp
@@
-33,13
+33,13
@@
typedef std::set<Effect*> setEffect;
setEffect active_Effects;
typedef std::set<Effect*> setEffect;
setEffect active_Effects;
-GravityWell*
m
ouseWell;
+GravityWell*
pM
ouseWell;
/// ***** Initializers/Cleaners *****
void effect::init()
{
/// ***** Initializers/Cleaners *****
void effect::init()
{
-
m
ouseWell = new GravityWell(Vector2(0,0));
+
pM
ouseWell = new GravityWell(Vector2(0,0));
active_Effects.insert(new Screen());
active_Effects.insert(new Gravity());
active_Effects.insert(new Screen());
active_Effects.insert(new Gravity());
@@
-63,15
+63,15
@@
void effect::update(float)
void effect::handleInput()
{
if(cfg::mouseWellFollow())
void effect::handleInput()
{
if(cfg::mouseWellFollow())
-
m
ouseWell->setPosition(input::mousePosition());
+
pM
ouseWell->setPosition(input::mousePosition());
if(cfg::mouseWellOn())
if(cfg::mouseWellOn())
- active_Effects.insert(
m
ouseWell);
+ active_Effects.insert(
pM
ouseWell);
if(cfg::mouseWellOff())
if(cfg::mouseWellOff())
- active_Effects.erase(
m
ouseWell);
+ active_Effects.erase(
pM
ouseWell);
}
}
-Vector2 effect::positionDelta(const PhysicsEntity*
e, float time_s
tep)
+Vector2 effect::positionDelta(const PhysicsEntity*
ppe, float fTimeS
tep)
{
Vector2 acc(0,0);
{
Vector2 acc(0,0);
@@
-79,12
+79,12
@@
Vector2 effect::positionDelta(const PhysicsEntity* e, float time_step)
it != active_Effects.end();
it++ )
{
it != active_Effects.end();
it++ )
{
- acc += (*it)->positionDelta(
e, time_s
tep);
+ acc += (*it)->positionDelta(
ppe, fTimeS
tep);
}
return acc;
}
}
return acc;
}
-Vector2 effect::velocityDelta(const PhysicsEntity*
e, float time_s
tep)
+Vector2 effect::velocityDelta(const PhysicsEntity*
ppe, float fTimeS
tep)
{
Vector2 acc(0,0);
{
Vector2 acc(0,0);
@@
-92,12
+92,12
@@
Vector2 effect::velocityDelta(const PhysicsEntity* e, float time_step)
it != active_Effects.end();
it++ )
{
it != active_Effects.end();
it++ )
{
- acc += (*it)->velocityDelta(
e, time_s
tep);
+ acc += (*it)->velocityDelta(
ppe, fTimeS
tep);
}
return acc;
}
}
return acc;
}
-Vector2 effect::forceDelta(const PhysicsEntity*
e, float time_s
tep)
+Vector2 effect::forceDelta(const PhysicsEntity*
ppe, float fTimeS
tep)
{
Vector2 acc(0,0);
{
Vector2 acc(0,0);
@@
-105,7
+105,7
@@
Vector2 effect::forceDelta(const PhysicsEntity* e, float time_step)
it != active_Effects.end();
it++ )
{
it != active_Effects.end();
it++ )
{
- acc += (*it)->forceDelta(
e, time_s
tep);
+ acc += (*it)->forceDelta(
ppe, fTimeS
tep);
}
return acc;
}
return acc;