GameGuru Classic

GameGuru Classic

Fomin Jan 6, 2019 @ 10:04am
AI for non combat friendly
Hi,

Since the update, some of the AI seems to have changed. I want to have characters who will stay in one general area (as opposed to running into walls) without attacking the player character but will still have standard idle animations so they won't look like statues. If I recall correctly, the neutral AI used to do this but now it just turns characters into statues.

Civilian AI is no good because then the characters run against the wall when they hear gunfire which looks really stupid.
Last edited by Fomin; Jan 6, 2019 @ 10:04am
< >
Showing 1-15 of 25 comments
synchromesh  [developer] Jan 6, 2019 @ 5:26pm 
I did do a vid but only got round to uploading yesterday ..
Note health is set very high .. Im not trying to complete it just showing that AI can no longer see you or shoot through walls .. They also run for cover and move about dodging your movement. and are a hell of a lot smarter .. Sorry if its a bit jerky in places thats the recording software. Smooth as silk when i tried it ..

Getting characters to ignore you has always been a simple task of setting the view range and cone angle in the properties to about 2 and they do have idle animations.
As for the Ai Neutral that doesnt work at the moment with the new system but there are far better free Civilian scripts available anyway

https://www.youtube.com/watch?v=IxOZ_xvKhto
Last edited by synchromesh; Jan 6, 2019 @ 5:54pm
Fomin Jan 6, 2019 @ 6:00pm 
Does anyone know of a script for someone who won't attack OR run away? I used to use AI neutral for that but since the update, that doesn't work anymore.
Fomin Jan 6, 2019 @ 6:11pm 
Originally posted by synchromesh:
I did do a vid but only got round to uploading yesterday ..
Note health is set very high .. Im not trying to complete it just showing that AI can no longer see you or shoot through walls .. They also run for cover and move about dodging your movement. and are a hell of a lot smarter .. Sorry if its a bit jerky in places thats the recording software. Smooth as silk when i tried it ..

Getting characters to ignore you has always been a simple task of setting the view range and cone angle in the properties to about 2 and they do have idle animations.
As for the Ai Neutral that doesnt work at the moment with the new system but there are far better free Civilian scripts available anyway

https://www.youtube.com/watch?v=IxOZ_xvKhto

Thanks! What AI did you use for the enemies here? Can you post a link? The AI I use is Corrosion's Enhanced AI but those enemies still act brain dead and head butt walls until I walk around and kill them.
synchromesh  [developer] Jan 6, 2019 @ 6:13pm 
The AI used is the Default stock now .... Thats what we have been trying to tell you its been improved and is still in progress ... Here it is from an isometric view ..

https://www.youtube.com/watch?v=uVmGd1y5GhE
Last edited by synchromesh; Jan 6, 2019 @ 6:14pm
Fomin Jan 6, 2019 @ 6:59pm 
Originally posted by synchromesh:
The AI used is the Default stock now .... Thats what we have been trying to tell you its been improved and is still in progress ... Here it is from an isometric view ..

https://www.youtube.com/watch?v=uVmGd1y5GhE

Wow! The default AI is better than Corrosion's now. In fact. It's so good I will need to rebalance all my levels now to take into account the fact that enemies can defend themselves (which they couldn't before even with corrosion's AI.)

On a related note, is there any plan to make AI Neutral functional again? The Civilian AI runs away so if you use that, your characters will just flee at the start of a battle. That doesn't really work for a lot of scenarios.
Last edited by Fomin; Jan 6, 2019 @ 8:16pm
myke1net Jan 6, 2019 @ 8:50pm 
Classics\ai_classiccharacter_unarmed.lua
This script still has the classic characters standing, rotating to the player when in range, and running the idle animation constantly when in range.

See if this script will worrk for you. Dont forget to change the animation frames in this statement to match your characters idle animation that you want.

SetAnimationFrames(211,232)

It is in the _init function of the script.
Fomin Jan 6, 2019 @ 9:32pm 
Originally posted by myke1net:
Classics\ai_classiccharacter_unarmed.lua
This script still has the classic characters standing, rotating to the player when in range, and running the idle animation constantly when in range.

See if this script will worrk for you. Dont forget to change the animation frames in this statement to match your characters idle animation that you want.

SetAnimationFrames(211,232)

It is in the _init function of the script.

Thanks for the tip! I already tried that... the characters point invisible guns and constantly twitch.

Do you know how to find the correct animation frames? I made characters with the character creater and I want them to act like the unarmed classic characters rather than twitiching and pointing invisible guns.

I found the place in the script which reads "SetAnimationFrames(211,232)" but I am not sure what values to change to make the script work with characters from the character creator.
Last edited by Fomin; Jan 6, 2019 @ 10:18pm
CheckingMylootz Jan 7, 2019 @ 12:31am 
Originally posted by Zidane:
Originally posted by synchromesh:
I did do a vid but only got round to uploading yesterday ..
Note health is set very high .. Im not trying to complete it just showing that AI can no longer see you or shoot through walls .. They also run for cover and move about dodging your movement. and are a hell of a lot smarter .. Sorry if its a bit jerky in places thats the recording software. Smooth as silk when i tried it ..

Getting characters to ignore you has always been a simple task of setting the view range and cone angle in the properties to about 2 and they do have idle animations.
As for the Ai Neutral that doesnt work at the moment with the new system but there are far better free Civilian scripts available anyway

https://www.youtube.com/watch?v=IxOZ_xvKhto

Thanks! What AI did you use for the enemies here? Can you post a link? The AI I use is Corrosion's Enhanced AI but those enemies still act brain dead and head butt walls until I walk around and kill them.

That's the default AI that i've told you about in multiple threads now :)

Originally posted by Zidane:
Originally posted by myke1net:
Classics\ai_classiccharacter_unarmed.lua
This script still has the classic characters standing, rotating to the player when in range, and running the idle animation constantly when in range.

See if this script will worrk for you. Dont forget to change the animation frames in this statement to match your characters idle animation that you want.

SetAnimationFrames(211,232)

It is in the _init function of the script.

Thanks for the tip! I already tried that... the characters point invisible guns and constantly twitch.

Do you know how to find the correct animation frames? I made characters with the character creater and I want them to act like the unarmed classic characters rather than twitiching and pointing invisible guns.

I found the place in the script which reads "SetAnimationFrames(211,232)" but I am not sure what values to change to make the script work with characters from the character creator.

That's because the soldiers default idle is for some reason an aiming idle, which is something that is annoying about the new AI, for some reason when Lee turned it modular he removed the two stage idle process it used to have (soldiers used to stand in a normal idle until alerted at which point they used to switch to aiming idle, and then when you got closer start attacking, now they just stand and aim).

In your folder where your default soldiers are, you will find with the uber soldier a separate text file that lists all of the anims available, they are all for the uber soldier, but the first half or so also apply to all the other soldiers and the character creator characters, as they use a truncated version of the same animation set, so you should be able to find an idle in there that isn't aiming.
Last edited by CheckingMylootz; Jan 7, 2019 @ 12:38am
Fomin Jan 7, 2019 @ 12:39am 
Originally posted by Belidos:
Originally posted by Zidane:

Thanks! What AI did you use for the enemies here? Can you post a link? The AI I use is Corrosion's Enhanced AI but those enemies still act brain dead and head butt walls until I walk around and kill them.

That's the default AI that i've told you about in multiple threads now :)

Yes it certainly is change for the better with ONE notable exception. The Neutral AI doesn't work anymore and having made a game with lots of friendly NPCs, I am now in a bad position since all my friendly NPCs just freeze like statues. Using the Civilian AI from the forums doesn't fix that since they now run like scared children which doesn't work for the story at all.

Would you by any chance know of an AI that would work for friendly NPCs who don't attack OR run away from the player to take the place of the Neutral AI that doesn't work anymore?
synchromesh  [developer] Jan 7, 2019 @ 1:36am 
I did answer that in my first post ...
If you want them to just stand and idle ignoring you then set the view distance and cone angles to very low .. 1 or 2 should do it .... they will then stand in the idle position with animations.
NOTE... All accept the masked civilian who is broken at the moment.

https://youtu.be/9vYnCOPHBtU
Last edited by synchromesh; Jan 7, 2019 @ 2:14am
synchromesh  [developer] Jan 7, 2019 @ 2:25am 
Wow! The default AI is better than Corrosion's now. In fact. It's so good I will need to rebalance all my levels now to take into account the fact that enemies can defend themselves
Going back to the AI yes it will probably be best to redo your level to take into account there new abilities .. Those videos above are also using Cover zones as well so where ever you put one is where the AI can take cover ... Still loads of sratagy and time required to get the ingredients right but worth it for good results .. Its still not perfect ...They can still get stuck in very tight area's but the trick is to avoid those or use other free scripts around that defend and not run about :)
Last edited by synchromesh; Jan 7, 2019 @ 3:49am
CheckingMylootz Jan 7, 2019 @ 4:24am 
If you want a passive NPC, try this one, not sure if it still works, but as far as i know it should do ...

https://forum.game-guru.com/thread/220029#msg2605361
Fomin Jan 7, 2019 @ 5:41am 
Originally posted by synchromesh:
I did answer that in my first post ...
If you want them to just stand and idle ignoring you then set the view distance and cone angles to very low .. 1 or 2 should do it .... they will then stand in the idle position with animations.
NOTE... All accept the masked civilian who is broken at the moment.

https://youtu.be/9vYnCOPHBtU

Perhaps I should have been more clear. I wanted them to face the player as the old neutral AI did without attacking or running away. In lieu of a dialogue system, I put story into my game by adding NPCs and text zones so that when the player approached a character, the character would face the player and "say" something which was actually the text zone. This doesn't work if they attack the player or run away however and if they completely ignore the player, it doesn't work either.

In the past, AI Neutral worked fine for this. Now however, I can't get it to work.
Last edited by Fomin; Jan 7, 2019 @ 5:41am
Fomin Jan 7, 2019 @ 5:42am 
Originally posted by Belidos:
If you want a passive NPC, try this one, not sure if it still works, but as far as i know it should do ...

https://forum.game-guru.com/thread/220029#msg2605361

Thanks! I'll try it right away!
Fomin Jan 7, 2019 @ 6:59am 
Originally posted by Belidos:
If you want a passive NPC, try this one, not sure if it still works, but as far as i know it should do ...

https://forum.game-guru.com/thread/220029#msg2605361


Thanks!

It kind of works but if you use it on a character set for one of the weapons pose presets (pistol, sword, etc.) they still move as if they have an invisible weapon even when unarmed. If you use it for a chaeacter with no weapons pose, they just glide around in a t-pose.

I remember before the AI neutral worked fine. I was even able to use it to make friendly zombies...

Is there any way to set an "unarmed" default character pose so that I can have a passive character who isn't waving an invisibe gun in my face?
Last edited by Fomin; Jan 7, 2019 @ 7:00am
< >
Showing 1-15 of 25 comments
Per page: 1530 50

Date Posted: Jan 6, 2019 @ 10:04am
Posts: 25