Posted: Sun Apr 12, 2020 9:18 am Post subject:
AI produces the wrong units
Subject description: AI produces the wrong units
When playing TI 0.7 added a new unit "NOD Sniper" to the NOD house, in full analogy with the "SNIPER" GDI. Everything was fine, the game was going as expected, "NOD Sniper" was produced where it should and looked and did everything in accordance with the Rules.ini parameters. I copied the same parameters in TI 0.8.0.7. Found that "NOD Sniper" now produces not only NOD, but also GDI. What's the catch, is it a bug version 0.8? QUICK_EDIT
More like a snippet of code changed and you didn't notice.
What do you have for the Nod sniper, for the folks who don't have TI installed?
And what code did you copy for him from the GDI sniper? _________________ One and only developer of the Command & Conquer Dune "C&C D" mod.
m7 wrote:
I tend to release things I create so that assets are never lost to hard drive problems, accidental deletion, or me having to pretend to care about rippers taking things from my project when it is done.
Unit's weapons don't matter much, unless they're working improperly or the game crashes upon construction of a unit.
I can't see anything wrong with the Nod sniper... unless...
Is the only thing the AI is building now the Nod sniper? Or is your problem only that the AI is building the Nod sniper alongside other units when it shouldn't?
If the AI only builds the Nod sniper, regardless which side, then you've encountered the "100 units" bug that occurs when a buildable unit exists in a list after 100.
Fix it by having the Nod sniper be elsewhere in the list, preferably before unbuidlabe/civilian units. QUICK_EDIT
its gotta be the max unit bug; the AI wouldnt be making it at all without AI triggers telling it to. moving the unit's place on the list isnt going to keep the list from being over max, either.
too bad no one ever made hacks for the TS engine _________________ visit my moddb profile for .shp downloads and stuff QUICK_EDIT
you could get rid of half of the civilians (CIV1 - CIV29)
i doubt anyone would notice if 14 of the 29 civilians are missing. _________________ SHP Artist of Twisted Insurrection: Nod buildings
100+ units bugfix for TS already exists (provided by AlexB). Have updated it for infantry. Didn't test it for aircraft 100+ case, so that portion of the code is commented in the updated patch.
The unit is named SNIPER and its Primary is named Sniper in the mod. Similarly, NSNIPER and NSniper in the code snippet above. Those could be made unambiguous by naming the Primary as SniperGun, SniperWeap etc.. QUICK_EDIT
Thank you guys. The problem really was that the new unit was assigned a serial number greater than 100. I changed it to the 60th and the problem disappeared. Thanks everyone for help. QUICK_EDIT
You can post new topics in this forum You can reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum