UGX-Mods Login

or login with an authentication provider below
Sign In with Google
Sign In with Twitter
Sign In with Discord
Sign In with Steam
Sign In with Facebook
Sign In with Twitch

any help!?

broken avatar :(
Created 7 years ago
by Deleted User
0 Members and 1 Guest are viewing this topic.
2,283 views
broken avatar :(
  • DeletedUser
  • Deleted Member
×
broken avatar :(
DeletedUser
This user is deleted :(
So im having trouble get Actors or Friendly AI like marines and Soviet soldiers to move!

ive only been able to make em move by throwing a grenade near them or using a flamethrower near them!

but i want em to move just like the enemy AI do..

it just seems like axis AI is more advanced tbh

any help on getting friendly AI to move properly and go to cover nodes and stuff?!?!?

this is required for my AI Playground map which ill be releasing here on UGX btw
broken avatar :(
×
broken avatar :(
Location: nlApeldoorn
Date Registered: 17 December 2013
Last active: 1 year ago
Posts
1,187
Respect
1,404Add +1
Forum Rank
Zombie Colossus
Primary Group
Community Scripter Elite
My Groups
More
My Contact & Social Links
More
Personal Quote
It aint much, if it aint Dutch
Signature
×
BluntStuffy's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
Community Scripter Elite Has shown excellence and experience in the area of custom scripting in the UGX-Mods community.
Oil Rig Beta Access
Oil Rig Beta Access
BluntStuffy's Contact & Social LinksBluntstuffy@BluntZombieBluntStuffyStuffyZombie
Have no experience with friendly AI myself, but i think you need some scripts for their behaviour/movement.
Not sure if you could simply do it with nodes in radiant only. At least here's some info on the types of nodes, and prob some more info about AI on that site as well:

http://wiki.modsrepository.com/index.php?title=Call_of_Duty_5:_SP_-_Navigation_Overview
Marked as best answer by Deleted User 7 years ago
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 11 March 2014
Last active: 3 years ago
Posts
264
Respect
Forum Rank
Mr. Elemental
Primary Group
Member
Signature
"Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live."
×
buttkicker845's Groups
buttkicker845's Contact & Social Links
friendly Ai in WAW act wierd

For starters they don't like to move with the command of
Code Snippet
Plaintext
SetGoalPos(mg.pos)
instead try to use
Code Snippet
Plaintext
SetGoalNode(node)
. Also unlike enemy AI friendlies can't be sent to the same node or goal position like you can with enemies. If you send friendlies to the same goal node only one of them will move and the rest will stay, so be sure to make use of
Code Snippet
Plaintext
IsNodeOccupied(node)
.

PS: for enemy AI the function IsNodeOccupied() is always false
Last Edit: August 28, 2017, 07:36:16 pm by buttkicker845
broken avatar :(
  • DeletedUser
  • Deleted Member
×
broken avatar :(
DeletedUser
This user is deleted :(
friendly Ai in WAW act wierd

For starters they don't like to move with the command of
Code Snippet
Plaintext
SetGoalPos(mg.pos)
instead try to use
Code Snippet
Plaintext
SetGoalNode(node)
. Also unlike enemy AI friendlies can't be sent to the same node or goal position like you can with enemies. If you send friendlies to the same goal node only one of them will move and the rest will stay, so be sure to make use of
Code Snippet
Plaintext
IsNodeOccupied(node)
.

PS: for enemy AI the function IsNodeOccupied() is always false


tbh im not experienced when using those lines of code that you sent me m8..can you explain to me how i add them in?

also i know what the nodes do and all and ive managed to get enemy AI to work fine! just friendly ai im having problems with
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 11 March 2014
Last active: 3 years ago
Posts
264
Respect
Forum Rank
Mr. Elemental
Primary Group
Member
×
buttkicker845's Groups
buttkicker845's Contact & Social Links
no problem is is some short descriptions of the functions
Code Snippet
Plaintext
ai SetGoalNode(node);//makes the ai move to a specific pathnode in the world, node is a pathnode or covernode

Code Snippet
Plaintext
if(IsNodeOccupied(node)) //checks to see if a friendly ai is already using this node, returns boolean value

to collect all path, cover, and ai negotiation nodes in the world use
Code Snippet
Plaintext
nodes = level GetAllNodes();
broken avatar :(
  • DeletedUser
  • Deleted Member
×
broken avatar :(
DeletedUser
This user is deleted :(
no problem is is some short descriptions of the functions
Code Snippet
Plaintext
ai SetGoalNode(node);//makes the ai move to a specific pathnode in the world, node is a pathnode or covernode

Code Snippet
Plaintext
if(IsNodeOccupied(node)) //checks to see if a friendly ai is already using this node, returns boolean value

to collect all path, cover, and ai negotiation nodes in the world use
Code Snippet
Plaintext
nodes = level GetAllNodes();

yeah but where do i put these lines of code at? like where in the map GSC? thats the only thing im not sure how to do xD
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 11 March 2014
Last active: 3 years ago
Posts
264
Respect
Forum Rank
Mr. Elemental
Primary Group
Member
×
buttkicker845's Groups
buttkicker845's Contact & Social Links
It would be hard to just tell you where to place these functions since all used for deciding where you want AI to navigate to. The SetGoalNode(node) is for sending the AI to a location after you've decided which node you want to send them to.

If you want to send an AI to an objective you do so by
Code Snippet
Plaintext
//Note: this simply moves an AI to the objective position, doesn't account for the fact that there may already be someone there
nodes = level GetAllNodes();
moveToNode = getClosest(objective.origin, nodes);
ai SetGoalNode(moveToNode);

Need to use to ensure that the AI is able to move to the node, if the node is occupied the AI will not move
Code Snippet
Plaintext
nodes = level GetAllNodes();
moveToNode = getClosest(objective.origin, nodes);
//this will move the AI to node only if it isnt being occupied by another friendly AI
If(!IsNodeOccupied(moveToNode))
{
     ai SetGoalNode(moveToNode);
}

I hope that helps you under stand how to use these functions together to allow your AI to move  :)
broken avatar :(
  • DeletedUser
  • Deleted Member
×
broken avatar :(
DeletedUser
This user is deleted :(
It would be hard to just tell you where to place these functions since all used for deciding where you want AI to navigate to. The SetGoalNode(node) is for sending the AI to a location after you've decided which node you want to send them to.

If you want to send an AI to an objective you do so by
Code Snippet
Plaintext
//Note: this simply moves an AI to the objective position, doesn't account for the fact that there may already be someone there
nodes = level GetAllNodes();
moveToNode = getClosest(objective.origin, nodes);
ai SetGoalNode(moveToNode);

Need to use to ensure that the AI is able to move to the node, if the node is occupied the AI will not move
Code Snippet
Plaintext
nodes = level GetAllNodes();
moveToNode = getClosest(objective.origin, nodes);
//this will move the AI to node only if it isnt being occupied by another friendly AI
If(!IsNodeOccupied(moveToNode))
{
     ai SetGoalNode(moveToNode);
}

I hope that helps you under stand how to use these functions together to allow your AI to move  :)

it does!! thank you so much!!!!!

 
Loading ...