Skills using Common Events

Engr. Adiktuzmiko

Chemical Engineer, Game Developer, Using BlinkBoy'
Veteran
Joined
May 15, 2012
Messages
14,682
Reaction score
3,003
First Language
Tagalog
Primarily Uses
RMVXA
it means even if you put 2 or more common events in there, only 1 will run
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
Your question has nothing to do with scripts. I have split it from the RGSSx questions that don't deserve their own thread topic and moved it to the correct forum. Please take more care when posting questions next time. Thank you.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,367
Reaction score
7,676
First Language
German
Primarily Uses
RMMV
how should I use a skill's common event field? it looked simple but the events don't seem to run, I created an event that should just add up howmany times a skill is used.
Basically you're using it correctly.
One question: have you any scripts installed?


I'm asking because there are scripts available that use variables 20 to 24 as default configurations, and change those variables for their own use. In such a case the common event might run correctly but the values are changed again before you access them.


That is the reason why you should ALWAYS name a variable as soon as it is used (in your pictures, the variable is still unnamed).


When you add a script, check if it uses variables and switches and if yes, name them at once - that way you can see if a variable is already used somewhere else when you're looking for one to use in your other events. And when you use a new variable for events, always name it before closing the control variable window...
 

raskalnickoff

Villager
Member
Joined
Jun 5, 2014
Messages
11
Reaction score
0
First Language
english
Primarily Uses
I'm still a little puzzled by this but it makes sence if other scripts get in the road. I think my issue has to do with the order that common events and damage is processed during the battle. The only reliable workaround I have is to edit the variables within the damage formula like this.

$game_variables[25]=2;$game_variables[26]=9;$game_variables[27]=10;(a.mat+10)*a.element_rate(10);so that the three variables are set anf then the damage is calculated. But then it gets a bit crowded and hard to read.

When I'm not getting frustrated I do take the time to name the variables. I should rearrange some of them again so that they are grouped together properly, but thats later.[screenshot of old comon event]  In most situations this Common Event still works, but in this instace I've added that mat dies, testing that the Common event does indeed never occur.

I only have two custom scripts:

Yanfly Engine Ace - Death Common Events v1.01

DYNAMIC FEATURES v1.00 by Shaz
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
The damage formula uses v to refer to $game_variables. So you could do this:

Code:
v[25]=2;v[26]=9;v[27]=10;(a.mat+10)*a.element_rate(10)
Also remove the final ; because it's indicating that you're ending one command and starting another. It MAY return null rather than the result of the calculation.
 

raskalnickoff

Villager
Member
Joined
Jun 5, 2014
Messages
11
Reaction score
0
First Language
english
Primarily Uses
That looks much more elegant, I'll change them all like that and remove the common event call.
 

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,083
Members
137,583
Latest member
write2dgray
Top