dietplums Posted November 1, 2022 Share Posted November 1, 2022 I'm trying to do a script where after activating the activator, the player will be shown a one of two messages based on their intelligence this is the script I tried using on the activator: Scriptname AAAooo1messasage1 extends ObjectReference Const {show message either message 1 or message 2 based on the players intelligence} Event OnActivate(ObjectReference akActionRef) If Player(GetBaseValue Actor Value: "Intelligence" < 5) AAAmessage01.show() ElseIf Player(GetBasevalue Actor Value: "Intelligence" > 5) AAAmessage02.show() EndIf EndEvent Message Property AAAmessage01 Auto Const Message Property AAAmessage02 Auto Const Actor Property Player Auto Const thank you Link to comment Share on other sites More sharing options...
iqoniq Posted November 1, 2022 Share Posted November 1, 2022 Try this... Scriptname AAAooo1messasage1 extends ObjectReference Const {show message either message 1 or message 2 based on the players intelligence} Actor Property PlayerRef Auto Const ActorValue Property Intelligence Auto Const Message Property AAAmessage01 Auto Const Message Property AAAmessage02 Auto Const Event OnActivate(ObjectReference akActionRef) Int pIntelligence = PlayerRef.Getvalue(Intelligence) As Int If pIntelligence < 5 AAAmessage01.show() ElseIf pIntelligence > 5 AAAmessage02.show() EndIf EndEvent Something to remember is that you're only checking that the player intelligence is under or over 5, so nothing will happen if the player's intelligence is 5. If you want something to happen on "is less than or equals" or "more than or equals" then use <= or >= respectively. Link to comment Share on other sites More sharing options...
dietplums Posted November 1, 2022 Author Share Posted November 1, 2022 complied and work thank you Link to comment Share on other sites More sharing options...
Recommended Posts