About agent_set_scripted_destination

Users who are viewing this thread

foxyman

Sergeant Knight
Hey guys! I've got a question about the agent_set_scripted_destination.
  When I use it in the battle field, it seems to have some side effects. So I'm here to ask, or clarify, the actual behavior of agents in scripted mode.
  Two things I really want to know:
      Will they attack (melee / ranged)?
      Will they rotate according to the destination?

  And one thing I know is that they won't yell for victory. Oddly that even though some are not in scripted mode, none of them will yell as long as anyone is in scripted mode.
 
foxyman said:
Hey guys! I've got a question about the agent_set_scripted_destination.
  When I use it in the battle field, it seems to have some side effects. So I'm here to ask, or clarify, the actual behavior of agents in scripted mode.
  Two things I really want to know:
      Will they attack (melee / ranged)?
      Will they rotate according to the destination?

  And one thing I know is that they won't yell for victory. Oddly that even though some are not in scripted mode, none of them will yell as long as anyone is in scripted mode.

From what I have heard, they will only blindly move to that spot.  I'm not sure about facing, though I assume they will face the way they are moving.  They will not do any other action until they get to the spot.  I was going to use this in my joust mission_template to move the AI to the right spot, and maybe I still will (since I will be controling if the AI attacks or not).

I don't remember seeing anything that can set they way they are looking, though there should be.  Post if you find it.
 
Thank you for your information ^_^
I'm currently trying to use this to do similar things. In my test, I found that, given close enough distance, melee troops will actively attack, so will the archers facing enemies. The only problem is that, for those archers not facing the enemy side, they just stand there or move.
 
foxyman said:
Thank you for your information ^_^
I'm currently trying to use this to do similar things. In my test, I found that, given close enough distance, melee troops will actively attack, so will the archers facing enemies. The only problem is that, for those archers not facing the enemy side, they just stand there or move.


hmm....  The best thing I can think of is to have your units get the position of the enemy and do a quick loop that will make them take a few steps in that direction.  That way they should face the right way.  You can get an agent's look position, I don't see why you can't set it (other than they don't have an operation I can see).
 
jik said:
foxyman said:
Thank you for your information ^_^
I'm currently trying to use this to do similar things. In my test, I found that, given close enough distance, melee troops will actively attack, so will the archers facing enemies. The only problem is that, for those archers not facing the enemy side, they just stand there or move.


hmm....  The best thing I can think of is to have your units get the position of the enemy and do a quick loop that will make them take a few steps in that direction.  That way they should face the right way.  You can get an agent's look position, I don't see why you can't set it (other than they don't have an operation I can see).

Well... Thanks again. I see that "get_look_position" thing, but thought it's for presetation.....
 
Sorry to hijack the thread. :smile:

Concerning the jousting problem. (I've been lurking a few days now and saw your problem).  Could you just fence in the area the two combatants are supposed to be in? So, have the normal arena floor, and in the center have a long low fence down the center, but then put two more running parallel so it acts like guide rails, and cap off both ends so the knighs have no choice but to go straight.  Maybe then you can let the normal combat ai take over?


- Eck
_____
|K| |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| |K|
|_|_|
K is a spawn points for a Knight, and the lines are the fence rails.
 
I did that, but a few thing happen. 

1.  Sometimes (even with an AI mesh) the AI knight will turn enough towards you to hit the center rail, making him stop.  This is very in frequent if you start charging right away.
2.  When you pass, the AI stops and turns back at you.
3.  He doesn't always take a thrust (though I do have the AI skill level on low)

To get away from this I have tried a few things.  What it has come down to for me is that I will need to control the AI agent.  Since I don't need him to think for himself (in the strike), I can direct him to where he needs to go, and have him thrust his lance when I think it's right.  I'm about to change the AI to force him to run straight to the end.

MY issues are:

Will he be facing him opponent when he strikes?
The animation for the horseback thrust.
The math of the strike timing.

Right now I have 4 entry points.  one for each start, and one for each finish (incase you are watching a joust).

Other issues I want to address is how to know if you hit your opponent's horse, or if you hit your opponent's head.  Neither will be checked (that I know of) if I manage the strikes...
 
Back
Top Bottom