egs_game: Remove the instancepid when aborting the mission.

This commit is contained in:
Loïc Hoguin 2010-09-26 16:27:51 +02:00
parent 0bfc07da65
commit 000b171567

View File

@ -434,7 +434,7 @@ event(mission_abort, State=#state{gid=GID}) ->
Character = User#egs_user_model.character,
MaxHP = Character#characters.maxhp,
NewCharacter = Character#characters{currenthp=MaxHP},
NewUser = User#egs_user_model{character=NewCharacter, setid=0},
NewUser = User#egs_user_model{character=NewCharacter, setid=0, instancepid=undefined},
egs_user_model:write(NewUser),
%% map change
if User#egs_user_model.areatype =:= mission ->