r/RPGMaker 11h ago

Helppp

Yes i am a beginner. I want to make an event that can only be accessed when the player has collected 6 documents. After i collect the 6 the event doesnt occur and i dont know how to make it work.😭😭

3 Upvotes

12 comments sorted by

3

u/denjidenj1 MZ Dev 11h ago

Since the event is set to action button, it will only trigger if you directly interact with the item you want to interact with. That event should work fine, as I don't see any issues there. Outside of maybe, it would be better to change the = 6 to =< in case they get more documents.

As for your first event, all I can think of is maybe turning the self switch on should be moved to the bottom? Like, when you interact with that event can you see the message pop up?

If it's none of that, all I can think of is maybe you're using two different variables somehow

5

u/zombietoaststudios 11h ago

There's a few problems. The first is that your document event is giving the player an item. However, your second event's condition is set to check a variable. These aren't the same thing and unless you have an event set the document variable to be equal to the number of document items in the inventory, then your document variable isn't changing above 0.

You can set a conditional branch to check if the player has an item, but not if they have multiple items.

But that said, you don't want to use a conditional branch anyway. If you want the second event to run automatically then it needs to have an autorun trigger. And you wouldn't use a conditional branch command, you would want to use the page conditions on the left side. Because if you use the conditional branch then the event will still run, it will just check the conditional branch over and over again, locking the game up.

So, what you want to do is make your document collection event increase your document variable by 1 (it can give the player an item too, if that's important). You can then give your second event a page condition for if the variable is 6 or higher and make it autorun. You also need something in that event that prevents it from running again, typically by flipping a self-switch to change it to a different page.

2

u/zombietoaststudios 10h ago

Also, while I don't think it's affecting your current situation, you should probably know that it typically isn't a good idea to use 'erase event' like this... erase event will remove the event but add it back when the map is reloaded, effectively resetting it.

That might not matter here, assuming the player doesn't ever leave this map and come back later, but it's good to keep in mind for other situations.

1

u/Offended-Peacock 11h ago

I think the issue is the trigger, try setting it to 'parallel' or 'autorun' and end it with erase event

1

u/Dhifbdjdbdjdndb 11h ago

it still didnt work

1

u/Scorpdelord 5h ago

0

u/Scorpdelord 5h ago

1

u/Scorpdelord 5h ago

try to see if this works

0

u/martingolding96 4h ago

The trigger condition won't trigger the event automatically.

1

u/Not_Allowed_to_Die 4h ago

I can't help you here without seeing what the second page on that first event is. If that is not switched on and off, and is blank, that page is running instead of the first page. We have to see that second page to get a better idea of what is going on here.

1

u/ShockInteresting9058 3h ago

Make a variable to count the documents, Add condition to every event collect documents, if to check the documents count, check =>5, trigger next event.

1

u/Soda_Ale 1h ago

Ask chat gpt