Final Fantasy Hacktics

Modding => Help! => Topic started by: Seph24 on July 13, 2015, 12:53:04 pm

Title: Problem with ENTD flags. Allies not spawning.
Post by: Seph24 on July 13, 2015, 12:53:04 pm
Hi everyone! I'm making a patch centered around setting and randomizing the units you get in every battle. I'm having troubles with the 1st random battle I edited as some units will not spawn. I haven't had this problem with any of the story battles I edited up to this point (at least from the little testing I made I think so), but with this one there are very EVIDENT problems with the flags.

I wanted 3 "always present" units: a chocobo, an archer and a squire. Then a "randomly present" chocobo, and 2 different "randomly present" knights in the same x/y coords (so only 1 will spawn if any). I've had the archer not spawning several times despite being an "alwys present" flag, and the knights have never spawned so far in 10 or more tests.

Does anyone know exactly how these flags work? Maybe with random battles having too much "randomly present" units already it screws up the chances of spawn, or maybe it has a set amount of randoms that can spawn at a time? IDK...

As a side note, I'll be very thankful if anyone checks out some questions I left in the FFTPatcher sticky a couple of days ago which haven't been answered yet. Thx in advance guys.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Xifanie on July 13, 2015, 04:57:22 pm
My guess is that the game has already loaded 4 spritesheets, so it completely ignores your other units.

So in your case, it would normal to never see knights, because female archer + chocobo + male squire already adds up to 3 units. There's an always present goblin and red panther, but both have a randomly present red panther and goblin respectively that could spawn there instead. Your best bet would still be 2 goblins or 2 red panthers, and no matter what, that still brings you up to 4 spritesheets.
Occasionally, you'll be lucky with the spawns and actually get 2 goblins and no red panthers, or 2 red panthers and no goblins, allowing the archer to spawn (it goes from the top of the list to the bottom).

Hope that answered your question.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Seph24 on July 13, 2015, 06:04:30 pm
So, instead of having a max 9 different total spritesheets available I have only 4 because I'm generating them on the ENTD directly?

How does the 1st battle at Orbonne work then? There you have Ramza, Rad (regular squire), Alicia and Lavian (regular female knight), Agrias, Gafgarion, a male knight, male archers and a male chemist, adding up to 8 different sprites generated in the ENTD
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Xifanie on July 13, 2015, 07:04:16 pm
in random battles, 5 spritesheet slots are allocated for your squad formation.
So because the game can only have 9 loaded at any time, that leaves 4 for the ENTD.
Doesn't matter if it's ally or enemy, it's a unit.

Random battles are special in the way that if you bring a male squire yourself, that doesn't change anything for the game. You won't get a free-pass at a generated unit in the ENTD.

Orbonne has 10-12 spritesheets total, but only 9 tops loaded at any time. The enemy units are removed (and so are their spritesheets) before loading Delita, Ovelia and the chocobo into memory and VRAM.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Seph24 on July 13, 2015, 07:13:06 pm
Ok, so in the ENTD it's 4 tops either if it's an ally or a foe. If the enemy team has a male squire and I have a female one it will count as 2, right? Do different palettes also count as 2?

That leaves me with little choice but to use more or less the same jobs as the enemies in most fights. I've already asked this in another topic but, is there any known way to generate guests directly on the battle formation screen? As in: walking on thea world map -> fight is triggered -> allied units are generated and you choose and place them in the formation screen -> fight starts -> end of the fight -> guest units generated don't join/ leave party
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: 3lric on July 13, 2015, 07:16:15 pm
http://ffhacktics.com/smf/index.php?topic=10972.msg207315#msg207315

Also, yes, Male/Female counts as two. Different palettes do not count separately.

Set Guests in Randoms by making them the same team as your own (Blue) and by not setting them to control or join after event.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Seph24 on July 13, 2015, 07:22:50 pm
Cool, male and female count as 2, and different palettes as 1. I don't intend to modify anything that's already in story or random battles, only ADD to that. I'm already setting my guests to blue team, always be controllable and never join after events. Is there any problem with them being controllable? It doesn't seem to make a difference..
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: 3lric on July 13, 2015, 07:37:47 pm
Controllable is fine, but you can't control guests in Vanilla, so i didn't mention it.

Make sure to read the link I posted to understand how to put more than 4 different enemies in a random battle.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Seph24 on July 13, 2015, 08:39:55 pm
Oh I've read it already, thx. What I get from it is that you still get 4 tops. It's either one or the other, like having 2 knights: one in x1y1, the other in x2y2, and then 2 archers: one in x1y1 and the other in x2y2. This will either spawn the knights or the archers but not one of each if I understan correctly, right?
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: 3lric on July 13, 2015, 08:43:42 pm
Correct, the most you are going to have in random battles is 4 types of enemies. Randoms are handled differently than story battles, where you can actually control how many of what there is, unlike Randoms, which are coded to not go over the sprite limit, and since you can always bring 5 people into a random battle, you'll never have more than 4 types of enemies.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Seph24 on July 13, 2015, 08:46:17 pm
Wait, does that mean I get 8 different spritesheets in the ENTD in story battles and 4 in random battles?
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: 3lric on July 13, 2015, 08:50:04 pm
I don't know where you are getting that from. All I was saying is that Randoms are coded to only allow 4, even though others can be randomly present in the ENTD and may switch up provided you have the coordinates set correctly.

The sprite limit is ALWAYS 9. I only mentioned story battles because you have more control over them. You COULD have 8 enemy types in a story battle, but that would only leave you with 1 spritesheet left for your team...

You only get 4 in randoms because the formation for randoms allows you to have 5 allies. which leaves room for 4 enemy types
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Seph24 on July 13, 2015, 08:56:49 pm
Then, assuming in my patch there's NO ONE but Ramza in your Main formation screen or Battle formation screen, would that allow me to put 8 different guests total in the ENTD in story battles (both foes and allies)?

It's one of the aims of the patch to do that. Ramza is the only controllable party member and the only one you'll ever get to place in the battle formation screen. I'm thinking of maybe letting Boco join with the "no breeding ASM" on but, I haven't decided yet.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: 3lric on July 13, 2015, 09:02:34 pm
Yes, if Ramza was the only one in formation then you have room for 8 other spritesheets. This will not include Random battles. As, mentioned above, they are handled differently.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Seph24 on July 13, 2015, 09:05:12 pm
Well that's great! I get it now. Thx a lot to both you and Xifanie for responding, and sorry for asking so much. You've been really helpful!
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Seph24 on July 16, 2015, 11:02:35 pm
I have another very related doubt and figured I'd post it here instead of making a new thread.

I had a fight with 10 different sprites at the same time and none of them broke or bugged. It's in sweegy's story battle. I set the first wizard and knights to randomly appear, and the 2nd set to be always present but on the same x/y coordinates so that you either spawn 2 knights, 2 wizards or one of each. then 2 random red panthers and at the end an always present chemist. As you can see, there are already 9 sprites there (from top to bottom: Delita, Algus, Goblin, Black Goblin, Bomb, Red Panther, Wizard, Knight, Chemist) , 10 including Ramza. I thought the last one on the list (the always present chemist) would only spawn if you get 2 wizards or 2 knights but it appears even when I get 1 of each, making a total of 10 sprites on the map with Ramza.

I've played the entire 10 sprite battle and had no problems with any sprite, none bugged at all. I just wanted to know why is that, as I assumed there could only be 9 at a time, and also how do I make the chemist only appear when I get 2 knights/wizards.

Thx in advance guys.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: gatebuster202 on July 16, 2015, 11:42:19 pm
Only Nine Sprites if we include Ramza, The Goblins and Black Goblins count as a palette swap. (Correct me if I am wrong anyone.)

As to the Chemist only appearing if you have Knights and Archers... That is beyond my skill.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: 3lric on July 17, 2015, 01:14:08 am
Palettes don't count. Goblin and Black Goblin is the same sprite. Try as you might. You will not have more than 9 sprites.
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: Seph24 on July 17, 2015, 06:09:07 pm
Well, it does make a lot of sense that different monster tiers are considered just palette swaps between themselves. Thx guys
Title: Re: Problem with ENTD flags. Allies not spawning.
Post by: 3lric on July 17, 2015, 07:36:17 pm
Of course it does, they are called from the same sheet :P They don't have separate spritesheets or use different slots.