summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/modAI.c20
-rw-r--r--src/modules/modPipe.c4
-rw-r--r--src/modules/modTeleport.c16
-rw-r--r--src/modules/modWall.c4
4 files changed, 22 insertions, 22 deletions
diff --git a/src/modules/modAI.c b/src/modules/modAI.c
index 003c65e..67ee594 100644
--- a/src/modules/modAI.c
+++ b/src/modules/modAI.c
@@ -193,7 +193,7 @@ static void eventTuxAI(tux_t * tux)
int x, y, w, h;
int rival_x, rival_y;
- int i, index;
+ int i, my_index;
int countFork = 0;
int countDel = 0;
@@ -225,12 +225,12 @@ static void eventTuxAI(tux_t * tux)
addList(listAlternative, newAlternative(TUX_LEFT, x - (w + 10), y));
addList(listAlternative, newAlternative(TUX_DOWN, x, y + (h + 10)));
- index = -1;
+ my_index = -1;
while (1) {
alternative_t *this;
- index++;
- if (index < 0 || index >= listAlternative->count) {
+ my_index++;
+ if (my_index < 0 || my_index >= listAlternative->count) {
int j;
@@ -242,22 +242,22 @@ static void eventTuxAI(tux_t * tux)
listDoEmpty(listFork);
- index = 0;
+ my_index = 0;
}
if (listAlternative->count == 0) {
break;
}
- this = (alternative_t *) listAlternative->list[index];
+ this = (alternative_t *) listAlternative->list[my_index];
if (++countDo == 100)
break;
if (this->step > 100) {
- delListItem(listAlternative, index, destroyAlternative);
+ delListItem(listAlternative, my_index, destroyAlternative);
countLimit++;
- index--;
+ my_index--;
continue;
}
@@ -276,7 +276,7 @@ static void eventTuxAI(tux_t * tux)
delList(listAlternative, index);
addList(listDst, this);
- index--;
+ my_index--;
//continue;
break;
}
@@ -284,7 +284,7 @@ static void eventTuxAI(tux_t * tux)
if (export_fce->fce_isFreeSpace(arena, this->x, this->y, w, h) == 0) {
//forkAlternative(listFork, this, w*2, h*2);
delListItem(listAlternative, index, destroyAlternative);
- index--;
+ my_index--;
countDel++;
continue;
diff --git a/src/modules/modPipe.c b/src/modules/modPipe.c
index 76554b2..5d1728f 100644
--- a/src/modules/modPipe.c
+++ b/src/modules/modPipe.c
@@ -317,9 +317,9 @@ static void action_eventpipe(space_t * space, pipe_t * pipe, shot_t * shot)
}
static void
-action_eventshot(space_t * space, shot_t * shot, space_t * spacePipe)
+action_eventshot(space_t * space, shot_t * shot, space_t * p_spacePipe)
{
- actionSpaceFromLocation(spacePipe, action_eventpipe, shot, shot->x,
+ actionSpaceFromLocation(p_spacePipe, action_eventpipe, shot, shot->x,
shot->y, shot->w, shot->h);
if (shot->del == TRUE) {
diff --git a/src/modules/modTeleport.c b/src/modules/modTeleport.c
index 492de5b..8f74eca 100644
--- a/src/modules/modTeleport.c
+++ b/src/modules/modTeleport.c
@@ -168,13 +168,13 @@ static void cmd_teleport(char *line)
static teleport_t *getRandomTeleportBut(space_t * space, teleport_t * teleport)
{
- int index;
+ int my_index;
do {
- index = random() % getSpaceCount(space);
- } while (getItemFromSpace(space, index) == teleport);
+ my_index = random() % getSpaceCount(space);
+ } while (getItemFromSpace(space, my_index) == teleport);
- return (teleport_t *) getItemFromSpace(space, index);
+ return (teleport_t *) getItemFromSpace(space, my_index);
}
static int getRandomPosition()
@@ -287,9 +287,9 @@ action_eventteleportshot(space_t * space, teleport_t * teleport, shot_t * shot)
}
static void
-action_eventshot(space_t * space, shot_t * shot, space_t * spaceTeleport)
+action_eventshot(space_t * space, shot_t * shot, space_t * p_spaceTeleport)
{
- actionSpaceFromLocation(spaceTeleport, action_eventteleportshot, shot,
+ actionSpaceFromLocation(p_spaceTeleport, action_eventteleportshot, shot,
shot->x, shot->y, shot->w, shot->h);
}
@@ -300,13 +300,13 @@ action_eventteleporttux(space_t * space, teleport_t * teleport, tux_t * tux)
}
static void
-action_eventtux(space_t * space, tux_t * tux, space_t * spaceTeleport)
+action_eventtux(space_t * space, tux_t * tux, space_t * p_spaceTeleport)
{
int x, y, w, h;
export_fce->fce_getTuxProportion(tux, &x, &y, &w, &h);
- actionSpaceFromLocation(spaceTeleport, action_eventteleporttux, tux, x, y,
+ actionSpaceFromLocation(p_spaceTeleport, action_eventteleporttux, tux, x, y,
w, h);
}
diff --git a/src/modules/modWall.c b/src/modules/modWall.c
index 41b7e04..d3734d5 100644
--- a/src/modules/modWall.c
+++ b/src/modules/modWall.c
@@ -296,9 +296,9 @@ static void action_eventwall(space_t * space, wall_t * wall, shot_t * shot)
}
static void
-action_eventshot(space_t * space, shot_t * shot, space_t * spaceWall)
+action_eventshot(space_t * space, shot_t * shot, space_t * p_spaceWall)
{
- actionSpaceFromLocation(spaceWall, action_eventwall, shot, shot->x,
+ actionSpaceFromLocation(p_spaceWall, action_eventwall, shot, shot->x,
shot->y, shot->w, shot->h);
if (shot->del == TRUE) {