bugfix: when falling on to a trampoline from the side, player would suddenly teleport off the top of the screen.
This commit is contained in:
parent
61ce57d134
commit
f14d276c3a
Binary file not shown.
12
rc.c
12
rc.c
|
@ -6880,7 +6880,7 @@ void dotileeffects(sprite_t *s) {
|
|||
tiletype_t *tt;
|
||||
int finished = B_FALSE;
|
||||
int state = 0;
|
||||
int tilex,tiley;
|
||||
int tilex,tiley,checkingx = 0, checkingy = 0;
|
||||
|
||||
if (!s) return;
|
||||
|
||||
|
@ -6959,6 +6959,10 @@ void dotileeffects(sprite_t *s) {
|
|||
tt = gettileat(s->x,s->y+3,&tilex,&tiley);
|
||||
}
|
||||
|
||||
// remember the exact x/y location we're checking.
|
||||
checkingx = s->x;
|
||||
checkingy = s->y+3;
|
||||
|
||||
// CHECKS WHICH COULD APPLY TO TILES UNDER AND SLIGHTLY LEFT/RIGHT OF US
|
||||
while (!finished) {
|
||||
if (tt->id == T_RIGHT) {
|
||||
|
@ -7051,7 +7055,7 @@ void dotileeffects(sprite_t *s) {
|
|||
|
||||
// move player to new trampoline height
|
||||
tt = gettile(T_TRAMPDOWN);
|
||||
xoff = s->x - (tilex*TILEW);
|
||||
xoff = checkingx - (tilex*TILEW);
|
||||
s->y = (tiley * TILEH) + tt->lowness[xoff];
|
||||
}
|
||||
}
|
||||
|
@ -7063,10 +7067,14 @@ void dotileeffects(sprite_t *s) {
|
|||
if (state == 0) {
|
||||
/* check tile to our right */
|
||||
tt = gettileat(s->x + s->img->w/2,s->y+3,&tilex,&tiley);
|
||||
checkingx = s->x + s->img->w/2;
|
||||
checkingy = s->y+3;
|
||||
state = 1;
|
||||
} else if (state == 1) {
|
||||
/* check tile to our left */
|
||||
tt = gettileat(s->x - s->img->w/2,s->y+3,&tilex,&tiley);
|
||||
checkingx = s->x - s->img->w/2;
|
||||
checkingy = s->y+3;
|
||||
state = 2;
|
||||
} else {
|
||||
finished = B_TRUE;
|
||||
|
|
8
todo
8
todo
|
@ -1,10 +1,5 @@
|
|||
- move level 86 earlier (dificulty easier than other castle levels before it)
|
||||
|
||||
- animate players hanging from umbrellas ?
|
||||
|
||||
- sometimes when falling on to a trampoline at an angle, I teleport up to the top of the screen.
|
||||
|
||||
|
||||
- make points worth chasing for something more than a high schore
|
||||
- bonus level teleport appears on next level once you
|
||||
reach a certain amount of points ?
|
||||
|
@ -115,6 +110,8 @@
|
|||
although the rest of the level is pretty easy.
|
||||
maybe move it slightly later
|
||||
|
||||
l 86 - earlier (dificulty easier than other castle levels before it)
|
||||
|
||||
- New tiles
|
||||
- destroyable tile
|
||||
- when a net hits it, it explodes into 4 pieces. don't come back.
|
||||
|
@ -123,6 +120,7 @@
|
|||
- only worth doing if i add lots of tese kind of tiles.
|
||||
- same if you SLAM onto it.
|
||||
- Tapestry (castle)
|
||||
|
||||
|
||||
- falling icicle (regrows)
|
||||
|
||||
|
|
Loading…
Reference in New Issue