Only show event if a stat is high enough

Canini

Veteran
Veteran
Joined
Mar 29, 2016
Messages
1,025
Reaction score
686
First Language
Swedish
Primarily Uses
RMVXA
I am working on a game prototype where there are few battles but stats still play a big part. Making events and sidequests raise a character stat is simple enough I was wondering if there any way to only show an event if a characters stat is only above a certain threshold? Lets say there is a ghost in a map that the player can only see or interact with if their wisdow stat is high enough. Any suggestions how this can be implemented, and if it is even possible? 
 

Oddball

Veteran
Veteran
Joined
Sep 4, 2014
Messages
1,923
Reaction score
535
First Language
English
Primarily Uses
N/A
i think its possible to store a stat value into a variable. so yes, it is possible. practical? ask someone who knows how to store a stat into a variable
 

standardplayer

Keeper of Kitties
Veteran
Joined
Apr 6, 2016
Messages
698
Reaction score
3,451
First Language
English
Primarily Uses
N/A
You can use Control Variables (Game Data) to store specific data like stats into variables.


Then, you can use Conditional branch to check if said variable is greater than, equal to, less than, etc. You can even check if the variable is 'not' equal to something and run an event that way. 


But lets say we did that ghost example. 


Make the ghost an event that has one of the conditions in the upper left side checked. You can choose the variable you've chosen your stat in, and what value it needs to be equal to or greater than in order for the event to trigger.  


To recap, Control variable and click Game Data to access the stats to store. 


Set event's inherent requirement to be the stat and it's required value, via the variable you made. 


Hope this helped ^^

examp.png
 

Canini

Veteran
Veteran
Joined
Mar 29, 2016
Messages
1,025
Reaction score
686
First Language
Swedish
Primarily Uses
RMVXA
Neat, thanks. Would it be possible to take it even further, say make the ghost appear on a certain threshold but not make the player be able to interact with it until yet another threshold is crossed. Or do you have to do two events in that case?
 

Ghost of Christmas Kloe

The Icecream Princess
Veteran
Joined
Nov 15, 2015
Messages
1,548
Reaction score
957
First Language
English
Primarily Uses
RMMZ
Yes, a conditional branch which works IF the variable you used earlier is X.
 

Canini

Veteran
Veteran
Joined
Mar 29, 2016
Messages
1,025
Reaction score
686
First Language
Swedish
Primarily Uses
RMVXA
Nice!


I will be experimenting a bit with this during the weekend, then.
 

clark

Villager
Member
Joined
Feb 23, 2016
Messages
22
Reaction score
10
First Language
english
Primarily Uses
you can actually set a blank page, then have page 2 be set to the variable also to make the thing completely invisible until said variable is reached.
 

Menos

Veteran
Veteran
Joined
Apr 12, 2015
Messages
47
Reaction score
16
First Language
English
Primarily Uses
Neat, thanks. Would it be possible to take it even further, say make the ghost appear on a certain threshold but not make the player be able to interact with it until yet another threshold is crossed. Or do you have to do two events in that case?
You could do this either via if statements or event pages. The latter probably has more flexibility, since you could use graphics of the ghost at different transparencies and make it get more concrete as the player gets closer to being able to interact.
 

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

Latest Threads

Latest Posts

Latest Profile Posts

People3_5 and People3_8 added!

so hopefully tomorrow i get to go home from the hospital i've been here for 5 days already and it's driving me mad. I miss my family like crazy but at least I get to use my own toiletries and my own clothes. My mom is coming to visit soon i can't wait to see her cause i miss her the most. :kaojoy:
Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.

Forum statistics

Threads
105,868
Messages
1,017,085
Members
137,583
Latest member
write2dgray
Top