Random Common Events?

Leandar

Warper
Member
Joined
Jan 17, 2018
Messages
3
Reaction score
0
First Language
Danish
Primarily Uses
RMMV
Greetings.

I was hoping someone from the community could make a very small demo game
that is calling a random event. (could just be two or three random questions)
Or if there is already one, point me in the right direction.
I would be forever gratefull.... well.. maybe not FOREVER but close to ;)

Best regards
Leandar
 

V_Aero

Veteran
Veteran
Joined
Apr 23, 2019
Messages
244
Reaction score
215
First Language
german
Primarily Uses
RMMV
Eh what exactly do you need? Not using Plugins or Scripts an event cannot be called randomly, but only by the Player. What you need to do instead is to add a new event page in that NPC with conditions, eg a simple Switch. Using Variable operations you can request random variables to set the switch on and off.
 

Leandar

Warper
Member
Joined
Jan 17, 2018
Messages
3
Reaction score
0
First Language
Danish
Primarily Uses
RMMV
Hey V_Aero. Thanks for reply. In my head (which probably aren't fully functioning) this is what i need: PLAYER touch an EVENT which then call a random EVENT. The random event in this case being a 'show choices' EVENT or any 'common event' And the perfect thing would be an demo exsample. That way I would be sure to learn it.
 

ShadowDragon

Veteran
Veteran
Joined
Oct 8, 2018
Messages
1,877
Reaction score
615
First Language
Dutch
Primarily Uses
RMMV
1 way is to create serval common events

on the event with touch, create a variable and follow like this:

control variable x = 0 .... 3 // x being the variable ID with random number 0 to 3 (4 in total)
if variable x = 0
common event 1 (1 is name or ID what you want to call)
end
if variable x = 1
common event 2
end
if variable x = 2
common event 3
end
if variable x = 3
common event 4
end

when the event is being touch, a random common event is being called.
call the variable random and use it in many events that needs a random number,
make sure random is called first before anything else, make selfswitch A = ON
in every common event, and page 2 if you want to end the event after being touch.

page 2 = blank with selfwswitch A is on.

you can repeat the above in different ways and as many time as needed.
 

Leandar

Warper
Member
Joined
Jan 17, 2018
Messages
3
Reaction score
0
First Language
Danish
Primarily Uses
RMMV
Thank you a lot ShadowDragon. Ive got it working. Much apreciated.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

// Looks at Elfkisser, realizes he'd have to either install Windows 10 or compile it for Linux
// Didn't install Elfkisser.
Too much effort for a curiosity. :popcorn:
I was just high-fiving myself for all I've learnt in the engine, and how far I've come, only to forget to remove the Immortal state from a semi-scripted battle. Now the enemy never dies and I feel so smart >.>
Playtest your stuff. Always playtest.
just spent FOREVER troubleshooting an issue with my keyboard... turns out the cord was just loose OTL
I count on someone one time, I let them promise something to me, and one week later it's complete silence as I'm completely let down. I hate everything.
Everytime I need to write dialogues I find myself writing new music pieces... what kind of trick is this?!

Forum statistics

Threads
99,223
Messages
963,203
Members
130,813
Latest member
Gremter
Top