Status
Not open for further replies.

Tiamat5774

Dragon Master (yes, I am a DM
Veteran
Joined
Jul 9, 2013
Messages
92
Reaction score
7
First Language
English
Primarily Uses
First of all let me say that I am virtually under novice at scripting.  My first game that I made was created only from the existing database and eventing commands.  No extra scripts were used.

With that said, I'm currently undertaking a larger project, but I've already run into a problem.  I am using a caterpillar script that is credited to Fukuyama.  It works really well as caterpillars go.  Here's the problem: when a character dies in battle, the dead character is still visible and walking in the "train".  How do I remove or change the character graphic for the dead character WITHOUT removing it from the party?  The only thing I have tried so far is common events but I don't know how to trigger the event.  Maybe it can be handled with a script or editing an existing script, but as I said, I'm a dunce in that area.

Any help would be great!

-Tiamat5774

Caterpillar Script.txt
 

Attachments

  • Caterpillar Script.txt
    323 bytes · Views: 31

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
42,883
Reaction score
14,992
First Language
English
Primarily Uses
RMMV
You could just do a Change Actor Graphic event call and select None. Of course, you'd have to then detect when they're dead and not dead so you can change them appropriately. Most would recommend a parallel process common event that's always running and checking, but I really dislike using those.
 

Tiamat5774

Dragon Master (yes, I am a DM
Veteran
Joined
Jul 9, 2013
Messages
92
Reaction score
7
First Language
English
Primarily Uses
Just so I can be forewarned, could you please elaborate as to why you dislike using parallel process?  And to all others that read this I was hoping for a script or script edit to handle this.

I created a common event that covers the eventuality of death for all 22 of my actors.  It was working last night but this morning one of my cut scene events was apparently corrupted.  As I tried to find and remove the problem lines in the event, the game would freeze. I also removed all parallel process events to see if that was the problem and the game still froze.  I wound up deleting the cut scene event and I'm going to have to remake it.  Just wondering what would have caused the mess up with that event.

To avoid using parallel process for the "Dead condition" common event, I would have to create an event page for every actor in the troops condition commands.  Something like "Actor's hp is 1% or below" then in the event command box use "Call Common event Dead Condition".

Doing that for every actor in every troop would be a major pain.
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
42,883
Reaction score
14,992
First Language
English
Primarily Uses
RMMV
I will use them when they're needed. What I dislike is that people use them all over the place and then wonder why their game is lagging.


A parallel process, without a wait (which is what most people do, and which is what contributes to lag) would check up to 60 times a second. That is a HUGE waste.


In this case, there are two distinct points when you would want a sprite to change. When the HP becomes 0, or when the HP goes from being 0 to something else. If I were trying to do this, I would modify the script - the actual method that causes the actor's HP to change, and pop in a couple of checks for those conditions. That means I'm checking to see if the sprite should be changed at ONLY the exact times when the conditions could change that would lead to a different sprite being used.


But if you don't like scripting, you're left with events, which is why I said most would recommend a parallel process common event that's always checking. At least make it wait a certain number of frames either before starting all the checks or after they're all done (not inside a conditional branch).
 

Tiamat5774

Dragon Master (yes, I am a DM
Veteran
Joined
Jul 9, 2013
Messages
92
Reaction score
7
First Language
English
Primarily Uses
Thanks.

I settled it with a parallel process common event.  I included the wait as you advised and it seems to be working just fine. No lag. 

Will I have to include this event in every map for it to work?

It's not that I don't like scripting, it's that given all the tutorials, I still don't understand it.  I would edit the lines in the scripts if I knew which ones specifically to edit and in which scripts.  I would need specific instructions.
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
42,883
Reaction score
14,992
First Language
English
Primarily Uses
RMMV
If you made it as a parallel process common event then you shouldn't have included it on ANY map. Since it's a common event, it runs over ALL maps.


This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.
 
Status
Not open for further replies.

Latest Threads

Latest Posts

Latest Profile Posts

I have made 60 new skills! ''after test'' I have made 3 new skills!

Made a new battleback this week! How's it look?
"This is the real secret to life - To be completely engaged with what you are doing in the here and now. And instead of calling it work, realize it is play."
Me: "I don't to use other engines because I'd have to do a lot of coding."

Also my desktop right now....
mycurrentdesktop.jpg

...I literally spend more time using VS Code than MZ. :kaoswt:
actually, are there any JRPG type games (I guess turn based, so not ARPGs like say, Vagrant Story) where you have only one party member for the majority of the game? (I wonder if I'm forgetting something obvious.)

Forum statistics

Threads
113,802
Messages
1,077,595
Members
147,858
Latest member
HigorTheHideoux
Top