Code:
Scn AbfrageScript
Begin OnActivate
If ( Player.GetItemCount Item1 > 0 )
If Activator1.GetDisabled == 0
Activator1.Disable
Activator2.Enable
Player.RemoveItem Item1 1
Elseif ( Activator1.GetDisabled ) && ( Activator2.GetDisabled == 0 )
Activator2.Disable
Activator3.Enable
Player.RemoveItem Item1 1
Elseif ( Activator2.GetDisabled ) && ( Activator1.GetDisabled )
Activator3.Disable
Activator4.Enable
Player.RemoveItem Item1 1
Endif
Elseif ( Player.GetItemCount Item2 > 0 )
If Activator1.GetDisabled == 0
Activator1.Disable
Activator2.Enable
Player.RemoveItem Item2 1
Elseif ( Activator1.GetDisabled ) && ( Activator2.GetDisabled == 0 )
Activator2.Disable
Activator3.Enable
Player.RemoveItem Item2 1
Elseif ( Activator2.GetDisabled ) && ( Activator1.GetDisabled )
Activator3.Disable
Activator4.Enable
Player.RemoveItem Item2 1
Endif
Elseif ( Player.GetItemCount Item3 > 0 )
If Activator1.GetDisabled == 0
Activator1.Disable
Activator2.Enable
Player.RemoveItem Item3 1
Elseif ( Activator1.GetDisabled ) && ( Activator2.GetDisabled == 0 )
Activator2.Disable
Activator3.Enable
Player.RemoveItem Item3 1
Elseif ( Activator2.GetDisabled ) && ( Activator1.GetDisabled )
Activator3.Disable
Activator4.Enable
Player.RemoveItem Item3 1
Endif
Endif
End
Das wäre für das erste. Der erste Activator muss ganz normal platziert werden, die anderen müssen von Anfang an Disabled sein (Das funktioniert in dem du auf das Objekt doppelklickst [Im Object Window] und dann einen Haken bei Intially Disabled machst, steht unten bei Persitent Reference)
Code:
Scn AbfrageScriptMessagebox
Short Button
Begin OnActivate
If Activator4.GetDisabled == 0
MessageBox "Willst du den Zauber oder den Gegenstand?", "Zauber", "Gegenstand"
Set Button to GetButtonPressed
Endif
End
Begin GameMode
If Button == -1
Set Button to GetButtonPressed
Elseif Button == 0
Player.AddSpell ZauberID
Activator4.Disable
Activator5.Enable
Elseif Button == 1
Player.AddItem ItemID Anzahl
Activator4.Disable
Activator5.Enable
Endif
End
Wenn ichs richtig verstanden hab müsste das hier für die zweite Sache richtig sein.