Main Menu

Item Box (Want to put those extra potions somewhere?) Tutorial

Started by Forty, June 11, 2007, 03:43:51 PM

0 Members and 1 Guest are viewing this topic.

Forty

Ok, this tutorial is for having an NPC holding an unlimited ammount of one (or more) item(s)
You will need one variable

Lets say there is a box that can hold all your potions for you
It should look like this

Text: I could store potions in here (this is not necessary, but what the heck)
Text: Put a potion in?
Show Choices:Yes, No
When [Yes]
Conditional Branch: [Potion] in inventory
Change Items: [Potion], - 1
Control Variables: [Potion Ammount] +=1
Else
Text: I don't have any!
Branch End
When [No]
Text: Want to take one out?
Show Choices: Yes, No
When [Yes]
Conditional Branch: Variable: [Potion Ammount] >=1
Change Items: [Potion], +1
Control Variables: [Potion Ammount] -=1
Else
Text: There's none in there!
Branch End
When [No]
Text: Then what am I doing here?
Branch End


If you want to be able to put multiple items in there, add another choice between those items in the beginning, for money, you could have the player put in like 10 gold at a time rather than one. It would take forever

Revo

Hey, that is pretty neat!

Not sure why... But I get a feeling I saw this somewhere else... :-\

Could have been on another site, so good job!

Forty

Thank you, I keep thinking of event systems to use, so...I'll post another after lunch!

Kokowam

Great! Too bad you need one variable for each item stored and for each item storable, you need a choice on the choice thing. And more choices if you exceed 3.

Forty

Yeah...but thats its done...without scripts...scripts and me is a nono