Glue is even better. Glue, the Game™
This commit is contained in:
parent
80df629371
commit
3d2221ffec
|
@ -27,10 +27,19 @@ void player_mod_glue(Player *player, uint8_t sides) {
|
|||
player->vars.acceleration = 1;
|
||||
player->vars.friction = 1;
|
||||
}
|
||||
if (sides & (D_LEFT | D_RIGHT | D_CEIL)) {
|
||||
if (sides & D_CEIL) {
|
||||
player->spd.y = 0;
|
||||
player->vars.gravity = 0;
|
||||
player->vars.friction *= 2;
|
||||
/* jump to drop of the ceiling */
|
||||
player->vars.jump_spd = 1;
|
||||
player->grace = 1;
|
||||
}
|
||||
if (sides & (D_LEFT | D_RIGHT)) {
|
||||
player->spd.y = 0;
|
||||
player->vars.gravity = 0;
|
||||
/* wall jump */
|
||||
player->grace = UPS / 5;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Reference in New Issue