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 Thu Mar 28, 2024 8:21 pm
All times are UTC + 0
AI Editor for RA2 and TS
Moderators: Community Tools Developpers
Post new topic   Reply to topic Page 1 of 4 [186 Posts] Mark the topic unread ::  View previous topic :: View next topic
Goto page: 1, 2, 3, 4 Next
Author Message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Thu Aug 07, 2014 1:34 pm    Post subject:  AI Editor for RA2 and TS
Subject description: Updated to v2.0.4.4
Reply with quote  Mark this post and the followings unread

### C&C AI Editor ###

This is a program to edit the AI of the Red Alert 2 and Tiberian Sun computer games. To use it you have to extract the rules.ini and ai.ini files first.

The AI configuration file describes a set of rules that trigger the computer to build groups of units that behave according to a script. The AI is relatively simple to design and consists of four basic building blocks:
- Task Force: This is your group of units.
- Script: This describes the actions a Task Force will undertake to complete its mission.
- Team: Combines Task Force and Script with some additional behavioral flags.
- Trigger: Describes under which circumstances a Team will be created (triggered).

To understand how these are used it is best to read the included AI Guide and to study RA2's or TS's AI.

Link: https://github.com/askeladdk/aiedit

## Changelog ##

### v2.0.4.4 ###
- Re-arranged and text aligned for the sort columns.
- Added TeamType House column again.
- Fixed width for column's attributes removed.
- Default width of left panel columns made compatible with both 100% and 125% DPI scaling.

### v2.0.4.3 ###
- Removed House column from TeamTypes tab as it is not all that useful.
- Added IsBaseDefense column to TeamTypes tab.
- Added Initial Weight column to TriggerTypes tab.
- Columns except for the Name column have fixed width.
- Increased screen real estate by broadening form width.

### v2.0.4.2 ###
- Added columns showing House, Max and Priority to Team Types tab.
- Added columns showing Side, Tech Level, Easy, Medium and Hard to Trigger Types tab.

### v2.0.4.1 ###
- Script action's UI number field's max value raised to 6-digits. (by E1 Elite)

### v2.0.4.0 ###
- Double click on boolean fields to toggle their values.
- AITrigger UI fields re-ordered for better readability.
- Script action types from config file is now parsed based on its ID instead of its array index. (by E1 Elite)
- YR config file updated with Ares script action additions of IDs from 65 to 70 (by E1 Elite)

### v2.0.3.9 ###
- TS config file fix of veteran level and removed unused AITrigger condition choices
- Skipped across list duplicate ID check for AITrigger IDs as vanilla TS has such
- Added version number to application title text
- Updated the AIGuide for script action Attack TargetType (0,n)

### v2.0.3.8 ###
- Reverted back non-essential changes in the form designer file.

### v2.0.3.7 ###
- Fixed additional number of duplicate messages on reloading INI files.

### v2.0.3.6 ###
- Added AI Guide for offline reference.
- Removed the usage of [AIEdit] section for ID generation.
- Provided StartIndex, IDPrefix and IDSuffix fields in config file for customizing IDs.
- Config files updated for corrections and for ID related fields.
- Added duplicate ID check across lists in AI ini.
- Parsing exception message box will now close the application.

### v2.0.3.5 ###
- Avoid creating duplicate IDs even if [AIEdit] section is deleted from AI ini.

### v2.0.3.4 ###
- TeamType fields of Max/Priority/Techlevel now allows negative numbers.

### v2.0.3.3 ###
- Script action's parameters now allow negative numbers wherever needed.
- Script actions 53, 54 and 55 now has editable parameters for YR (config\yr.ini).

### v2.0.3.2 ###
- Added an error message with faulty ID before throwing an exception while parsing AI ini.

### v2.0.3.1 ###
- Application path is used to compute the full path of config files.

### v2.0.3 ###
- Changed the wording of the error log messages to be more consistent.
- Updated to ObjectListView 2.9.10.

### v2.0.2.2 (by E1 Elite) ###
- Crash fix, Script Type/Task Force need not have entries in sequence like Name first or Group last.
- Crash fix, Techno Types can have negative cost in rules.
- Bug fix, AITrigger Techno Type <none> entries won't be replaced with another technotype ID
if any Techno Type Name falls before <none> in sorting.
- More log info for possible errors, also duplicate cases logged from rules to certain extent.
- Additional side placeholder entries in config files, just in case user forgets to edit them when
having additional sides.

### v2.0.2.1 (by E1 Elite) ###
- Techno Type name is appended with its ID.

### v2.0.2 ###
- Fixed bug where the last Task Force entry would be swallowed if the Group tag was missing.
- Names are trimmed when new object is created.
- Duplicate AI object entries will be logged (they are harmless).
- Larger text field for renaming.

### v2.0.1 ###
- Added error log.
- Reference counts are decremented when an AI object is deleted.
- Names and .ini key/value pairs are trimmed.
- Default values for missing tags rather than crashing.
- Can copy AI objects.
- Can double click on AI object reference to jump to it's definition.
- Seperate config for RA2 and YR.
- Inserting script action when nothing is selected appends to end of list.
- Bug fixes.

### v2.0.0 ###
- Rewrote the entire program!
- Cleaned up user interface.
- Autodetects RA2 and TS modes.
- Now loads all AI files regardless of how the sections are ordered.
- Sorted lists for easy searching and organising.
- AI type references are tracked and you can see what they are used by (right click -> Use Info).
- Added keyboard shortcuts for most actions.
- Now distributed under ISC license.



aieditv2_0_4_4.zip
 Description:

Download
 Filename:  aieditv2_0_4_4.zip
 Filesize:  238.85 KB
 Downloaded:  762 Time(s)


Last edited by Askeladd on Tue Sep 03, 2019 5:58 pm; edited 17 times in total

Back to top
View user's profile Send private message
Aro
Alcohol Fueled


Joined: 10 Sep 2006

PostPosted: Thu Aug 07, 2014 1:50 pm    Post subject: Reply with quote  Mark this post and the followings unread

Better than DCoder's tool. Good work!

Back to top
View user's profile Send private message
^Rampastein
Rampastring


Joined: 11 Oct 2008
Location: Gensokyo

PostPosted: Thu Aug 07, 2014 2:00 pm    Post subject: Reply with quote  Mark this post and the followings unread

Writing the AI manually is very well doable. Not very difficult either, just time-consuming. It looks like this tool does make it easier though, so well done Smile

_________________
CnCNet Client | CnCNet TS patches | More Quality-of-Life Improvements for RA Remastered


Back to top
View user's profile Send private message ModDB Profile ID Facebook Profile URL
OrangeNero
Commander


Joined: 11 Jan 2012

PostPosted: Thu Aug 07, 2014 2:22 pm    Post subject: Reply with quote  Mark this post and the followings unread

*insert various tibed slander about real men modding with notepad only.*

great work will try it out.

_________________
Free Tibed!
EA for worst company of the decade!

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


Joined: 03 Sep 2004
Location: Czechia

PostPosted: Thu Aug 07, 2014 3:16 pm    Post subject: Reply with quote  Mark this post and the followings unread

I don't write the AI manually, come at me.

It's high time a replacement for D's editor appeared, I'll definitely be checking this one out soon.

_________________
mentalomega.com

Back to top
View user's profile Send private message Send e-mail Visit poster's website YouTube User URL Facebook Profile URL Twitter Channel URL
E1 Elite
General


Joined: 28 May 2013

PostPosted: Thu Aug 07, 2014 3:48 pm    Post subject: Reply with quote  Mark this post and the followings unread

On AI Editor

- it is only for RA2/YR not for TS, sides are named Allied/Soviet/Yuri
- Script actions are certainly less in TS, above 58 is not applicable.
- New mission scripts are different for TS when compared to YR. Script 11,16 means placing C4
in TS while it is 11,17 in YR. There are only 24 variety for new mission in TS while it is 32 in YR.
- [Offsets] - My understanding of it is, 0 - just refer the building
65536/131072 - for low/high threat, 196608/262144 - for near/far building

- On AITriggers, trigger condition, -1 is for no condition, not Triggered automatically (Autocreate)

It would be helpful to show the raw stuff like script could be also shown as 0=11,16 etc. And clicking
on a script id/taskforce on teamtype screen could show its script/taskforce screen.

It would have been helpful if the editor had an analysis component like to see all AITriggers using same
taskforce etc.

Edit: Incorrect are with strike-through. Read further in the thread for correction.

Last edited by E1 Elite on Mon Jan 08, 2018 1:02 pm; edited 1 time in total

Back to top
View user's profile Send private message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Thu Aug 07, 2014 4:31 pm    Post subject: Reply with quote  Mark this post and the followings unread

E1 Elite wrote:
On AI Editor

- first of all it is only for RA2/YR not for TS
- sides are named Allied/Soviet/Yuri
- Script actions are certainly less in TS, above 58 is not applicable.
- New mission scripts are different for TS when compared to YR. Script 11,16 means placing C4
in TS while it is 11,17 in YR. There are only 24 variety for new mission in TS while it is 32 in YR.
- [Offsets] - My understanding of it is, 0 - just refer the building
65536/131072 - for low/high threat, 196608/262144 - for near/far building
- On AITriggers, trigger condition, -1 is for no condition, not Triggered automatically (Autocreate)
- Available in skirmish option is still doubtful, don't know if it has some other meaning.

It would also be helpful to show the raw stuff like script could be also shown as 0=11,16 etc.

It would have been helpful if the editor had an analysis component like to see all AITriggers using same
taskforce etc.

Thanks for the feedback. Even though the focus is on RA2/YR, AIEdit should work perfectly with TS. You can edit strings.ini to correct any inconsistencies between RA2 and TS.

According to Deezire's AI guide and ModEnc, setting AITriggerType condition to -1 means to create pool teams automatically. That is, without conditions. So you and I are both right. Either way you can edit strings.ini to correct this if you want.

I don't see the need for a raw mode because the reason I wrote this editor is so that I won't ever have to see that crap again. Smile Anyway, I guess what you really want to know is whether the ai.ini that is saved is the same as the ai.ini that was loaded if no changes were made. You can verify this for yourself by using a diff tool. I suggest ExamDiff Pro (the trial works fine). There is one addition to the file which is the [AIEdit] section where the program keeps a counter to ensure every section that is added has a unique ID. This is harmless because the section is ignored by the game.

Analysis tools are a good idea and I might implement those in the future.

Back to top
View user's profile Send private message
Graion Dilach
Defense Minister


Joined: 22 Nov 2010
Location: Iszkaszentgyorgy, Hungary

PostPosted: Thu Aug 07, 2014 4:38 pm    Post subject: Reply with quote  Mark this post and the followings unread

BuildingTypes does not use the offset 65534 but 65536 - that's a bug in the DeeZire documentation, as E1 Elite points out.

The Editor enforces it's own naming scheme for the entries in the INI. The hexnums-G ID format is NOT necessary for an AI to function. Also, it prevents the modder's ability to come up with a meaningful ID naming scheme (since there is just a simple counter getting increased every time a new entry is added).

For some reason it only parsed my triggertypes and nothing else. Okay, it did found the rest, but reported all being blank which is silly, since they're working in YR and were madde with D's editor.

It does not support new sides, neither (not like if D's do, but still).

So honestly, calling this better than D's tool at it's current state is nonsense.

_________________
"If you didn't get angry and mad and frustrated, that means you don't care about the end result, and are doing something wrong." - Greg Kroah-Hartman
=======================
Past C&C projects: Attacque Supérior (2010-2019); Valiant Shades (2019-2021)
=======================
WeiDU mods: Random Graion Tweaks | Graion's Soundsets
Maintainance: Extra Expanded Enhanced Encounters! | BGEESpawn
Contributions: EE Fixpack | Enhanced Edition Trilogy | DSotSC (Trilogy) | UB_IWD | SotSC & a lot more...

Back to top
View user's profile Send private message Visit poster's website ModDB Profile ID
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Thu Aug 07, 2014 4:49 pm    Post subject: Reply with quote  Mark this post and the followings unread

Graion Dilach wrote:
BuildingTypes does not use the offset 65534 but 65536 - that's a bug in the DeeZire documentation, as E1 Elite points out.

The Editor enforces it's own naming scheme for the entries in the INI. The hexnums-G ID format is NOT necessary for an AI to function. Also, it prevents the modder's ability to come up with a meaningful ID naming scheme (since there is just a simple counter getting increased every time a new entry is added).

For some reason it only parsed my triggertypes and nothing else. Okay, it did found the rest, but reported all being blank which is silly, since they're working in YR and were madde with D's editor.

It does not support new sides, neither (not like if D's do, but still).

So honestly, calling this better than D's tool at it's current state is nonsense.


I'll fix that offset 65534 mistake.

Yes, it uses it's own naming scheme for section names because the actual name is unimportant as long as it's unique, and the naming scheme enforces uniqueness. Every section has a Name= tag to give them meaningful names.

You have to give me more information if your inis aren't getting loaded properly. Could you send me your rules and AI inis so I can take a look at it? I have loaded AI inis from several mods before without any problems caused by my program. The only time I had problems opening a file was when the AI ini itself had mistakes, which I had to fix manually.

New sides ARE supported by editing strings.ini. Find the [Sides] sections and add your fourth, fifth, and sixth sides!

Back to top
View user's profile Send private message
Dutchygamer
President


Joined: 18 Jun 2005
Location: Dordrecht, the Netherlands

PostPosted: Thu Aug 07, 2014 4:51 pm    Post subject: Reply with quote  Mark this post and the followings unread

...
Someone actually made an AI editor? THERE GOES MY SECRET PLAN >=3

Back to top
View user's profile Send private message Send e-mail Skype Account
Graion Dilach
Defense Minister


Joined: 22 Nov 2010
Location: Iszkaszentgyorgy, Hungary

PostPosted: Thu Aug 07, 2014 4:59 pm    Post subject: Reply with quote  Mark this post and the followings unread

PM'd. Also, next time mention these in the manual. Readme is used for these, otherwise where should I know from that I should customize that ini...

And ID stuff would be cool to changed because map scripts would be goodluck get fixed - keep in mind that the modder can change which global trigger is enabled on which map. If one does a campaign - then yes your ID countering system is a mess.

_________________
"If you didn't get angry and mad and frustrated, that means you don't care about the end result, and are doing something wrong." - Greg Kroah-Hartman
=======================
Past C&C projects: Attacque Supérior (2010-2019); Valiant Shades (2019-2021)
=======================
WeiDU mods: Random Graion Tweaks | Graion's Soundsets
Maintainance: Extra Expanded Enhanced Encounters! | BGEESpawn
Contributions: EE Fixpack | Enhanced Edition Trilogy | DSotSC (Trilogy) | UB_IWD | SotSC & a lot more...

Back to top
View user's profile Send private message Visit poster's website ModDB Profile ID
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Thu Aug 07, 2014 6:01 pm    Post subject: Reply with quote  Mark this post and the followings unread

Graion Dilach wrote:
PM'd. Also, next time mention these in the manual. Readme is used for these, otherwise where should I know from that I should customize that ini...

And ID stuff would be cool to changed because map scripts would be goodluck get fixed - keep in mind that the modder can change which global trigger is enabled on which map. If one does a campaign - then yes your ID countering system is a mess.

I indeed forgot to mention that in the readme, but I also expected a veteran modder such as yourself to eagerly check out the .ini just to see what's there .Wink

I'm not sure what you mean with map scripts needing to get fixed? The ID numbering only applies to new entries. The names of existing entries remain unchanged.

Anyway, the reason why your AI failed to load correctly is because the listing sections (TeamTypes, ScriptTypes, TaskForces) appear at the end of the file, AFTER the sections they are referring to. If you move those to the top everything works correctly (this is where they normally are anyway). Smile

I updated AIEdit to fix the 65535 offset and you can download v1.01 it from the first post!

Back to top
View user's profile Send private message
Graion Dilach
Defense Minister


Joined: 22 Nov 2010
Location: Iszkaszentgyorgy, Hungary

PostPosted: Thu Aug 07, 2014 6:18 pm    Post subject: Reply with quote  Mark this post and the followings unread

I mean the [AITriggerTypesEnable] section of the maps. Which is used on mission maps to disable triggers using f.e. technology which lorewise does not exist at that moment yet, or disable the training of heroes.

I did checked the ini. And I deduced it's there for translation not for hacking around. Anyway, if it still gets polished for a while - and the readme turns out to be informative - I probably also will try to get accustomed to this tool.

_________________
"If you didn't get angry and mad and frustrated, that means you don't care about the end result, and are doing something wrong." - Greg Kroah-Hartman
=======================
Past C&C projects: Attacque Supérior (2010-2019); Valiant Shades (2019-2021)
=======================
WeiDU mods: Random Graion Tweaks | Graion's Soundsets
Maintainance: Extra Expanded Enhanced Encounters! | BGEESpawn
Contributions: EE Fixpack | Enhanced Edition Trilogy | DSotSC (Trilogy) | UB_IWD | SotSC & a lot more...

Back to top
View user's profile Send private message Visit poster's website ModDB Profile ID
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Thu Aug 07, 2014 6:25 pm    Post subject: Reply with quote  Mark this post and the followings unread

Ah okay. Well you can just add those triggers to the enable section, right? You can still see the IDs of the triggers and other sections in the editor.

Hmm, I have a question actually. Are you guys absolutely sure the offset is 65535 and not 65536? Because that would make more sense given the hexidecimal values of the offsets:

hex(196608) = 0x30000
hex(131072) = 0x20000
hex(65536) = 0x10000
hex(65535) = 0xffff

See what I mean?

Back to top
View user's profile Send private message
Graion Dilach
Defense Minister


Joined: 22 Nov 2010
Location: Iszkaszentgyorgy, Hungary

PostPosted: Thu Aug 07, 2014 6:50 pm    Post subject: Reply with quote  Mark this post and the followings unread

It's indeed 0x010000 not 65535. Noone said 0xFFFF, only you did. #Tongue

_________________
"If you didn't get angry and mad and frustrated, that means you don't care about the end result, and are doing something wrong." - Greg Kroah-Hartman
=======================
Past C&C projects: Attacque Supérior (2010-2019); Valiant Shades (2019-2021)
=======================
WeiDU mods: Random Graion Tweaks | Graion's Soundsets
Maintainance: Extra Expanded Enhanced Encounters! | BGEESpawn
Contributions: EE Fixpack | Enhanced Edition Trilogy | DSotSC (Trilogy) | UB_IWD | SotSC & a lot more...

Back to top
View user's profile Send private message Visit poster's website ModDB Profile ID
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Thu Aug 07, 2014 6:54 pm    Post subject: Reply with quote  Mark this post and the followings unread

Whoops you are right  Embarassed Updated to v1.02.

Back to top
View user's profile Send private message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Thu Aug 07, 2014 7:08 pm    Post subject: Reply with quote  Mark this post and the followings unread

I accidentally zipped the old v.1.01 .exe by mistake but it's fixed now. So please download v1.02 again. Sorry guys :\

Back to top
View user's profile Send private message
Graion Dilach
Defense Minister


Joined: 22 Nov 2010
Location: Iszkaszentgyorgy, Hungary

PostPosted: Thu Aug 07, 2014 7:18 pm    Post subject: Reply with quote  Mark this post and the followings unread

Could've been worse. Okay, I think I'll deal with the ID issue on my own. Good job regardless.

_________________
"If you didn't get angry and mad and frustrated, that means you don't care about the end result, and are doing something wrong." - Greg Kroah-Hartman
=======================
Past C&C projects: Attacque Supérior (2010-2019); Valiant Shades (2019-2021)
=======================
WeiDU mods: Random Graion Tweaks | Graion's Soundsets
Maintainance: Extra Expanded Enhanced Encounters! | BGEESpawn
Contributions: EE Fixpack | Enhanced Edition Trilogy | DSotSC (Trilogy) | UB_IWD | SotSC & a lot more...

Back to top
View user's profile Send private message Visit poster's website ModDB Profile ID
Lin Kuei Ominae
Seth


Joined: 16 Aug 2006
Location: Germany

PostPosted: Thu Aug 07, 2014 7:38 pm    Post subject: Reply with quote  Mark this post and the followings unread

Askeladd wrote:
You need .NET framework 4.5.1 to run it (download from Microsoft).

Are you sure it is necessary. Can't you set 3.5 as target framework?
I'm not going to install 4.5.1 on my nicely running XP system.
Reading an ini file and showing some interface elements is surely something you can even do with .NET 2.0, so for some more compatibility, you should set the target framework down.

.NET 4.5.1 is also not much different than 4.5.0, only the timer class has been put into its own dll. So there is no need to target the absolutely newest version, and at least 4.5.0 should work, if not much older frameworks.

_________________
SHP Artist of Twisted Insurrection:  Nod buildings

Public SHPs
X-Mech Calendar (28 Mechs for GDI and Nod)
5 GDI, 5 Nod, 1 Mutant, 1 Scrin unit, 1 GDI building

Tools
Image Shaper______TMP Shop______C&C Executable Modifier

Back to top
View user's profile Send private message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Thu Aug 07, 2014 8:02 pm    Post subject: Reply with quote  Mark this post and the followings unread

It's not necessary. I just thought I'd set it to the latest version since I upgraded to VSE2013. It's not really my problem if you refuse to update your system (why are you still on XP??), but I'll drop down to a lower .NET version on the next update.

Back to top
View user's profile Send private message
Wolfsangel
Cyborg Soldier


Joined: 25 Jul 2014
Location: Unkown

PostPosted: Thu Aug 07, 2014 10:14 pm    Post subject: Reply with quote  Mark this post and the followings unread

Sweet ,DCoder's Tool was too complicated, this is good. Great work

_________________
Call me as " Xenaga "

Back to top
View user's profile Send private message
Graion Dilach
Defense Minister


Joined: 22 Nov 2010
Location: Iszkaszentgyorgy, Hungary

PostPosted: Fri Aug 08, 2014 3:48 am    Post subject: Reply with quote  Mark this post and the followings unread

Askeladd wrote:
(why are you still on XP??)


Anyone using earlier than 7 year old hardware can't run Win7. Keep in mind, not everyone around runs PCs with 4 GB RAM or more. I, for example with my Athlon II x3 450 and my 2 GB RAM, already cursed myself enough times to go with Win7 because the benefits didn't worthed it in the end.

Not to mention zsu, who still is around with Win2000.

_________________
"If you didn't get angry and mad and frustrated, that means you don't care about the end result, and are doing something wrong." - Greg Kroah-Hartman
=======================
Past C&C projects: Attacque Supérior (2010-2019); Valiant Shades (2019-2021)
=======================
WeiDU mods: Random Graion Tweaks | Graion's Soundsets
Maintainance: Extra Expanded Enhanced Encounters! | BGEESpawn
Contributions: EE Fixpack | Enhanced Edition Trilogy | DSotSC (Trilogy) | UB_IWD | SotSC & a lot more...

Back to top
View user's profile Send private message Visit poster's website ModDB Profile ID
Banshee
Supreme Banshee


Also Known As: banshee_revora (Steam)
Joined: 15 Aug 2002
Location: Brazil

PostPosted: Fri Aug 08, 2014 6:17 am    Post subject: Reply with quote  Mark this post and the followings unread

I run an one year old PC with Windows XP 64bits (which, in my opinion is faster than any newer crap created by Microsoft, it has a more friendly UI for PCs and it is much less bureaucratic). It's up to people's taste. I know I'll eventually have to abandon Windows XP, but I still prefer it over Windows 7 (2nd in preference), Windows 8 (3rd) and Windows Vista (why did MS create that crap?).

Back to top
View user's profile Send private message Visit poster's website Skype Account
E1 Elite
General


Joined: 28 May 2013

PostPosted: Fri Aug 08, 2014 7:09 am    Post subject: Reply with quote  Mark this post and the followings unread

Changed the strings.ini to suit TS. Attaching it.

Just opened the vanilla TS rules and ai.ini and saved as ai2.ini. Several discrepancies found.
- it adds MindControlDecision=0, UseTransportOrigin=no for every teamtype and makes House=<none>
- it changed the Group=-40094 to Group=-1 automatically
- it changes the cash value for apc/engineer steal money in several AITriggers automatically

These have to resolved before this tool can be used. It is better to make the strings.ini selectable depending
on game YR/TS before the rules or ai.ini is loaded.



ForTS.zip
 Description:
strings.ini for TS

Download
 Filename:  ForTS.zip
 Filesize:  3.52 KB
 Downloaded:  52 Time(s)


JustSave.rar
 Description:
Discrepancies

Download
 Filename:  JustSave.rar
 Filesize:  65.09 KB
 Downloaded:  47 Time(s)


Back to top
View user's profile Send private message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Fri Aug 08, 2014 10:10 am    Post subject: Reply with quote  Mark this post and the followings unread

Thanks for the modified strings.ini. I'll add in a way to set AIEdit to TS or RA2 mode.

Assuming the tags MindControlDecision and UseTransportOrigin are ignored in TS I'll keep it like this for now since it won't affect the game.

Is the House= tag used in TS? Deezire's AI guide states that it is only useful in map files, which is why I left it out of the UI.

I fixed the bug where Group= wasn't saved on TaskForces.

Can you give me an example of the changing cash value because I don't know what you are referring to? I guess this is one of those AITrigger parameters that is unused in RA2?

Back to top
View user's profile Send private message
E1 Elite
General


Joined: 28 May 2013

PostPosted: Fri Aug 08, 2014 12:36 pm    Post subject: Reply with quote  Mark this post and the followings unread

JustSave.rar attachment has all you need for comparison. AITrigger cash changes are also in it.
Compare ai.ini (vanilla) with ai2.ini (changed). Included rules.ini also, so that you can test it for yourself.

But why would anyone want RA2 tags in TS ai.ini, they have to be removed. Just saving shouldn't do all those
changes as well.

Back to top
View user's profile Send private message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Sat Aug 09, 2014 2:53 pm    Post subject: Reply with quote  Mark this post and the followings unread

I updated to version 1.03. The following changes were made:

Quote:
- Can now load AI in TS or RA2 mode.
- TeamTypes House= tags are now editable since it is used in TS.
- Enlarged the editor window.
- Separated config in two files for RA2 and TS.
- Lowered platform requirements to .NET 2.0.
- Bugfix: Building offset 262144 added.
- Bugfix: Group= tags on TaskForces and TeamTypes are now correctly loaded and saved.
- Bugfix: Now correctly loads/saves Trigger amounts.


E1 Elite, there is one small issue with your rules which is that the GDI and Nod Helipads both have the exact same name (Name= tag). The editor cannot differentiate the two because it uses the name from the dropdown list to lookup the ID. I suggest renaming those buildings to "GDI Helipad" and "Nod Helipad". This should not be an issue since that naming scheme is already used for other buildings. You should also change the the name of the unloading harvester (HORV) for the same reason, like "Harvester (Unloading)" or something.

The RA2 tags are still saved for TS AI.inis because it has no effect at all on the game and it is easier than modifying the editor for this special case. Besides, the RA2 AI.ini contains IonImmune tags which are not used either.

Back to top
View user's profile Send private message
E1 Elite
General


Joined: 28 May 2013

PostPosted: Sat Aug 09, 2014 4:58 pm    Post subject: Reply with quote  Mark this post and the followings unread

The shared rules.ini is from vanilla TS and names are like that in vanilla TS.

As you are able to differentiate between TS and RA2, I would still suggest to remove the RA2 tags from TS ai.ini,
even if it may not be easier or may take some effort coding wise.

Not sure on TS [Conditions], X=Neutral owns AMOUNT of TECH TYPE, X to be 5 or 7. Never seen its usage,
but I would keep it 7 instead of 5.

Back to top
View user's profile Send private message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Sat Aug 09, 2014 5:14 pm    Post subject: Reply with quote  Mark this post and the followings unread

Actually I wrote the editor in such a way that it doesn't have to differentiate between RA2 and TS, other than loading a different config file.

The numbering is meaningless, only the order matters. X=Neutral.. is treated as #5 regardless.

Back to top
View user's profile Send private message
E1 Elite
General


Joined: 28 May 2013

PostPosted: Sat Aug 09, 2014 5:37 pm    Post subject: Reply with quote  Mark this post and the followings unread

As you take -1 for no condition, likewise 7 should be taken instead of 5 in this case.

On TriggerTypes screen, Weightage propability, Min/Max probability should be renamed to
Starting Weightage, Minimum Weightage and Maximum Weightage.

Back to top
View user's profile Send private message
Wolfsangel
Cyborg Soldier


Joined: 25 Jul 2014
Location: Unkown

PostPosted: Sat Aug 09, 2014 8:18 pm    Post subject: Reply with quote  Mark this post and the followings unread

How can I fix this ?



Ads&#305;z.png
 Description:
 Filesize:  19.88 KB
 Viewed:  67669 Time(s)

Ads&#305;z.png



_________________
Call me as " Xenaga "

Back to top
View user's profile Send private message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Sat Aug 09, 2014 8:22 pm    Post subject: Reply with quote  Mark this post and the followings unread

It's impossible to tell if you don't send me your rules and ai inis. Either your AI ini is malformed (which you have to correct manually first) or some of your entries are referring to non-existent TechnoTypes. I haven't written the code to properly handle errors like this yet.

Back to top
View user's profile Send private message
Wolfsangel
Cyborg Soldier


Joined: 25 Jul 2014
Location: Unkown

PostPosted: Sat Aug 09, 2014 8:29 pm    Post subject: Reply with quote  Mark this post and the followings unread

Yeah, Thanks for information, problem is my ai files

Solved.



1.png
 Description:
 Filesize:  25.1 KB
 Viewed:  67662 Time(s)

1.png



_________________
Call me as " Xenaga "

Back to top
View user's profile Send private message
E1 Elite
General


Joined: 28 May 2013

PostPosted: Sun Aug 10, 2014 7:28 am    Post subject: Reply with quote  Mark this post and the followings unread

E1 Elite wrote:
As you take -1 for no condition, likewise 7 should be taken instead of 5 in this case.

On TriggerTypes screen, Weightage propability, Min/Max probability should be renamed to
Starting Weightage, Minimum Weightage and Maximum Weightage.


Or could also use for TS.ini:

5=Unused
6=Unused
7=Neutral owns AMOUNT of TECH TYPE

Back to top
View user's profile Send private message
Crimsonum
Seth


Joined: 14 Jul 2005
Location: Fineland

PostPosted: Sun Aug 10, 2014 8:45 am    Post subject: Reply with quote  Mark this post and the followings unread

Banshee wrote:
I run an one year old PC with Windows XP 64bits (which, in my opinion is faster than any newer crap created by Microsoft, it has a more friendly UI for PCs and it is much less bureaucratic). It's up to people's taste. I know I'll eventually have to abandon Windows XP, but I still prefer it over Windows 7 (2nd in preference), Windows 8 (3rd) and Windows Vista (why did MS create that crap?).


Hey, my desktop PC has had Vista for 6 years and it's worked fine #Tongue

Keep up the good work, Askeladd! Would it be possible to replace the editor's dependency on an object's Name= flag with a section ID check? In other words, the editor would check the section IDs but display the Name= value. The game allows for multiple TechnoTypes with the same Name= as demonstrated in the vanilla TS rules.ini, but two TechnoTypes cannot have the same section ID (e.g. [HARV] and [HORV] both have the same Name= flag value). Unlike in RA2, the TS engine uses the Name flag for the name that's displayed ingame, so having all Name flags unique might limit certain game elements (lore, deception tactics, etc.).

_________________


Back to top
View user's profile Send private message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Sun Aug 10, 2014 9:44 am    Post subject: Reply with quote  Mark this post and the followings unread

Another day, another update:
Quote:
v1.04
- TechnoType names now also display ID to differentiate ones with the same name.
- Editor warns if TaskForce contains reference to unit not in rules.
- Minor edit to TS config Conditions.

Back to top
View user's profile Send private message
E1 Elite
General


Joined: 28 May 2013

PostPosted: Sun Aug 10, 2014 4:00 pm    Post subject: Reply with quote  Mark this post and the followings unread

Nice work.

Features
- Option in ini to set default yes/no for boolean cases like Available in Skirmish could be checked by default when creating new. Or weights are set to 50 by default etc.
- Mentioned earlier - clicking on a script id/taskforce on teamtype screen could show its script/taskforce screen.

Some changes (Attaching changed config ini files)
- The [Offsets] is same for RA2 as well, so can be made like TS in RA2.ini.
- [Conditions] can be made in RA2.ini as well for -1=No Condition
- 49,0 script could use additional info in both TS/RA2 -
49=Repeat Until Success,None,Instructs the taskforce to continually execute the previous action until it is unable to. Executing this script just once makes its AITrigger successful - used in success/failure delta calculations.
- 2=Go Bezerk,None,Causes cyborgs to go bezerk. (Doesn't work).



config_inis.zip
 Description:
Changes in RA2,TS inis

Download
 Filename:  config_inis.zip
 Filesize:  7.1 KB
 Downloaded:  57 Time(s)


Back to top
View user's profile Send private message
Crimsonum
Seth


Joined: 14 Jul 2005
Location: Fineland

PostPosted: Sun Aug 10, 2014 4:45 pm    Post subject: Reply with quote  Mark this post and the followings unread

"- 2=Go Bezerk,None,Causes cyborgs to go bezerk. (Doesn't work). "

What if you enable the BerzerkAllowed flag at [CombatDamage] in rules.ini? Maybe it allows this script to work.

_________________


Back to top
View user's profile Send private message
E1 Elite
General


Joined: 28 May 2013

PostPosted: Sun Aug 10, 2014 4:51 pm    Post subject: Reply with quote  Mark this post and the followings unread

BerzerkAllowed only allows for human player to work at half damage, not for AI.

Back to top
View user's profile Send private message
Crimsonum
Seth


Joined: 14 Jul 2005
Location: Fineland

PostPosted: Sun Aug 10, 2014 6:15 pm    Post subject: Reply with quote  Mark this post and the followings unread

That makes no sense design-wise, since the berzerk cyborgs will attack all, even friendly units. Why would they code such feature in only for the human player?

_________________


Back to top
View user's profile Send private message
E1 Elite
General


Joined: 28 May 2013

PostPosted: Mon Aug 11, 2014 2:23 am    Post subject: Reply with quote  Mark this post and the followings unread

BerzerkAllowed should have been system-wide, that was my assumption as well earlier. But it works
for human player, not for AI. On the same map, it used to work for human player and not for AI even
when the enemy cyborgs were in red and crawling, even with Go Berzerk script (2,n).

I have seen script 2,n in very old documentations like
2,n = Change grouping to, n = grouping (SHOULD BE AVOIDED) where n was from -1 to 13.

So, not sure what exactly script 2,n does, but certainly it doesn't work as Go Berzerk.

Back to top
View user's profile Send private message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Wed Aug 13, 2014 10:48 am    Post subject: Reply with quote  Mark this post and the followings unread

Update:
Quote:
v1.05
- Super-duper new icon!
- Minor edits to config files.
- Added buttons to jump to referenced AI types.

Back to top
View user's profile Send private message
Parasite03
Cyborg Artillery


Also Known As: ZivDero
Joined: 23 Jul 2013
Location: Russia

PostPosted: Wed Aug 13, 2014 5:16 pm    Post subject: Reply with quote  Mark this post and the followings unread

Thi needs to become a torrent so it autohashes and updates. Or it needs an autoupdate feature.

_________________
DarkVen9109 wrote:
What in the name of insanity is this? I FRICKING LOVE THIS LOGICCCC!!!!!!!!!!!!OOOOOOOOHEEAWWWWWWWWWWWYAAAAAAAAAAAAAAAAAWWWWWW PEW PEW PEW PEW BOOM BOOM BOOM!! Nice I love this!!!! Ferriswheel bomb, Dive bomb. New Logic discovered thanks to Kenosis Very Happy

_________________

Back to top
View user's profile Send private message
E1 Elite
General


Joined: 28 May 2013

PostPosted: Mon Sep 01, 2014 3:24 pm    Post subject: Reply with quote  Mark this post and the followings unread

AIEdit v1.0.5.1
- removed the writing of RA2YR tags of MindControlDecision and UseTransportOrigin to
TS ai.ini TeamTypes.

@Askeladd
Went through the AIEdit source code of v1.0.5 yesterday. Did minor change to remove RA2
tags that was getting added to TS ai.ini. Will feel comfortable if you review it and merge it if
you like. If you have any objections, let me know. Source code change over ver 1.0.5 is
included in the attachment.



AIEdit1051.rar
 Description:
Ver 1.0.5.1

Download
 Filename:  AIEdit1051.rar
 Filesize:  87.51 KB
 Downloaded:  104 Time(s)


Back to top
View user's profile Send private message
Askeladd
Light Infantry


Joined: 29 Dec 2013

PostPosted: Tue Sep 02, 2014 8:43 pm    Post subject: Reply with quote  Mark this post and the followings unread

Thanks I'll check it out.

Back to top
View user's profile Send private message
zlixine}
Guest




PostPosted: Thu Sep 11, 2014 12:40 pm    Post subject: Reply with quote  Mark this post and the followings unread

at last new one clap clap I approve thanks

Back to top
219307456222
Guest




PostPosted: Sun Dec 14, 2014 8:24 am    Post subject: Reply with quote  Mark this post and the followings unread

Hello, massive thanks for the AI Editor, I just noticed that the old one by Dwhatever tells me there is invalid XML syntax and doesn't start up.

However, this new editor fails when I try to load my AI file saying that the "String" parameter cannot be null.
What do I have to fix in my AI file?

Can't drop notepad just yet, huh?  Haha.

Back to top
219307456222
Guest




PostPosted: Sun Dec 14, 2014 8:35 am    Post subject: Reply with quote  Mark this post and the followings unread

I should have specified: my custom AI file, the copy I keep of the original loads without issues.

Back to top
E1 Elite
General


Joined: 28 May 2013

PostPosted: Wed Feb 04, 2015 6:03 am    Post subject: Reply with quote  Mark this post and the followings unread

E1 Elite wrote:
- [Offsets] - My understanding of it is, 0 - just refer the building
65536/131072 - for low/high threat, 196608/262144 - for near/far building

That understanding was wrong. BuildingTypes index + 262144 does not work.

Structure number logic is:
0 + index = Building with least threat
65536 + index = Building with highest threat
131072 + index = Nearest building
196608 + index = Farthest building

Corrected INI files are attached (applicable to both v1.05 and v1.0.5.1). Also truncated script action types
of 53 and above for TS.

Note: For script entries that uses structure number, first use add/insert and then select and modify the
desired offset from the dropdown for each entry.



ConfigFiles.zip
 Description:

Download
 Filename:  ConfigFiles.zip
 Filesize:  6.99 KB
 Downloaded:  41 Time(s)


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


Joined: 09 Feb 2015

PostPosted: Thu Feb 12, 2015 3:28 pm    Post subject: Reply with quote  Mark this post and the followings unread

Soooo I just tried this, I get a crash with a "null string" error... any idea?

_________________
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   Reply to topic Page 1 of 4 [186 Posts] Goto page: 1, 2, 3, 4 Next
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
Quick Reply
Username:


If you are visually impaired or cannot otherwise answer the challenges below please contact the Administrator for help.


Write only two of the following words separated by a sharp: Brotherhood, unity, peace! 

 
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


Powered by phpBB © phpBB Group

[ Time: 0.2477s ][ Queries: 15 (0.0167s) ][ Debug on ]