Jump to content

Quick Questions, Quick Answers


Mattiewagg

Recommended Posts

 

 

Is it possible to add multiple If statements? For example, if I wanted to check if the final Civil War quest had been completed, as well as check the player's allegiance, I'd write something like this:

 

 

If BattleForSolitude.GetStageDone(9000) Game.GetAllegiance(Sons)

BannerStorm.Enable()

endIf

 

 

Would this work? Obviously the GetAllegiance part is bogus, I'm still working on that.

You'd use a logical AND.

If BattleForSolitude.GetStageDone(9000) && Game.GetAllegiance(Sons)

     BannerStorm.Enable()

EndIf

Oh, alright. Didn't see anything about that on the wiki; thanks a lot!

 

By the way, is there a way to reference conditionals without having to meddle with quests and such. I just need to create a trigger where, if the player sided with the Imperials or Stormcloaks, the script would enable an ObjectReference and then delete itself. I thought the quest lines would be split up in separate groups, but they apparently all operate on one quest entry with a conditional check instead.

 

Is there an easier way to do this?

 

EDIT

 

I think I found something in the main Civil War scripts.

 

int property playerAllegiance auto conditional Hidden

 

int playerAllegianceVar

int Property playerAllegiance Hidden

function set(int value)

debug.tracestack("*playerAllegiance = "+value)

playerAllegianceVar = value

EndFunction

int function get()

return playerAllegianceVar

EndFunction

EndProperty

 

 

If this returns 1, it means the player is sided with the Empire. So if playerAllegianceVar = 1 then I'll enable the Imperial banner.

I'll fiddle with this and come back with results.

 

Yep. I was just going to mention playerAllegiance.

Link to comment
Share on other sites

  • Replies 2.6k
  • Created
  • Last Reply

Top Posters In This Topic

I know someone knows how to do this:

 

Have a trigger that activates a load door on trigger enter and passes the akActionRef in as the activating actor to the <DoorRef>.Activate(actor akActionRef) function.

 

My intent is to make entering the trigger essentially be identical to that actor activating the door by hand.

 

Anyone know why my PC isn't getting teleported when the door is activated (it is activating because I can hear the door opening outside of the map?

Edited by DesertEaglePWN
Link to comment
Share on other sites

I know someone knows how to do this:

 

Have a trigger that activates a load door on trigger enter and passes the akActionRef in as the activating actor to the <DoorRef>.Activate(actor akActionRef) function.

 

My intent is to make entering the trigger essentially be identical to that actor activating the door by hand.

 

Anyone know why my PC isn't getting teleported when the door is activated (it is activating because I can hear the door opening outside of the map?

Could you show the script you currently have?

 

This should work:

ObjectReference Property DoorREF Auto 

Event OnTriggerEnter(ObjectReference akActionRef)

	PlayerREF.Activate(DoorREF)

EndEvent
Link to comment
Share on other sites

 

I know someone knows how to do this:

 

Have a trigger that activates a load door on trigger enter and passes the akActionRef in as the activating actor to the <DoorRef>.Activate(ObjectReference akActionRef) function.

 

My intent is to make entering the trigger essentially be identical to that actor activating the door by hand.

 

Anyone know why my PC isn't getting teleported when the door is activated (it is activating because I can hear the door opening outside of the map?

Could you show the script you currently have?

 

This should work:

ObjectReference Property DoorREF Auto 

Event OnTriggerEnter(ObjectReference akActionRef)

	PlayerREF.Activate(DoorREF)

EndEvent

 

Here is what I have, it's on a defaultActivateSelf trigger ( along with it's default script that activates itself on Player or Player Ally Enter)

Scriptname MOD1TeleportToCellOnActivate extends ObjectReference

Event OnActivate(ObjectReference akActionRef)
TeleportDoor.Activate(akActionRef);
EndEvent
ObjectReference Property DragonsRestSanctumTeleportMarker Auto; Unused
ObjectReference Property TeleportDoor Auto
While I might could make do with only the player activating it, it'd be better if I could have followers be able to activate the trigger as well (without followers forcing the player to teleport -- which that script could do)
Edited by DesertEaglePWN
Link to comment
Share on other sites

 

 

I know someone knows how to do this:

 

Have a trigger that activates a load door on trigger enter and passes the akActionRef in as the activating actor to the <DoorRef>.Activate(ObjectReference akActionRef) function.

 

My intent is to make entering the trigger essentially be identical to that actor activating the door by hand.

 

Anyone know why my PC isn't getting teleported when the door is activated (it is activating because I can hear the door opening outside of the map?

Could you show the script you currently have?

 

This should work:

ObjectReference Property DoorREF Auto 

Event OnTriggerEnter(ObjectReference akActionRef)

	PlayerREF.Activate(DoorREF)

EndEvent

 

Here is what I have, it's on a defaultActivateSelf trigger ( along with it's default script that activates itself on Player or Player Ally Enter)

Scriptname MOD1TeleportToCellOnActivate extends ObjectReference

Event OnActivate(ObjectReference akActionRef)
TeleportDoor.Activate(akActionRef);
EndEvent
ObjectReference Property DragonsRestSanctumTeleportMarker Auto; Unused
ObjectReference Property TeleportDoor Auto
While I might could make do with only the player activating it, it'd be better if I could have followers be able to activate the trigger as well (without followers forcing the player to teleport -- which that script could do)

 

I was under the impression it was YourActionRef.Activate(TeleportDoor). Try it that way.

 

And just remove PlayerREF and replace it with akActionRef, then.

Link to comment
Share on other sites

 

 

 

I know someone knows how to do this:

 

Have a trigger that activates a load door on trigger enter and passes the akActionRef in as the activating actor to the <DoorRef>.Activate(ObjectReference akActionRef) function.

 

My intent is to make entering the trigger essentially be identical to that actor activating the door by hand.

 

Anyone know why my PC isn't getting teleported when the door is activated (it is activating because I can hear the door opening outside of the map?

Could you show the script you currently have?

 

This should work:

ObjectReference Property DoorREF Auto 

Event OnTriggerEnter(ObjectReference akActionRef)

	PlayerREF.Activate(DoorREF)

EndEvent

 

Here is what I have, it's on a defaultActivateSelf trigger ( along with it's default script that activates itself on Player or Player Ally Enter)

Scriptname MOD1TeleportToCellOnActivate extends ObjectReference

Event OnActivate(ObjectReference akActionRef)
TeleportDoor.Activate(akActionRef);
EndEvent
ObjectReference Property DragonsRestSanctumTeleportMarker Auto; Unused
ObjectReference Property TeleportDoor Auto
While I might could make do with only the player activating it, it'd be better if I could have followers be able to activate the trigger as well (without followers forcing the player to teleport -- which that script could do)

 

I was under the impression it was YourActionRef.Activate(TeleportDoor). Try it that way.

 

And just remove PlayerREF and replace it with akActionRef, then.

 

Just tested it. Not working. Door doesn't open anymore. Investigating more about the Activate() function.

 

Update: Seems I was right about the <ObjectRef>.Activate() function. The paramter to the function is the activating object reference and the function is called on the object to be activated. Still don't know why my script wasn't working. http://www.creationkit.com/ObjectReference_Script

Edited by DesertEaglePWN
Link to comment
Share on other sites

I stand corrected but have no idea how to fix your issue. All properties filled, I assume? It seems like an amateur mistake but it's quite a normal one.

TeleportDoor is filled, which is the only one used. Still no dice. Changed the OnActivate() to an OnTriggerEnter(); will report back.

Edited by DesertEaglePWN
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...