Project Perfect Mod Forums
:: Home :: Get Hosted :: PPM FAQ :: Forum FAQ :: Privacy Policy :: Search :: Memberlist :: Usergroups :: Register :: Profile :: Log in to check your private messages :: Log in ::


The time now is Fri Apr 19, 2024 4:34 am
All times are UTC + 0
Ding Ding... RA2 INI cross-checking scripts *UPDATED for YR*
Moderators: Global Moderators, Red Alert 2 Moderators
Post new topic   This topic is locked: you cannot edit posts or make replies. Page 4 of 4 [159 Posts] Mark the topic unread ::  View previous topic :: View next topic
Goto page: Previous 1, 2, 3, 4
Author Message
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Wed May 03, 2023 5:45 am    Post subject: Reply with quote  Mark this post and the followings unread

Darkstorm wrote:
I'm not sure I entirely understand how to use these scripts? I was able to sort out getting ActiveTCL working but if I understand the output I'm getting back, I need to have the INI files in the specific path C:\CC-RA2 ?

You have to edit every tcl you plan to use to set the basic variables like paths and filenames. Also the scripts should be placed in the game dir so the batchfiles can launch the resulting log without extra steps.
Darkstorm wrote:
AICheck specifically seems to still kick back an error that it can't find rules.ini but if I rename my rulesmd then it seems to function.

Once you sort out the settings, some scripts will have .cfg files you can also modify, but that's more advanced stuff you'd get into after you have grasped the basic functions.
Darkstorm wrote:
I'm a bit more interested in knowing how the map checkers work. I'm not entirely sure how it works or even what it does but I have a map that's been crashing on me every time I run it and I'm at wits end trying to figure out what's up with it.

The AICHECK script does do some basic map checking if you let it, which just looks for objects that aren't in your mod, or you have removed something without realizing you still use it on maps. It's not a comprehensive map check in that it doesn't know the scripting or triggers, that's in another script I haven't released yet. MAPCLEAN is for doing automated removal of junk, or substitution of the common stuff for things your mod needs. It has some advanced abilities when you figure that out.

For a complete description of each script, look here -> https://www.ppmforums.com/topic-67456/g-es-ra2-ini-scripts-mega-pack-for-march-2023/

This thread is for incremental updates and new releases, which eventually get put into a pack, after they reach a kind of stable plateau.

_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
Darkstorm
Commander


Joined: 20 Jan 2008
Location: Texas

PostPosted: Wed May 03, 2023 8:12 am    Post subject: Reply with quote  Mark this post and the followings unread

Thank you so much! I was able to edit the scripts to get them working so it should be relatively smooth sailing now.

As for my little map problem, I suppose that largely dashes my hopes of an easy fix for it but it's not a big deal. I'm sure I'll get it sorted out one way or another at some point. I'll definitely be looking out for that unreleased map script in a future pack.

Back to top
View user's profile Send private message ModDB Profile ID
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Wed May 03, 2023 8:18 am    Post subject: Reply with quote  Mark this post and the followings unread

If you want to send me your map via PM, I can take a look?

_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Sat May 06, 2023 1:54 pm    Post subject: Reply with quote  Mark this post and the followings unread

Here's a new script TAGLIST 1.2a... (reposting with big update)

The purpose of this script is to merely find improperly capitalized tags within rules.ini specifically. It has part of the code necessary to check art.ini as well, but is currently disabled. Now not all of rules.ini is parsed, it focuses on the various unit types, buildings and warheads, as this is primarily where you will have the errors.

The script is really just looking at syntax, but will ONLY indicate the first instance of an object which had the incorrectly written tag. There are common spelling mistakes, and capitalization errors even in the vanilla rules.ini that this script will catch. Make sure you note the caveats at the end.

The script does not modify the rules.ini at all, expecting the user to do a replace-all for any errors found, unless the error is deprecated due to Ares/Phobos etc and is no longer an error anymore.

***

The script has 2 modes of operating:

1. Look through the object code, and compare any tags found to a list of known tags, in a case insensitive manner, and then a second time as case sensitive, as stored in the taglist.cfg file. It will log the tags it finds that it doesn't know, and will also log the tags that it knows are incorrectly written.

2. Look through the object code, and compare any tags to the list in taglist.cfg, but only log the ones not listed. They are logged/written just as the tag, with no error or warning message to explain it in this mode, so that the list can easily be copied to add to the taglist.cfg, which you should only need to do for the new tags added by Ares and other extensions.

***

Known issue: The existence of JumpjetAccel can prevent jumpjet units from landing, so the incorrect spelling found in rules.ini is actually preventing a behaviour bug, fixing it would thus re-enable the bug.

Strictly speaking this is compatible with TS as well, although you'd have to update the entries in taglist.cfg to remove RA2-specific tags, and include any TS-specific ones, although the base games have extensive overlap, and it should still be useful as-is.



prevtags.jpg
 Description:
 Filesize:  30 KB
 Viewed:  1675 Time(s)

prevtags.jpg



_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Thu May 11, 2023 6:13 am    Post subject: Reply with quote  Mark this post and the followings unread

TAGLIST 1.3...

This update refactors the code, overall faster, with some minor parsing changes too. Also the header comments have been fixed, had some inappropriate stuff in there, and shortened the line lengths.

The main change is that now it ships with separate cfg files for RA2/YR/TS/FS, with a secondary EXT cfg file that can be edited to include all the tags used by your engine patches or extensions like Ares or Vinifera. When you edit the tcl, you will see where to switch which cfg is loaded.

I have asked on Discord for help adding the various Ares/Phobos tags to the extended cfg, but if anyone here wants to try their hand at it, it would be appreciated.



taglist.rar
 Description:

Download
 Filename:  taglist.rar
 Filesize:  13.32 KB
 Downloaded:  8 Time(s)


_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Last edited by G-E on Sun May 14, 2023 9:05 pm; edited 2 times in total

Back to top
View user's profile Send private message
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Thu May 11, 2023 6:19 am    Post subject: Reply with quote  Mark this post and the followings unread

SOUNDCHECK 3.2...

This is mostly a performance update. Some redundancy has been removed, and ini loading code has been streamlined. The only outward change is that the unused sound total isn't reported in the stats at the end of the log, if there are no unused sounds.



sndcheck3.rar
 Description:

Download
 Filename:  sndcheck3.rar
 Filesize:  4.69 KB
 Downloaded:  9 Time(s)


_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Sun May 14, 2023 9:23 pm    Post subject: Reply with quote  Mark this post and the followings unread

Ok here's the big one, finally ready for primetime, Mission Tester 5.3!

This script does basically what AICHECK does, but with a focus on the map. That is it only reads some cursory information from rules/art to be able to process the map objects and such. Optionally it will read sound.ini and cross-check for any sounds used on the map as well.

The script will handle both single and multiplayer maps, and it can be handy to track down why a sound isn't playing or object isn't showing up on the multiplayer maps, but it's real strength is figuring out how the mission scripting works or doesn't.

Usage is simple, like MAPCLEAN you just drag a map onto the batchfile to have it process, the batchfile will then run the log to read in your editor. As always basic configuration has to be done within the tcl, and you will need the runtimes, but otherwise only has a few settings. I recommend leaving the defaults, but up to you.

Small caveats with functionality, the enabling of AITriggerTypes in the map is not strictly limited to global triggers, but that's what the script checks them against, it does this before the rest of the map is fully loaded, so there's no simple way to merge the list with map triggers. And moving the trigger processing to the end seems like a very awkward ordering, so I have no intention to fix it until I think of a better way.

The logging can be set to append rather than replace, so if you want to scan all your missions, you can set it to append, then drag-n-drop each mission in turn (one by one) until they're all processed, before reading the log. If you don't have many issues arise, it may give you a better overview, but again personal preference.

Also by default it writes out the animations played by the scripts, I found this to be very handy in cases where the animation list might be altered, and it wouldn't be obvious until the mission was played that it's wrong. A quick notice might alert you ahead of that fact.

This script has been a long time in the making, random people have sent me maps to test against, and MadHQ used it throughout his own remastering of the campaigns, so I believe it is feature-complete, but I'm open to surprises Smile



missy.jpg
 Description:
 Filesize:  476.67 KB
 Viewed:  1419 Time(s)

missy.jpg



mistest5.rar
 Description:

Download
 Filename:  mistest5.rar
 Filesize:  10.71 KB
 Downloaded:  14 Time(s)


_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Mon May 22, 2023 12:32 pm    Post subject: Reply with quote  Mark this post and the followings unread

MASSSSSSIIIVE UPDATE!

AICLEAN 6.0...

First thing is the engine has had a major rewrite for a lot of parts, so that sections are now able to be specified in the aiclean.cfg to come first, these would be the declaration lists and other major headers. Then not only will AICLEAN write those sections as specified, but will afterwards write each object belonging to those sections in the same order. The only exceptions to this are a few things that get written purposely at the end of rules.ini.

The second major feature is the ability to MERGE inis using the [include] functions. It will not merge nested includes, and it might even crash if you try, so only the first level is supported. The merged data is used as priority for object code, but will remove duplicated tags and do its best to sort out the lists. The resulting inis will no longer have include sections, and the external inis can be deleted/moved.

As part of these major changes, the aiclean.log will be a lot more verbose, and will explain largely the changes made, but also highlight some problems that need you to resolve. Keep in mind AICLEAN is not really an analysis tool in the way its architected, it doesn't know or try to guess what is what, only if it's explicitly declared, or in some cases used, will it know. This means that "orphans" are considered anything undeclared and unused generally speaking, but it also means that you need to check your inis with AICHECK afterwards, and fix the errors.

This is a very extensive overhaul and although it was tested on SE and GC, it's possible it does weird things on yours. Please leave any feedback, testing has been difficult.



cleeeen.jpg
 Description:
 Filesize:  211.07 KB
 Viewed:  1291 Time(s)

cleeeen.jpg



aiclean6.rar
 Description:

Download
 Filename:  aiclean6.rar
 Filesize:  15.74 KB
 Downloaded:  9 Time(s)


_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Sat May 27, 2023 6:32 am    Post subject: Reply with quote  Mark this post and the followings unread

When I started this thread, I only had one script and the beginnings of a second, and it made sense to keep them together, as they were related. However, this thread has now expanded to cover 8 distinct scripts, and as such, it's time to split them apart into their own threads, where updates or suggestions can be segregated neatly, and it will be clearer when one receives an update.

The new threads are all under Community Tools:
AICHECK: https://www.ppmforums.com/topic-68095/aicheck-a-script-for-extensively-analyzing-rulesartaiini/
AICLEAN: https://www.ppmforums.com/topic-68089/aiclean-a-script-to-clean-and-organize-rulesartaiini/
TAGLIST: https://www.ppmforums.com/topic-68088/taglist-a-script-to-check-validity-of-tags-within-rulesini/

SOUNDCHECK: https://www.ppmforums.com/topic-68094/soundcheck-a-script-to-check-for-mistakes-related-to-sounds-in-rulesartsoundini/
SOUNDCLEAN: https://www.ppmforums.com/topic-68098/soundclean-a-script-to-organize-soundini-and-re-order-declarations/

MAPCLEAN: https://www.ppmforums.com/topic-68099/mapclean-a-script-to-addremovemodify-tags-and-sections-in-maps/
MISTEST: https://www.ppmforums.com/topic-68090/mistest-a-script-to-test-mission-map-code-and-check-map-objects-for-errors/

_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   This topic is locked: you cannot edit posts or make replies. Page 4 of 4 [159 Posts] Goto page: Previous 1, 2, 3, 4
Mark the topic unread ::  View previous topic :: View next topic
 
Share on TwitterShare on FacebookShare on Google+Share on DiggShare on RedditShare on PInterestShare on Del.icio.usShare on Stumble Upon
You cannot post new topics in this forum
You cannot 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


Powered by phpBB © phpBB Group

[ Time: 0.2615s ][ Queries: 16 (0.0199s) ][ Debug on ]