Code: |
//Sur le "Script déclenché par l'ouverture" de la porte
void main() { object oPJ = GetLastUsedBy(); object oHenchman = GetHenchman(oPJ); object oFamilier = GetAssociate(ASSOCIATE_TYPE_FAMILIAR, oPJ); object oInvocation = GetAssociate(ASSOCIATE_TYPE_SUMMONED, oPJ); object oAnimal = GetAssociate(ASSOCIATE_TYPE_ANIMALCOMPANION, oPJ); object oDominer = GetAssociate(ASSOCIATE_TYPE_DOMINATED, oPJ); object oCible = GetNearestObjectByTag(GetLocalString(OBJECT_SELF, "cible")); //Variable "cible" sur la porte (définit le point de destination) location lTarget = GetLocation(oCible); AssignCommand(oPJ, JumpToLocation(lTarget)); AssignCommand(oHenchman, JumpToLocation(lTarget)); AssignCommand(oFamilier, JumpToLocation(lTarget)); AssignCommand(oInvocation, JumpToLocation(lTarget)); AssignCommand(oAnimal, JumpToLocation(lTarget)); AssignCommand(oDominer, JumpToLocation(lTarget)); DelayCommand(5.0, ActionCloseDoor(OBJECT_SELF)); } |
Code: |
// Get the destination (a waypoint or a door) for a trigger or a door.
// * Returns OBJECT_INVALID if oTransition is not a valid trigger or door. object GetTransitionTarget(object oTransition); |