Stefanos

Veteran
Veteran
Joined
May 7, 2017
Messages
55
Reaction score
15
First Language
English
Primarily Uses
RMVXA
Is it possible to have such bundles sold in shops?
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,847
Reaction score
12,376
First Language
English
Primarily Uses
RMMZ
I haven't come across a script which does that. It is possible to do it with variables, but it will be cumbersome.

You would have to set an individual variable (e.g. variable 29) for the item which the shop sells which has this feature. (Let's hope your shops don't have a wide variety of stock, as it has to be a separate variable for each different item!). You would do this immediately before the Shop Processing command. Now the game knows how many of item X the player has before buying anything.

Immediately after the shop processing, have a new variable (e.g. variable 35) set to the item(s)
Conditional branch
Is the new variable (35) greater than the original variable (29)
If it is, have the shop keeper say "Here is your free item for having bought our Deluxe Ear Muffs", and give it via Change Item command.
If it's not, then nothing.

You would have to do that for each item involved.
 

Stefanos

Veteran
Veteran
Joined
May 7, 2017
Messages
55
Reaction score
15
First Language
English
Primarily Uses
RMVXA
I haven't come across a script which does that. It is possible to do it with variables, but it will be cumbersome.

You would have to set an individual variable (e.g. variable 29) for the item which the shop sells which has this feature. (Let's hope your shops don't have a wide variety of stock, as it has to be a separate variable for each different item!). You would do this immediately before the Shop Processing command. Now the game knows how many of item X the player has before buying anything.

Immediately after the shop processing, have a new variable (e.g. variable 35) set to the item(s)
Conditional branch
Is the new variable (35) greater than the original variable (29)
If it is, have the shop keeper say "Here is your free item for having bought our Deluxe Ear Muffs", and give it via Change Item command.
If it's not, then nothing.

You would have to do that for each item involved.

And in which menu is it that we set these "variables" before shop processing?
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,847
Reaction score
12,376
First Language
English
Primarily Uses
RMMZ
They are set via a command on the first tab of the Event Command Menu.

Your question shows that you are new to the engine. I strongly urge you to work through Andar's compilation of info for new users, especially the playable tutorial for switches and variables that he links to. Spending a bit of time on it now will save you a huge amount of time and frustration in the future. Without a firm grasp of switches and variables, and eventing in general, you simply won't be able to make a game.
 

Latest Threads

Latest Posts

Latest Profile Posts

It might be a little bit boring and tedious, but building that database of armor, items, weapons and skills are super important.
More words of wisdom: Trying to make everyone happy will just make you miserable.
Ads: "Up to 90% off"
Reality: 9 items at 10% Off, one item at 90% off
if you were working on a rhythm-based retro fighting game, would you rather have the jumps take up two beats (one for jumping, one for landing) or just one?

Forum statistics

Threads
124,383
Messages
1,163,248
Members
163,181
Latest member
Insaneaphobe
Top