Region IDs and battle events - not transforming before the 'emerged' message

Nereid

Veteran
Veteran
Joined
Sep 22, 2021
Messages
199
Reaction score
64
First Language
none
Primarily Uses
RMMZ
Enemies are supposed to appear only on specific squares? And only limited to 3?
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
2,780
Reaction score
1,630
First Language
English
Primarily Uses
RMMV
I don't understand what you're asking. Are you asking for someone to explain the region ID options in the encounter settings? If that's not what you mean, you'll need to use more specific language, please.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
34,305
Reaction score
8,750
First Language
German
Primarily Uses
RMMV
yes, there are no ranges. But you rarely need them anyway.

If you don't place regions in the encounter list, the random encounters will be on every tile
 

Nereid

Veteran
Veteran
Joined
Sep 22, 2021
Messages
199
Reaction score
64
First Language
none
Primarily Uses
RMMZ
I've tested it and seems like the above is true. I can hardly believe the two options are either everywhere or just 3 small squares...
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
2,780
Reaction score
1,630
First Language
English
Primarily Uses
RMMV
I've tested it and seems like the above is true. I can hardly believe the two options are either everywhere or just 3 small squares...
You seem to misunderstand what a region ID is. The last tab on your map editor, labeled R, is for region IDs. You place those, just like map tiles, on any squares you like. You could have your entire map covered with Region 1 (I have no idea why you'd want to, but you could). One region ID is not a small square, it's as much of your map as you want.

So allowing you to define 3 region IDs for an encounter is a lot of flexibility - most maps for most people won't include any region IDs, never mind more than 3. And if there's some reason you actually need more than 3 different regions that can include the same encounter (then why are they different regions?), you can just list it again with other region IDs.
 

Nereid

Veteran
Veteran
Joined
Sep 22, 2021
Messages
199
Reaction score
64
First Language
none
Primarily Uses
RMMZ
Ah, I missed that. Also, is there a way to make an enemy stop appearing once defeated?
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
34,305
Reaction score
8,750
First Language
German
Primarily Uses
RMMV
is there a way to make an enemy stop appearing once defeated?
that would be an evented encounter, not a random encounter. Just make a map event for that enemy, placed either where you want it or with code to check multiple positions before triggering the battle processing.
and then you can disable the event as one-time use (or count the uses if more than once) or whatever else you want by eventing.

EDIT: Or use a troop event to change the enemy in the random encounters - you would still call the same troop but it would no longer contain the once enemy (needs a switch assigned to the enemy)
 

Nereid

Veteran
Veteran
Joined
Sep 22, 2021
Messages
199
Reaction score
64
First Language
none
Primarily Uses
RMMZ
So, I'm trying the latter in the database's troops section, but I can't see how, as there's no self-switches, and so can't temporarily turn a switch on... I tried to have a separate on-map event to switch on, autorunning it, then self-switching to a blank page, so it wouldn't run again, then...
◆If:#3 enemy... is affected by Dead
◆Control Switches:#0033 switch = OFF

:End
But after defeat they still appear...
 
Last edited:

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
2,780
Reaction score
1,630
First Language
English
Primarily Uses
RMMV
So, I'm trying the latter in the database's troops section, but I can't see how, as there's no self-switches, and so can't temporarily turn a switch on
Andar didn't say anything about self-switches, you would use an actual normal switch.

So, for example, you would make your troop and have your one-time enemy in there. Right-click on it and select Appear Halfway, which means it's loaded into the troop's data but doesn't actually appear in the combat.

Then, make a turn 0 event that says if switch whatever number is OFF, Enemy Appear (on tab 3).

Then you'll have the other troop event you made above to turn that switch ON when that enemy dies. Just note that if that's the last enemy alive in the troop, the event won't run unless you use the Hime or SRD plugin to make troop events execute before battles end.

(Or you could spawn that enemy with an immortal state and take it off after you toggle the switch)
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
34,305
Reaction score
8,750
First Language
German
Primarily Uses
RMMV
that isn't how it works with troops and troop events.
1) make a switch "enemy x dead". ALWAYS name a switch when it is first used or when you configure it for a newly added plugin, if you don't do this your later bughunting will become much more problematic.

2) make a troop event run on turn #0, span = battle
if switch "enemy x dead" is on, then transform enemy into something else
else give immortal state to enemy x (state with resist death, needed for a quirk of the troop events not being processed on battleend)

3) make a troop event run on enemy x HP=0
switch "enemy x dead" to ON
remove immortal state (so that the enemy can die after the switch is turned)

ninja'd
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
2,780
Reaction score
1,630
First Language
English
Primarily Uses
RMMV
Not really! Your transform approach is a bit more elegant than my hidden approach, because it doesn't take up a slot in the troop permanently. In case the OP wanted all of them.
 

Nereid

Veteran
Veteran
Joined
Sep 22, 2021
Messages
199
Reaction score
64
First Language
none
Primarily Uses
RMMZ
Turn 0 starts before command entry, how would that help? I tried two conditions on the same page, still doesn't seem to prevent the recurrence...
 

HexMozart88

The Master of Random Garbage
Veteran
Joined
May 15, 2016
Messages
2,164
Reaction score
4,087
First Language
English
Primarily Uses
RMVXA
Turn 0 is just when it starts. If you set it to span=battle, it lasts for the whole thing.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
34,305
Reaction score
8,750
First Language
German
Primarily Uses
RMMV
Turn 0 starts before command entry, how would that help?
that is exactly the reason, so that the change happens before the fight.
I tried two conditions on the same page, still doesn't seem to prevent the recurrence...
then please show screenshots of what you have done so that we can check where you made a mistake

If you set it to span=battle, it lasts for the whole thing.
wrong - the span sets how often the troop event can repeat.
once per battle, once per turn, once per action/moment
the changes are needed once per battle in either way.
 

Nereid

Veteran
Veteran
Joined
Sep 22, 2021
Messages
199
Reaction score
64
First Language
none
Primarily Uses
RMMZ
The first pic I'm not sure about, I tried to do the above... also, how does the condition interfere with the 'if'?
RPGMZ_7KlY7nTlea.png
RPGMZ_ssxHHynl2t.png
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
2,780
Reaction score
1,630
First Language
English
Primarily Uses
RMMV
The first pic I'm not sure about, I tried to do the above...
Me either. I'm not sure why you're using two switches to track one enemy...it doesn't help that you didn't take Andar's advice about giving the switches useful names so you can keep track of what they're doing.

You also didn't follow the instructions that both Andar and I gave about the enemy starting Immortal and removing that before they die - otherwise, it won't process the event before the battle ends.

You thirdly have a weird condition on your second event. You're checking one time when switch 33 is turned on to see if your Treant died. The event condition should be Enemy HP -> Treant -> 0%

Andar's steps 2 and 3 from post 10 give pretty clear instructions on how to do this, you just haven't followed them at all.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
34,305
Reaction score
8,750
First Language
German
Primarily Uses
RMMV
The first pic I'm not sure about, I tried to do the above
This is what I wrote for that event, care to compare?
2) make a troop event run on turn #0, span = battle
if switch "enemy x dead" is on, then transform enemy into something else
else give immortal state to enemy x (state with resist death, needed for a quirk of the troop events not being processed on battleend)

"if switch "enemy x dead is ON" - why do you test for OFF?
"then transform enemy into something else" - there is no transform command in your event, instead there are only control switch commands - something that I never wrote for that event.
"else give immortal state to enemy x" - there is nothing in the else branch, despite me explaining that this is needed for the other event to function.

And your second screenshot has absolutely nothing to do with what I wrote...
3) make a troop event run on enemy x HP=0
switch "enemy x dead" to ON
remove immortal state (so that the enemy can die after the switch is turned)
There are only two commands, none of which is a conditional branch, in my description.
 

Nereid

Veteran
Veteran
Joined
Sep 22, 2021
Messages
199
Reaction score
64
First Language
none
Primarily Uses
RMMZ
Can you write it in a form I can paste it in the window? A lot of this didn't make much sense to me, which is why I tried to do what made sense, also I avoided the immortal bit because I thought checking for the dead state was the same, and I didn't quite understand why the rest applied (I was also not defeating them last, so that shouldn't have mattered).
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
34,305
Reaction score
8,750
First Language
German
Primarily Uses
RMMV
Can you write it in a form I can paste it in the window?
I literally gave you the names for all event commands, it doesn't get any more direct than that.
But here you have them as screenshots:
trooppage1.png
trooppage2.png
 

Nereid

Veteran
Veteran
Joined
Sep 22, 2021
Messages
199
Reaction score
64
First Language
none
Primarily Uses
RMMZ
What's the point of transform? I simply did x = x? As I don't want to change them into anything else... and it's not working, at any rate, simply getting them immortal in the first battle, then as expected for the next, but they keep respawning in future battles still.
 

Latest Threads

Latest Posts

Latest Profile Posts

Apparently Amazon Prime users get free Genshin Impact stuff like primogems and whatnot every month, but I'm not sure I ever want to fall into the abyss of F2P ever again.
Doing RPG Maker News for 26th Nov to 2nd Dec (2021)

"Yeah. It's been a rough road lately. But that's the thing about the Rangers. It doesn't matter how hard it gets, or how many of them fall. They never stop fighting. The Rangers NEVER stop fighting".

Angela Deth, you are a hero of mine. Sorry for my first run of Wasteland 3.
We must press on. For all those we couldn't save. For all those we might yet save.
FirestormNeos wrote on DarkPlasmaBall's profile.
asking this here instead of the thread in question to avoid derailing it, but I'm curious; is there a particular reason you'd include a "Terms of Use" for an RPG Maker game? Like, are there multiplayer features for the game you're working on?

Forum statistics

Threads
117,144
Messages
1,104,923
Members
153,211
Latest member
Necrozys
Top