Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
mmatyas committed Sep 16, 2024
1 parent 018a294 commit cb8eb3b
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/smw/objects/overmap/WO_OrbitHazard.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ OMO_OrbitHazard::OMO_OrbitHazard(gfxSprite* nspr, Vec2s pos, float radius, float
dRadius = radius;
dVel = vel;
dAngle = angle;
dCenter = {pos.x, pos.y};
dCenter = Vec2f(pos.x, pos.y);

CalculatePosition();
}
Expand Down
14 changes: 7 additions & 7 deletions src/smw/player.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1375,10 +1375,10 @@ void CPlayer::CommitAction()
{
if (PlayerAction::Bobomb == action) {
bobomb = false;
objectcontainer[2].add(new MO_Explosion(&rm->spr_explosion, {ix + HALFPW - 96, iy + HALFPH - 64}, 2, 4, globalID, teamID, KillStyle::Bobomb));
objectcontainer[2].add(new MO_Explosion(&rm->spr_explosion, Vec2s(ix + HALFPW - 96, iy + HALFPH - 64), 2, 4, globalID, teamID, KillStyle::Bobomb));
ifSoundOnPlay(rm->sfx_bobombsound);
} else if (PlayerAction::Fireball == action) {
objectcontainer[0].add(new MO_Fireball(&rm->spr_fireball, {ix + 6, iy}, 4, isFacingRight(), 5, globalID, teamID, colorID));
objectcontainer[0].add(new MO_Fireball(&rm->spr_fireball, Vec2s(ix + 6, iy), 4, isFacingRight(), 5, globalID, teamID, colorID));
ifSoundOnPlay(rm->sfx_fireball);

projectiles++;
Expand All @@ -1387,9 +1387,9 @@ void CPlayer::CommitAction()
DecreaseProjectileLimit();
} else if (PlayerAction::Hammer == action) {
if (isFacingRight()) {
objectcontainer[2].add(new MO_Hammer(&rm->spr_hammer, {ix + 8, iy}, 6, {(game_values.reversewalk ? -velx : velx) + 2.0f, -HAMMERTHROW}, 5, globalID, teamID, colorID, false));
objectcontainer[2].add(new MO_Hammer(&rm->spr_hammer, Vec2s(ix + 8, iy), 6, {(game_values.reversewalk ? -velx : velx) + 2.0f, -HAMMERTHROW}, 5, globalID, teamID, colorID, false));
} else {
objectcontainer[2].add(new MO_Hammer(&rm->spr_hammer, {ix - 14, iy}, 6, {(game_values.reversewalk ? -velx : velx) - 2.0f, -HAMMERTHROW}, 5, globalID, teamID, colorID, false));
objectcontainer[2].add(new MO_Hammer(&rm->spr_hammer, Vec2s(ix - 14, iy), 6, {(game_values.reversewalk ? -velx : velx) - 2.0f, -HAMMERTHROW}, 5, globalID, teamID, colorID, false));
}
projectiles++;

Expand All @@ -1399,16 +1399,16 @@ void CPlayer::CommitAction()
if (game_values.hammerlimit > 0)
DecreaseProjectileLimit();
} else if (PlayerAction::Boomerang == action) {
objectcontainer[2].add(new MO_Boomerang(&rm->spr_boomerang, {ix, iy + HALFPH - 16}, 4, isFacingRight(), 5, globalID, teamID, colorID));
objectcontainer[2].add(new MO_Boomerang(&rm->spr_boomerang, Vec2s(ix, iy + HALFPH - 16), 4, isFacingRight(), 5, globalID, teamID, colorID));
projectiles++;

if (game_values.boomeranglimit > 0)
DecreaseProjectileLimit();
} else if (PlayerAction::Iceblast == action) {
if (isFacingRight())
objectcontainer[2].add(new MO_IceBlast(&rm->spr_iceblast, {ix + HALFPW - 2, iy + HALFPH - 16}, 5.0f, globalID, teamID, colorID));
objectcontainer[2].add(new MO_IceBlast(&rm->spr_iceblast, Vec2s(ix + HALFPW - 2, iy + HALFPH - 16), 5.0f, globalID, teamID, colorID));
else
objectcontainer[2].add(new MO_IceBlast(&rm->spr_iceblast, {ix + HALFPW - 30, iy + HALFPH - 16}, -5.0f, globalID, teamID, colorID));
objectcontainer[2].add(new MO_IceBlast(&rm->spr_iceblast, Vec2s(ix + HALFPW - 30, iy + HALFPH - 16), -5.0f, globalID, teamID, colorID));

projectiles++;

Expand Down
4 changes: 2 additions & 2 deletions src/smw/player_components/PlayerSuperStomp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ void PlayerSuperStomp::update_onGroundHit(CPlayer &player)
ifSoundOnPlay(rm->sfx_bobombsound);
is_stomping = false;

objectcontainer[1].add(new MO_AttackZone(player.getGlobalID(), player.getTeamID(), {player.leftX() - 32, player.topY() + 10}, {32, 15}, 8, KillStyle::KuriboShoe, false));
objectcontainer[1].add(new MO_AttackZone(player.getGlobalID(), player.getTeamID(), {player.rightX(), player.topY() + 10}, {32, 15}, 8, KillStyle::KuriboShoe, false));
objectcontainer[1].add(new MO_AttackZone(player.getGlobalID(), player.getTeamID(), Vec2s(player.leftX() - 32, player.topY() + 10), {32, 15}, 8, KillStyle::KuriboShoe, false));
objectcontainer[1].add(new MO_AttackZone(player.getGlobalID(), player.getTeamID(), Vec2s(player.rightX(), player.topY() + 10), {32, 15}, 8, KillStyle::KuriboShoe, false));
}
}

Expand Down

0 comments on commit cb8eb3b

Please sign in to comment.