void fnJump(object oDest) { object oMe=OBJECT_SELF; if (GetArea(oDest)!=GetArea(oMe)||GetDistanceBetween(oMe,oDest)>3.0) { // move AssignCommand(oMe,JumpToObject(oDest)); DelayCommand(0.5,fnJump(oDest)); } // move } // fnJump() void main() { object oPC=GetPCSpeaker(); object oWP=GetWaypointByTag("AGERNIS_EXIT"); AssignCommand(oPC,fnJump(oWP)); }