summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
authorgumi <git@gumi.ca>2018-02-17 12:16:54 -0500
committergumi <git@gumi.ca>2018-02-17 12:16:54 -0500
commitc7131cd6818c762a8deb740db40bf1b579f5abee (patch)
treef64e0ddedba38d6d52c7b05ccec904c1cfd69341 /src/map
parent6f999732ba46c8c1ba413a1ee0f54de63a8a051e (diff)
downloadtmwa-c7131cd6818c762a8deb740db40bf1b579f5abee.tar.gz
tmwa-c7131cd6818c762a8deb740db40bf1b579f5abee.tar.bz2
tmwa-c7131cd6818c762a8deb740db40bf1b579f5abee.tar.xz
tmwa-c7131cd6818c762a8deb740db40bf1b579f5abee.zip
fix player facing the wrong direction on magic attacks
Diffstat (limited to 'src/map')
-rw-r--r--src/map/pc.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/map/pc.cpp b/src/map/pc.cpp
index 3784566..e4c3907 100644
--- a/src/map/pc.cpp
+++ b/src/map/pc.cpp
@@ -2653,6 +2653,12 @@ void pc_attack_timer(TimerData *, tick_t tick, BlockId id)
if (sd->attack_spell_override) // [Fate] If we have an active attack spell, use that
{
+ if (battle_config.player_attack_direction_change)
+ sd->dir = sd->head_dir = map_calc_dir(sd, bl->bl_x, bl->bl_y);
+
+ if (sd->walktimer)
+ pc_stop_walking(sd, 1);
+
// call_spell_event_script
argrec_t arg[1] =
{