Non-threaded

Forums » Advanced Editor Forum » Read Thread

Get help from the experts on variables, scripts, items, and other scary things.

Item scripting?

12 years ago

I want to make it so that you may only use the item 'gun' if you have the item 'bullets'. Seeking help on how to do so, thanks.

Item scripting?

12 years ago

You can use an ITEM SCRIPT on the Gun Item to direct to a Page that says “You’re out of Bullets” or the like when you don’t have Bullets. It would look something like this –

When you are keeping Track of Bullets as a Variable:
IF %BULLETS < 1 THEN
  $DEST := @P100 (“Out of Bullets” Page

When you are keeping Track of Bullets as an ITEM:
IF $ITEMSTATE99 = 0 THEN
  $DEST := @P100

Item scripting?

12 years ago

Thanks! :)