FaceTarget()
Posted: Sat Mar 21, 2020 11:54 am
Found that a spawn will not fact target after the spawn faced another npc. Here is part of the lua so hopefully it will make more sense.
In the Function TalkToCaptainVarlos(NPC, Spawn) I have to have the Captain face Ingrid and using the FaceTarget(NPC, Ingrid) does in fact work. The issue is after their interaction the Captain turns and faces the player. Which I would think that the FaceTarget(NPC, Spawn) in the function IngridLeaveCaptain(NPC, Spawn) would work, but it is not working.
Here is the function SaluteCaptainVarlos(NPC, Spawn) in Ingrids spawn script
Code: Select all
function TalkToCaptainVarlos(NPC, Spawn)
local Ingrid = GetSpawn(NPC, 270001)
FaceTarget(NPC, Ingrid)
PlayFlavor(NPC, "voiceover/english/captain_varlos/boat_06p_tutorial02_fvo_007.mp3", "Don't want the ship to come apart in these high winds, do ya'?!", "scold", 517097409, 4194681002, Spawn)
AddTimer(Ingrid, 4000, "SaluteCaptainVarlos", 1, Spawn)
end
function IngridLeaveCaptain(NPC, Spawn)
FaceTarget(NPC, Spawn)
PlayFlavor(NPC, "voiceover/english/captain_varlos/boat_06p_tutorial02_fvo_008.mp3", "Ya think she'd never seen a gnome afore.", "", 2447879193, 4289147535, Spawn)
AddTimer(NPC, 3000, "ShakeCamera_1", 1, Spawn)
AddTimer(NPC, 4000, "TheQuestOffer")
end
Here is the function SaluteCaptainVarlos(NPC, Spawn) in Ingrids spawn script
Code: Select all
function SaluteCaptainVarlos(NPC, Spawn)
local Varlos = GetSpawn(NPC, 270000)
PlayFlavor(NPC, "voiceover/english/ingrid/boat_06p_tutorial02/020_deckhand_ingrid_010_1637e047.mp3", "Aye, aye, Captain!", "salute", 1250282628, 237171958, Spawn)
AddTimer(Varlos, 3000, "IngridLeaveCaptain", 1, Spawn)
AddTimer(NPC, 2000, "ReturnToSpawnPoint", 1, Spawn)
end