summaryrefslogtreecommitdiff
path: root/src/simulation
diff options
context:
space:
mode:
Diffstat (limited to 'src/simulation')
-rw-r--r--src/simulation/Simulation.h2
-rw-r--r--src/simulation/elements/DMG.cpp4
2 files changed, 2 insertions, 4 deletions
diff --git a/src/simulation/Simulation.h b/src/simulation/Simulation.h
index 98c5025..9cdd3a7 100644
--- a/src/simulation/Simulation.h
+++ b/src/simulation/Simulation.h
@@ -117,10 +117,8 @@ public:
int pretty_powder;
int sandcolour;
int sandcolour_frame;
- static int loverule[9][9];
bool ISLOVE;
int love[XRES/9][YRES/9];
- static int lolzrule[9][9];
bool ISLOLZ;
int lolz[XRES/9][YRES/9];
diff --git a/src/simulation/elements/DMG.cpp b/src/simulation/elements/DMG.cpp
index 2e755d9..9c19199 100644
--- a/src/simulation/elements/DMG.cpp
+++ b/src/simulation/elements/DMG.cpp
@@ -67,13 +67,13 @@ int Element_DMG::update(UPDATE_FUNC_ARGS)
for (nxi=-rad; nxi<=rad; nxi++)
if (x+nxi>=0 && y+nxj>=0 && x+nxi<XRES && y+nxj<YRES && (nxi || nxj))
{
- dist = sqrt(pow(nxi, 2)+pow(nxj, 2));//;(pow((float)nxi,2))/(pow((float)rad,2))+(pow((float)nxj,2))/(pow((float)rad,2));
+ dist = sqrt(pow(nxi, 2.0f)+pow(nxj, 2.0f));//;(pow((float)nxi,2))/(pow((float)rad,2))+(pow((float)nxj,2))/(pow((float)rad,2));
if (!dist || (dist <= rad))
{
rr = pmap[y+nxj][x+nxi];
if (rr)
{
- angle = atan2(nxj, nxi);
+ angle = atan2((float)nxj, nxi);
fx = cos(angle) * 7.0f;
fy = sin(angle) * 7.0f;