Help with my Activator Script

Post » Mon Jun 18, 2012 12:16 pm

Hey all, It's me again with another Papyrus-related question :smile:

Its do do with controlling a cart in-game for a mod I'm working on;
I have created a trigger zone, and attached the following script to it:
Scriptname ZZCarriageWindhelmTriggerZoneScript extends ObjectReferenceFaction Property ZZAnimatedCarriageFaction  AutoQuest Property ZZAnimatedCartsControler  AutoTopic Property ZZAnimatedCartsArrivalTopic  AutoImport UtilityEvent OnTriggerEnter(ObjectReference triggerRef)if (triggerRef as Actor).IsInFaction(ZZAnimatedCarriageFaction)  (triggerRef as Actor).Say ZZAnimatedCartsArrivalSpeech  game.GetPlayer().PlayIdle(IdleCartPrisonerCExit)  Utility.Wait(10)  game.GetPlayer().setVehicle(None)  game.EnablePlayerControls()  Utility.Wait(7)  (triggerRef as Actor).SetFactionRank(ZZAnimatedCarriageFaction, 0)endifendEventIdle Property IdleCartPrisonerCExit  Auto

Basically, when the Driver gets into the trigger zone, it should play the player animation to get off the cart, pause to wait for the animation to finish, enable player controls, pause again for a while, and then set the Driver's faction rank to 0 (I'm using the rank to execute different packages based on conditions).

My problem is, the code will work as long as I comment out "(triggerRef as Actor).Say ZZAnimatedCartsArrivalSpeech". If not; I get the following compile error:
Starting 1 compile threads for 1 files...Compiling "ZZCarriageWindhelmTriggerZoneScript"...f:\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\ZZCarriageWindhelmTriggerZoneScript.psc(14,24): no viable alternative at input 'Say'No output generated for ZZCarriageWindhelmTriggerZoneScript, compilation failed.Batch compile of 1 files finished. 0 succeeded, 1 failed.Failed on ZZCarriageWindhelmTriggerZoneScript

What that is supposed to do is make the Driver tell the player "We have arrived". ZZAnimatedCartsArrivalSpeech is the TopicID, so I'm not sure why it dosen't work. Any ideas?
Thanks :smile:
User avatar
Céline Rémy
 
Posts: 3443
Joined: Sat Apr 07, 2007 12:45 am

Post » Tue Jun 19, 2012 4:24 am

http://www.creationkit.com/Say is a console command, and as such cannot be used in Papyrus.

I don't know if there's a Papyrus equivalent, however. You might have to use an AI package to get them to say what you want.

Cipscis
User avatar
Danger Mouse
 
Posts: 3393
Joined: Sat Oct 07, 2006 9:55 am

Post » Tue Jun 19, 2012 2:07 am

Ah okay then; thanks for clearing that up, I'll use a force greet package instead :)
User avatar
Riky Carrasco
 
Posts: 3429
Joined: Tue Nov 06, 2007 12:17 am


Return to V - Skyrim