Eventing or scripting, why do you choose one over the other?

cabfe

Cool Cat
Veteran
Joined
Jun 13, 2013
Messages
2,356
Reaction score
2,553
First Language
French
Primarily Uses
RMVXA
Hello,

I'm not sure if this is the right section, but I was wondering.

I've sometimes read people wanting to make parts of their games using events only when scripts can do the same.

Is there a particular benefit from doing it with events?

Like, is it easier (for a non-scripter)? Or maybe faster (in term of execution speed)?

Or is it just for the challenge?
 

MisterTorgue

Explosioooooooons!
Veteran
Joined
Nov 4, 2014
Messages
324
Reaction score
49
First Language
Explosions!
Primarily Uses
I guess it's all of the above, generally I go for scripts as its a lot cleaner and more manageable for a game.

Why do something that could take lots of events and switches that can be done with one script call?

I suppose you'd event if you weren't comfortable with scripts/scripting/editing scripts, or generally just wanted the base game running without scripts.

I personally use scripts over eventing if I can :)

:)
 

Lucy Fox

Chosen Undead
Veteran
Joined
May 16, 2014
Messages
141
Reaction score
320
First Language
German
Primarily Uses
RMXP
I personaly worked longer with events than with scripts.

For me many things are easier with them. I think the eventing system is there to be used : D

Scripts are great, but more for the big complex things. Or things that would crop performance.

Though I often use script calls in events, when they are shorter.
 
Last edited by a moderator:

Matseb2611

Innovate, don't emulate
Veteran
Joined
Oct 15, 2012
Messages
4,573
Reaction score
6,401
First Language
English
Primarily Uses
RMMV
Most times I stick with eventing. The only time I use a script is if what I need cannot be done with events or can be done but requires a lot of fiddling. I'm also reluctant to use a script I've never used before. Some might require a learning curve. Others might not be compatible with those scripts I've already picked. The more script-heavy the game is, the more likely compatibility issues or random script bugs are to occur.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
33,346
Reaction score
8,389
First Language
German
Primarily Uses
RMMV
Lite cannot use scripts, so maybe they're using that.


Lesser number of scripts means lesser chance of compatibility problems.


Yes, eventing is easier than scripting, even if you are a programmer - and it's also easier to debug, because you can't make as many mistakes as are possible with scripts.


And in my personal opinion people too often start looking for scripts when the eventing would be a lot easier than the scripting.


On the other side there are a lot of things that are impossible or difficult to do in eventing.


You need to know when which part is better to use, because you need both if your project is going to be beyond the basic standard.


So in my opinion your topic title reads a bit like "eating or drinking, why do you chose one..." - you need both, you cannot choose one over the other in a lot of cases.
 

TheoAllen

Self-proclaimed jack of all trades
Veteran
Joined
Mar 16, 2012
Messages
6,252
Reaction score
7,648
First Language
Indonesian
Primarily Uses
RMVXA
For me, eventing is just like easier scripting with limited possibility at same time.

So, whenever I want to make a complex system (which might be possible to be done by event), I usually go with the script.

Say that I have a lot of evented encounter. And they will respawn in next 360 frames.

Using event, I need to put Wait for 360 frames. Then I realized that it was too fast. I want it more longer. I need to change all the events.

Using script, I could store the 360 value in a constant.

Then, whenever I want to change the value, I just need to change a single line in script.

That makes my life easier.
 
Last edited by a moderator:

Hollow

(◡‿◡✿)
Veteran
Joined
Jul 14, 2012
Messages
519
Reaction score
439
First Language
English
Primarily Uses
RMMV
Typically, I prefer to event things because I like to be able to do things myself if at all possible. I also feel that I have more control over the outcome of what it is I'm trying to do if I event it, rather than having to flounder around with someone else's script if there's something I don't like. However, that's not to say that I won't use scripts if I feel that doing so would graphically or control-wise appear more polished (like for custom menus, battle systems, etc.).

@Theo: You still could event that, you'd just use a common event instead of a bunch of regular events and set the battle processing to be "Same as Random Encounter".
 
Last edited by a moderator:

TheoAllen

Self-proclaimed jack of all trades
Veteran
Joined
Mar 16, 2012
Messages
6,252
Reaction score
7,648
First Language
Indonesian
Primarily Uses
RMVXA
Oh thanks, I didnt event think that common event would help

However, I'm not a fans of common event tho
 

Hollow

(◡‿◡✿)
Veteran
Joined
Jul 14, 2012
Messages
519
Reaction score
439
First Language
English
Primarily Uses
RMMV
Oh? How come? I find them extremely useful for events that you'll be doing more than once, since they, like your scripting example, allow you to only change something once and it'll affect all instances of the event.
 

MHRob

Card Master
Veteran
Joined
Jun 30, 2014
Messages
133
Reaction score
24
First Language
English
Primarily Uses
RMVXA
I think they both have their merits for use. In the end, it just comes down to what you want, what you need, and what would seem easier to use to reach your desired goal.
 

TheoAllen

Self-proclaimed jack of all trades
Veteran
Joined
Mar 16, 2012
Messages
6,252
Reaction score
7,648
First Language
Indonesian
Primarily Uses
RMVXA
How about random gain item? (taken from my game)

class Game_Interpreter # -------------------------------------------------------------------------- # Itemlist : # -------------------------------------------------------------------------- # 1. HP # 2. AP # 3. Less Elixir # 4. Elixir # 5. Cure # 6. Mass Cure # 7. Tonic # 8. Grand Tonic # -------------------------------------------------------------------------- Candidate = [2, 1,1,1,1,1,1, 2,2,2,2,2,#~ 3,3,3, 4, 5,5,5,5, 6,6, 7,7,7, 8] # -------------------------------------------------------------------------- # Random gain item. Coz, I'm too lazy to do eventing. Also it's for # compatibility with my event notification # -------------------------------------------------------------------------- def gain_random str = @params[0] item_candidate = Candidate.clone @params[3] = rand(item_candidate.shift) + 1 @params[0] = item_candidate[rand(item_candidate.size)] @params[1] = 0 @params[2] = 0 $game_system.item_found += @params[3] # Record item found command_126 @params[0] = str end end 
Usage in eventing

eventing.jpg


How do you overcome the random gain item using eventing without using a lot of conditional branches? (which I dont like it)

EDIT :
Dont mind about what exactly the script is. It just simply gain random item.

EDIT2:

Dont get me wrong, it just for my personal preference. I always suggest people to do eventing to solve their problem. So that they won't rely on scripting. And I will suggest how to do event for them as far as I know. But for me, I will just use script anyway.
 
Last edited by a moderator:

Hollow

(◡‿◡✿)
Veteran
Joined
Jul 14, 2012
Messages
519
Reaction score
439
First Language
English
Primarily Uses
RMMV
You would have to use several conditional branches, but if you don't like to use them then I can't really help.  :guffaw:  Although honestly, if you are more comfortable scripting something over eventing, go ahead. I like to event most everything, and like I said, I just enjoy being able to do things myself. I respect people who can do what they need to on their own as well.

So yeah, script away, my friend, if that's what you'd prefer to do in this instance.  :)
 

MisterTorgue

Explosioooooooons!
Veteran
Joined
Nov 4, 2014
Messages
324
Reaction score
49
First Language
Explosions!
Primarily Uses
Well I do still use eventing don't get me wrong, I still use it a lot.

But for things like quests, scripts to me are essential, as before I used them, you can easily forget what quests you are on and such, and it becomes a huge pain in the bum.

so let me rephrase, I use scripts over eventing, when its more beneficial and end user friendly on the final product :)
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,464
Reaction score
11,940
First Language
English
Primarily Uses
RMVXA
I use both.

I have found that the more I do, the more I find can be done with pure eventing.  I do use a lot of common events and, as a sub-category of that, regions which call common events.  I find that using events gives me microscopic control over tiny variations that I want to have, and they are quicker to de-bug.  And there aren't compatibility issues.  A lot of my custom scripts are, in fact, compatibility patches.

There are things which are far more efficient, and maybe only possible, using a script.  On the efficiency side quests has just been mentioned, and that is a good example.  Managing separate parties with separate inventories would be a nightmare with just events, though it can be done.

I think a lot of people, especially those new to the engine, reach for scripts far too quickly, because they don't realise just how powerful the events menu and the data base are.  A good example would be the number of times I've seen quite complex bits of scripting suggested to achieve something that is dealt with in an easy, straightforward way in the damage formula.
 

Omnimental

Veteran
Veteran
Joined
Apr 27, 2012
Messages
237
Reaction score
83
First Language
English
Primarily Uses
I prefer to use eventing if I can, but for larger/more complex stuff, I'll go with a script.  The more moving parts it has, the more I'm likely to look for a script that can handle it.
 

Tsukihime

Veteran
Veteran
Joined
Jun 30, 2012
Messages
8,564
Reaction score
3,878
First Language
English
Depends on the scope of the problem.


If it's isolated to a single event or map, then I wouldn't mind using a common event.


If it's something that I'm going to be using consistently throughout the game, or require me to pass arguments around (have not found a nice way to integrate arguments in to common event calls), or anything that would be easier to just write a method and use script calls, I would use scripts.


If it's something I may re-use again, and having to copy a bunch of events and switches and variables and anything else involved is too much work, I would use a script.


If the solution is going to look extremely hackish and unmaintainable with events, I'd go with scripts.
 
Last edited by a moderator:

cabfe

Cool Cat
Veteran
Joined
Jun 13, 2013
Messages
2,356
Reaction score
2,553
First Language
French
Primarily Uses
RMVXA
So I understand that, if a particular task can be done either with events or with a script, the choice is more a matter of taste.

Has a benchmark already been made between the two?

That's probably not very relevant since the most CPU consuming tasks are generaly not doable with events, but maybe that could be measured, out of curiosity.

Events are more or less hidden script calls, so I'd say that eventing is slightly slower, although I bet it's unnoticeable.
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,464
Reaction score
11,940
First Language
English
Primarily Uses
RMVXA
@cabfe

Since getting Effectus, I have noticed that everything runs more quickly/smoothly.  It's quite ironic that it's a script which sorts out the problems which come from having too many events.  

But this reminds me of another advantage of events over scripts - increasingly one has to pay to use scripts in commercial games, including scripts which used to be free for commercial.  That can quickly add up to a significant sum.  Events are always free.  I'm now using events to do some quite complex graphic things which can be done by a script, but which would now cost me.
 
Last edited by a moderator:

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
42,869
Reaction score
14,989
First Language
English
Primarily Uses
RMMV
I use both.


If it can be done easily with events, I will. If it becomes too messy to do with events, or too complicated, or requires too many events, I might either use a script, or write some script methods that I can call from the event to make it easier.


I recommend people try to do it with events first, then if they can't figure it out, ask for help to do it with events, and then if it still doesn't work, resort to scripts. I see WAY too many people telling newbies to download entire engines (like Yanfly's or Victor's) to do one simple little task, when an evented solution exists already, and is extremely easy to use. This indicates that the person making the suggestion doesn't know the engine well enough themselves, and is teaching someone new that scripts are required when they're not, giving the impression that RPG Maker is hard to use. Also, the more you try to do with events before resorting to scripts, the more familiar you will become with the engine.


It's like the old "you MUST have custom graphics in your game" debate ... you can do some pretty amazing stuff using only what's provided, if you become familiar with it and use a bit of imagination. Eventing vs scripting is the same :)
 

Hudell

Dog Lord
Veteran
Joined
Oct 2, 2014
Messages
3,602
Reaction score
3,837
First Language
Java's Crypt
Primarily Uses
RMMZ
I don't even bother with events. I load all my script files on Sublime 3 and use all it's awesome features to develop faster.

An example: I can easily find out where I use each variable and / or switch on the game. If I didn't use scripts, I would need to look one event at a time.
 

Latest Threads

Latest Posts

Latest Profile Posts

Turning a specific vibe into reality is incredibly difficult. For instance, this song is one of the ones I listen to when working on my post apocalyptic project, and getting it's "feeling" into the game has been a real challenge.

I don't just wanna regurgitate the numbers I see, I wanna actually understand the calculations I'm making so I'm probably gonna make a post later with some calculations and what I THINK they mean to get some advice and corrections.

Edit: All (Most) of these will be tested in game prior. I just wanna make sure I understand what's going on under the hood if you will.
my girlfriend calls all my little chibi art cute lol... funny considering that wasn't the original art style of the game.
100 problems in RMMZ 100 more problems take one down pass it around 101 Problems in RMMZ
Made some progress on my game, mostly mapping. Learned quite a bit in the process!.

M6eUoTT.png

Forum statistics

Threads
113,778
Messages
1,077,361
Members
147,807
Latest member
shadowbroniceguys
Top