Resolves spawn direction not saving at relog (#7210)

* Fixes #7195.
* Adds a new save field for battle config spawn_direction which was not working for players who log out and in.
Thanks to @SapitoSucio and @Lemongrass3110!
This commit is contained in:
Aleos
2022-08-30 12:50:50 -04:00
committed by GitHub
parent 329158ac93
commit a2ce09fd56
7 changed files with 42 additions and 24 deletions

View File

@@ -11045,6 +11045,10 @@ void clif_parse_LoadEndAck(int fd,struct map_session_data *sd)
//Login Event
npc_script_event(sd, NPCE_LOGIN);
}
// Set facing direction before check below to update client
if (battle_config.spawn_direction)
unit_setdir(&sd->bl, sd->status.body_direction, false);
} else {
//For some reason the client "loses" these on warp/map-change.
clif_updatestatus(sd,SP_STR);