RPG Maker Forums

Sorry for making another topic so soon, but this all this scripting all so confusing for me!

---

I want to make a shop that updates it's wares based on switches/variables.

Example: if Switch 001 is on, the shop will sell ethers, in addition to it's usual wares(let's say potions and antidotes).

After a LOT of trial and error I figured out how to add items and open a shop through a scriptcall.

Code:
var shopItems = [[0,1,0,0],[0,2,0,0],[0,3,0,0]];
SceneManager.push(Scene_Shop);
SceneManager.prepareNextScene(shopItems, false);
Though, I have no clue how I add for example, the switch example.
Or perhaps, a variable that's at least 3 or something.



Furthermore... I'd like to know what I've done there.
I understand most of the code luckily, but I don't understand why I have to use this format for the items, and what the numbers stand for.

I figured out that the first number is the catagory(0 = items, 1 = weapons, 2 = armours). The second number is the ID number.. But what is the third number? I found out that the 4th number has something to do with the shop price(if I leave it empty, all items sell for 0). But it doesn't change anything from normal value, if I set it to 500 or so, so that's weird as well.

Ugh, I hope I make sense.

Anyways, if anyone could help me with the first part at least, that's what matters for me most :)

Thanks a lot!

Latest Threads

Latest Posts

Latest Profile Posts

Our latest feature is an interview with... me?!

People4_2 (Capelet off and on) added!

Just beat the last of us 2 last night and starting jedi: fallen order right now, both use unreal engine & when I say i knew 80% of jedi's buttons right away because they were the same buttons as TLOU2 its ridiculous, even the same narrow hallway crawl and barely-made-it jump they do. Unreal Engine is just big budget RPG Maker the way they make games nearly identical at its core lol.
Can someone recommend some fun story-heavy RPGs to me? Coming up with good gameplay is a nightmare! I was thinking of making some gameplay platforming-based, but that doesn't work well in RPG form*. I also was thinking of removing battles, but that would be too much like OneShot. I don't even know how to make good puzzles!
one bad plugin combo later and one of my followers is moonwalking off the screen on his own... I didn't even more yet on the new map lol.

Forum statistics

Threads
106,035
Messages
1,018,455
Members
137,821
Latest member
Capterson
Top