Author Topic: Remove-Goal sexp - does it work?  (Read 2269 times)

0 Members and 1 Guest are viewing this topic.

Offline Black Wolf

  • Twisted Infinities
  • 212
  • Hey! You! Get off-a my cloud!
    • Visit the TI homepage!
Remove-Goal sexp - does it work?
Does this sexp not work, or am I failing to understand how the FS AI thinks. I have ships with orders to attack another ship (Priority 50). When they get too close, they then get given an order to go to a waypoint (Priority 89). When they're far enough away, I use remove-goal to remove the waypoint order. However, they continue on their merry way to the waypoint and don't revert to attacking the first ship until they've completed the waypoint. Which is annoying.

So, my question. Am I using the sexp wrong (If I am, it seems like a pretty useless sexp as I can't see any other way to apply it) or is the sexp itself buggered?

Now, granted, I can do this another way, with a lot more waypoints and a lot of variables, and in some ways, that'd be better, but It'll also get very, very sexp intensive and I'd very much prefer to be able to use this method.
TWISTED INFINITIES · SECTORGAME· FRONTLINES
Rarely Updated P3D.
Burn the heretic who killed F2S! Burn him, burn him!!- GalEmp

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: Remove-Goal sexp - does it work?
Code: [Select]
// Goober5000
void sexp_remove_goal(int n)
{
}

I guess we need to ask Goober. Judging from the commit log it looks like the SEXP was added incomplete (possibly even by accident since it's not mentioned) and never touched again.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

  

Offline asyikarea51

  • 210
  • -__-||
Re: Remove-Goal sexp - does it work?
I've got this feeling it doesn't actually work. I vaguely remember trying out the SEXP a few times, but when I didn't see results, I redid the entire mission altogether (completely unfamiliar with variables, got to learn that sooner or later) and left said misssion on my hard disk to rot.

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: Remove-Goal sexp - does it work?
It doesn't work. The code to make the SEXP actually do anything is non-existent. There is meant to be something between those brackets in the code I posted.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline asyikarea51

  • 210
  • -__-||
Re: Remove-Goal sexp - does it work?
Right, noted.

Then again I'm probably setting up patrols the wrong way if I have to add and remove goals at every waypoint... :doubt:

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: Remove-Goal sexp - does it work?
Yep. Set up a path of more than one waypoint and the ships will quite happily follow it.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline Goober5000

  • HLP Loremaster
  • 214
    • Goober5000 Productions
Re: Remove-Goal sexp - does it work?
I had intended to add it but never actually got around to it. :nervous:

 

Offline CP5670

  • Dr. Evil
  • Global Moderator
  • 212
Re: Remove-Goal sexp - does it work?
I had intended to add it but never actually got around to it. :nervous:

If this sexp is what I think it was supposed to be, yes, tell me about it. :p

 

Offline Black Wolf

  • Twisted Infinities
  • 212
  • Hey! You! Get off-a my cloud!
    • Visit the TI homepage!
Re: Remove-Goal sexp - does it work?
Is it going to be added back in? I can think of several places it'd come in handy, particularly for controlling the AI during atmospheric missions.
TWISTED INFINITIES · SECTORGAME· FRONTLINES
Rarely Updated P3D.
Burn the heretic who killed F2S! Burn him, burn him!!- GalEmp