Jump to content
Sign in to follow this  
jedra

Enhanced Skills Slider WIP

Recommended Posts

Jedra's Enhanced Skills Slider [W.I.P]

With some of the changes to the way precision-enemy and precision-friendly work in the 1.6 patch, I started to look at how the AI works in Arma 2, paying particular attention to the Skills Array. In various bouts of testing I found that the skills array had a drastic effect on the way the AI behaved. I came to the conclusion that just having a slider for overall skill was not giving the player, or server admin the fine control they needed. Hence the Enhanced Skills Slider.

Pretty Pictures

skills_slider_full_small.jpg

newMenu.jpg

Aim

The aim is for it to work in both single player and multiplayer and allow the player (or admin in MP) to change the skill array values for units/groups/sides on the fly. So, if a game is getting pretty tough, everyone is having their arses kicked, then the admin can adjust the skills of the AI on the fly with a fine level of detail.

Progress

So far it's in early alpha and is working in Single player on single units. I need to expand this to groups and all units before tackling getting it working in multi-player.

I am very happy with how it changes things on the fly in single player.

Addon or Script?

I am hoping to release it as both a signed addon and a script.

ETA?

When it's done :p Seriously, I have never worked with dialogues before, so I had to learn how to do it - I am getting there. Also I suspect a few 'gotchas' in the MP side of things, but I don't see any reason why I shouldn't get it working. Hopefully a week or so should see me a fair way doen the line.

WTF?

If anybody thinks this is a crazy idea (or even a good one!) then I would be happy to hear. Feel free to ask any questions (as no doubt I will be asking you some along the way!) or make any suggestions.

UI design is not my skill (Jedra setskill ["UIdesign", 1.0] didn't work for me!), so it will probably look butt-ugly, so any suggestions about how to make it better would be great once I get some more screen shots up.

That's it for now!

Edited by Jedra
New menu teaser!

Share this post


Link to post
Share on other sites

Very cool. Do you think you could have settings embedded in a userconfig that loads when you enter a mission / place a module?

Share this post


Link to post
Share on other sites

Sounds like an awesome idea! Now no one can complain about the AI spotting skill etc because they can just change it

Share this post


Link to post
Share on other sites
Very cool. Do you think you could have settings embedded in a userconfig that loads when you enter a mission / place a module?

@ Fox '09 - Hi, I will look into this, although Robalo's ASR_AI already does this so it may be able to just run alongside that amazing mod. He put a lot of effort into setting up the skill levels for different classes and it doesn't feel right just to do the same thing. The only issue with running alongside ASR_AI is that we both need to override CfgAISkill - so that's something I need to look at. This mod will not do a lot of the cool stuff that ASR_AI does, and it would be a shame it they were not compatible.

There may be some mileage in this though, so I will look at it once I have got the MP side working - maybe version two in a few more weeks!

@Angus S - Yes, the idea is that a big mission isn't lost and abandoned halfway through just because the AI insurgents are snipers with 20 year old rusty AK's! This seems to be the biggest problem with recent AI skill changes and it has taken the fun out of the game for a lot of people.

Share this post


Link to post
Share on other sites

This is looking good Jedra - even the UI is simple but functional.

What WOULD be good is to have a further option to globally change the AI in the dialog OR to have something that raises or lowers an individual slider (globally) by 0.1 for instance? So if the team are doing too well against the AI, a quick click and it raises all AI (that slider) by 0.1 . I could imagine AI1 on SpotTime 0.5 AI2 on SpotTime 0.3, but at a click both are raised by 0.1 (without going into each individual AIs stats) Possible ?

Whatever happens .... keep up the good work.

Share this post


Link to post
Share on other sites

@Kremator - yes, it's possible. I have implemented it so that you can set a value and apply it to the ALL EAST UNITS (or West etc). So if you wanted to set spottime for all east units to 0.5, you select 'All Units' in the East List, move the Spot Time slider to 0.5 and hit apply. This will change just the Spot Time for all East Units. You can do the same for Groups.

Share this post


Link to post
Share on other sites

Nice idea Jedra!

Hope you don't mind a suggestion.... having a way to set min and max values on each skill and then let the script randomize between the two on all groups/units, that way no AI runs the same skills and it will be very unpredictable.

Anyway, keep it up!

/KC

Share this post


Link to post
Share on other sites
Nice idea Jedra!

Hope you don't mind a suggestion.... having a way to set min and max values on each skill and then let the script randomize between the two on all groups/units, that way no AI runs the same skills and it will be very unpredictable.

Anyway, keep it up!

/KC

Nice idea - I will look at adding this in. Thanks!

Share this post


Link to post
Share on other sites

a) AI is local to the owner/group leader. Keep that in mind for MP.

b) If you want to restrict it to server admin only, check the DevCon for the code.

Share this post


Link to post
Share on other sites
a) AI is local to the owner/group leader. Keep that in mind for MP.

b) If you want to restrict it to server admin only, check the DevCon for the code.

a) Thanks for the reminder - I have a few leads as to how to handle this.

b) I am glad you said that :p - me, breaking open your pbo today, nope, must have been someone else! It was the big 'Run on Server' button that gave me the idea!

Definitely Admins only, otherwise it would just be chaos. I guess someone will break it open to de-restrict it, but as it will be signed, they shouldn't be able to use a modified version.

Share this post


Link to post
Share on other sites

This looks awesome although I'm sad to see that it couldn't be implemented by BIS (it SO fundamental to a good gaming experience).

Am I right in thinking that this is a GUI to the values store in the arma2oa.cfg file?

Also, am I right in guessing that this does not significantly impact framerates?

Finally, I appreciate your efforts to make this compatible with Robalo's ASR AI mod as it has become practically indispensable.

Share this post


Link to post
Share on other sites
This looks awesome although I'm sad to see that it couldn't be implemented by BIS (it SO fundamental to a good gaming experience).

Am I right in thinking that this is a GUI to the values store in the arma2oa.cfg file?

Also, am I right in guessing that this does not significantly impact framerates?

Finally, I appreciate your efforts to make this compatible with Robalo's ASR AI mod as it has become practically indispensable.

It doesn't mess with the config, it directly manipulates the games skill matrix I will obviously need to test how setting the skills in the config affect it, but the affect will be relative if any so the sliders will still be useful.

Manipulating the sliders does have an effect in game (thanfully as the last two days would have been wasted otherwise!). I'll try an post an alpha test video later showing the effect.

My aim is to make it compatible with ASR_AI if I can, as I use it all the time too!!

EDIT ---> As for performance, it shouldn't be affected at all. At the end of the day, all it really does is set values, it is not manipulating the AI in anyway.

Edited by Jedra

Share this post


Link to post
Share on other sites

Here is a short video of the skills slider in action.

Keep your eye on the score (top-right) for BadGuy1 as it's his skills I will be manipulating. The right hand score (in green for those of you watching in black and white) is the percentage of shots he hits with.

To begin with I set the skills for Aiming Accuracy, Aiming Shake and Aiming Speed really high. I then fire off a shot to get their attention.

Watch how BadGuy1 starts hitting me with just about every shot.

I then use the skills slider to reduce the same three parameters down to a silly level. Notice how then he starts missing a lot and his hit percentage goes down.

I then put them up again, and his hit percentage starts to rise again.

Best viewed in full HD, full screen.

Cmm7gqsl8SM

Share this post


Link to post
Share on other sites

yeah looking really good - more power to your elbow sir

Share this post


Link to post
Share on other sites

I have a question for people who may be interested in using the mod;

Should it be;

1. A client side addon. The advantage being that it will be simple to 'attach' to the player, and all I really have to do is check that they are admin (the tool will announce its use and also log the uid using it in the server RPT). It will also be easier to use alongside other missions as it's basically attached to the client. Potential disadvantage is that I have to shift the skill values from the server to the client to process them - at the moment I am not quite sure how I am going to do that.

2. A Server side addon. The advantage being that server admins can choose to add it or not. The disadvantage is that I will need to figure out how to attach it to a player who is admin and cope with stuff like JIP etc. I guess this might be harder to make it SP compatible and I am not sure of the pitfalls here.

I am more tempted to go with the first option as I think it may be easier and more flexible?

Unfortunately I have somewhat of a mental block when it comes to coding for multiplayer. I always end up sending my brain in circles even though I have a fair grasp of the theory. I think I understand it, then I make a mission where something happens that seems to undermine everything I thought I knew! I am determined to finally fully understand it this time.

Any thoughts you have would be good!

Share this post


Link to post
Share on other sites

This is all lost to me - client/server etc. HOWEVER if you have something client how can you control server made AI? What would happen to how others see the AI?

Regarding the admin side of things, this sounds like something akind to MCC or VTS - will be interested to see how you sort it. Anyway - whatever is decided, just ask if you need something tested (local and dedi) mate.

Share this post


Link to post
Share on other sites
This is all lost to me - client/server etc. HOWEVER if you have something client how can you control server made AI? What would happen to how others see the AI?

Regarding the admin side of things, this sounds like something akind to MCC or VTS - will be interested to see how you sort it. Anyway - whatever is decided, just ask if you need something tested (local and dedi) mate.

Thanks for the offer - some testing will be needed further down the line! I can run stuff on the server from the client easily enough (either using something pvpScene pointed me at or CBA). I'm going to have a think about it tonight as to the best approach.

Share this post


Link to post
Share on other sites

Quick Update....

I have now converted the mod so that it is a client-side addon. I have also now got it working in multiplayer (on a dedicated server anyway). It will now apply skill changes to both AI controlled by the server and the AI controlled by connected clients.

To Do :

1. At the moment it can read and display the skills correctly for the server AI and the client AI who is running the addon, it does not however correctly read the skills for AI that are controlled by other connected clients. It can hower apply skills changes to those clients. At the moment I am not sure how to find out which client 'owns' a particular AI.

2. Need to tidy up the UI and add a few more options, including;

3. Ability to add random values across a minimum and maximum range.

4. Ability to alter skills at group level and to whole sides (East, West etc). This should be easy as it's just a case of changing the scope of what I have done already.

5. Thinking about a mini-map. Currently, just seeing the unit names does not give a great idea of where they are. My idea is that when you select a unit (or group) it will show it's position on the minimap (or that of the group leader in the case of a group). Not sure if this may spoil the missions though? Although only Admin will be have access anyway.

6. In the process of getting it working in MP (Dedicated) I broke it's ability to work in SP and LAN (hosted). Need to fix that.

Anyway, it's coming along nicely and should see a release soon. Half-term next week though and I have to look after the kids so mod-making may need to take a back seat for a week.

EDIT --->

In my haste to get out this update I forgot the most important feature I am adding;

At the moment the skill sliders are actuals. Setting a 0.3 accuracy to all EAST units will make all EAST units 0.3. This is probably not always the best way as a blanket skill to all may not be realistic. So, I am adding the ability to affect the units by a percentage as well. This will preserve the differences in the units while allowing them all to be influenced by the sliders. Hope this makes sense!

Edited by Jedra

Share this post


Link to post
Share on other sites

Hi Jedra, Thanks for your work on this. I had stopped playing (I'm SP only) since the 1.6 update do to the AI issues. Looking forward to your MOD

Share this post


Link to post
Share on other sites

Yes I was thinking last night that percentages would be a better way of managing the differing levels of skills between low quality (conscripts) and high trained (spec ops) units.

As for deciding between client and serverside, I'd opt for the simplest, client-side!

Share this post


Link to post
Share on other sites
Yes I was thinking last night that percentages would be a better way of managing the differing levels of skills between low quality (conscripts) and high trained (spec ops) units.

As for deciding between client and serverside, I'd opt for the simplest, client-side!

Well, that's lucky then! Work is now 99% complete on the first (I guess beta) version. I will hopefully get it up here later today if the MP testing goes well and I get the documentation done. It now works in SP, LAN MP and Dedi MP - unless today's testing proves otherwise.

Stay tuned....

Share this post


Link to post
Share on other sites

Pretty slick !

First thing that came to mind when I saw your screenshots was a visual editor for ASR AI's skill levels.

Read from memory -> edit with your UI -> apply and save to clipboard -> paste into userconfig for persistence.

Maybe we can work something out since you already have the UI ;)

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×