Author Topic: Force a ship to rotate  (Read 6479 times)

0 Members and 1 Guest are viewing this topic.

Offline Raven2001

  • Machina Terra Reborn
  • 211
  • Im not the droid your looking for, move along
No!!! You got it all wrong!!! Normally, if set to attack a ship, the Ravana closes its distance with the Target at the same time it fires her beams, but at a certain point (when it is too close) it just flyes in circles around the Target, and doesn't shoot (the beams are facing the front)... instead, the Ravana should fly away and turn around for another pass...

Oh, there is another beahviour... if it is too close when ordered to attack, the Ravana automatically begins the circling around the bogey...

Got my point now??
Yeah, I know you were waiting for a very nice sig, in which I was quoting some very famous scientist or philosopher... guess what?!? I wont indulge you...

Why, you ask? What, do I look like a Shivan to you?!?


Raven is a god.

 

Offline TrashMan

  • T-tower Avenger. srsly.
  • 213
  • God-Emperor of your kind!
    • FLAMES OF WAR
Don't worry people!

Goober5000 is working on my ai-face-ship SEXP that will allow anyone to order a ship to face any other ship anyway you want, from anyside you want.

when
has-arrived-delay
-Orion
-10
--ai-face-ship
---Orion
---left
---Ravana
---rear

i.e. -  for example, a Orion will try to get to the rear of a Ravana, while facing it with it's left side!
Nobody dies as a virgin - the life ****s us all!

You're a wrongularity from which no right can escape!

 

Offline Goober5000

  • HLP Loremaster
  • Moderator
  • 214
    • Goober5000 Productions
Um... no, that's not it at all.  The ship will merely turn to point in a particular direction.  If you want it to maneuver around, you'll have to script waypoints.

 
Quote
Originally posted by Raven2001
No!!! You got it all wrong!!! Normally, if set to attack a ship, the Ravana closes its distance with the Target at the same time it fires her beams, but at a certain point (when it is too close) it just flyes in circles around the Target, and doesn't shoot (the beams are facing the front)... instead, the Ravana should fly away and turn around for another pass...[/B]

Again, when she turns around to flee, she will be unable to fire at her target until she turns around again to start shooting.

The way I've done it is that she will simply stop, shoot at the target, and turn as necessary to keep her aim on the target. If both ships are instructed to sit and shoot (like a Ravana targeting a Hecate), then they will both just face each other and slug it out. If the target gets too far away, she will try to keep up with it, to prevent it from getting out of range.

Note that two big ships attacking each other will not collide -- they're programmed not to. They will only circle around each other, or face each other. For this reason, it doesn't really make much sense for them to try and distance themselves from each other anyway.

Of course, if you really want, and if the ship can do it, then it could be programmed to use reverse thrusters to back away from the target. Turning away from it, however, is a really bad idea.

Quote
Originally posted by Goober5000
If you want it to maneuver around, you'll have to script waypoints.

Or beg programmers to code the circling around code to do this...

 
Whats wrong with using a close-in waypoint to turn a capship around?  Capship battles pretty much have to be waypoint-choreographed anyway, since that circling thing is next to useless for all but Orions and Demons.

 

Offline StratComm

  • The POFressor
  • 212
  • Cameron Crazy
    • http://www.geocities.com/cek_83/index.html
Quote
Originally posted by Shiva Archon
Whats wrong with using a close-in waypoint to turn a capship around?  Capship battles pretty much have to be waypoint-choreographed anyway, since that circling thing is next to useless for all but Orions and Demons.


The problem is that there seems to be no determining factor for what angle the capship chooses to turn by when turning around (maybe has something to do with the smallest possible arclength but I haven't seen anything to support that), so in situations where capships are flying in close formation to each other, they cannot be ordered to turn around with waypoints without risking mass collisions.  However, I think that trying to more carefully script capship behavior is a moot point, as a good FREDer will never leave capships to their own affairs unless there is some explicit reason to do so.  Otherwise, all good battles are scripted.
who needs a signature? ;)
It's not much of an excuse for a website, but my stuff can be found here

"Holding the last thread on a page comes with an inherent danger, especially when you are edit-happy with your posts.  For you can easily continue editing in points without ever noticing that someone else could have refuted them." ~Me, on my posting behavior

Last edited by StratComm on 08-23-2027 at 08:34 PM

 

Offline TrashMan

  • T-tower Avenger. srsly.
  • 213
  • God-Emperor of your kind!
    • FLAMES OF WAR
Quote
Originally posted by Goober5000
Um... no, that's not it at all.  The ship will merely turn to point in a particular direction.  If you want it to maneuver around, you'll have to script waypoints.


Why not? If you got the hang of facing a ship, shouldn't be relatively easy to add this as well? Capship fights will look good even without scripting.
Nobody dies as a virgin - the life ****s us all!

You're a wrongularity from which no right can escape!

 
Quote
Originally posted by Shiva Archon
Whats wrong with using a close-in waypoint to turn a capship around?  Capship battles pretty much have to be waypoint-choreographed anyway, since that circling thing is next to useless for all but Orions and Demons.

It's not automatic. :D Why script capship battles when the AI can do it on its own?

There needs to be an ai-guard for big ships, though, so you can have cruisers and corvettes escorting a destroyer -- stay with it, circle around it when it's not moving, engage hostiles in defense of your escortee, etc. Then you don't need to script battlegroup coordination, either.

I don't know how hard this would be, though. It depends on how applicable the small ship ai-guard is to big ship AI. As you may know, big ship AI is quite different from small ship AI.

Anyway, my line of thinking is simply that the big ship AI should be smart enough that you don't need and won't want to script big ship battles.

 

Offline Flipside

  • əp!sd!l£
  • 212
I agree, though the opportunities for Freespace Pokemon abound ;)

Flipside :D

 
DEIMOS!  I CHOOSE YOU!  GOOOOO!

  

Offline StratComm

  • The POFressor
  • 212
  • Cameron Crazy
    • http://www.geocities.com/cek_83/index.html
Quote
Originally posted by ChronoReverse
DEIMOS!  I CHOOSE YOU!  GOOOOO!


Oh the humanity!  Did someone have to go and inalterably taint my opinions of Freespace by using it in Poke-speak?

*faints*
who needs a signature? ;)
It's not much of an excuse for a website, but my stuff can be found here

"Holding the last thread on a page comes with an inherent danger, especially when you are edit-happy with your posts.  For you can easily continue editing in points without ever noticing that someone else could have refuted them." ~Me, on my posting behavior

Last edited by StratComm on 08-23-2027 at 08:34 PM

 
Check that. ai-guard already works correctly when given to big ships. Same logic as small ships -- approach, circle around, keep up, temporary ai-chase on attackers, etc.

P.S. ChronoReverse: :hopping: :hopping: :mad: :mad2: :shaking: :shaking: :shaking:

 
Sorry, couldn't help myself when Flipside made the pokemon comment XD

 

Offline Flipside

  • əp!sd!l£
  • 212
LOL Well, you could theoretically set up arenas to test new capital ships for effectiveness of weapon arrangements etc, it would only be a matter of time before there was a league ;)

Flipside :D

 

Offline Goober5000

  • HLP Loremaster
  • Moderator
  • 214
    • Goober5000 Productions
Quote
Originally posted by TrashMan
Why not? If you got the hang of facing a ship, shouldn't be relatively easy to add this as well? Capship fights will look good even without scripting.


Rule #1 in the SCP forum: Non-coders should not speculate on how easy it may be for coders to implement things.  Getting a ship to face a location was relatively simple, but getting a ship to maneuver to a certain location is orders of magnitude more difficult.

 

Offline redmenace

  • 211
plus manuever around ships. you basically i guess, have to teach it drivers ed. and what if other ships are flying around that will influence its behavior.
Government is the great fiction through which everybody endeavors to live at the expense of everybody else.
              -Frederic Bastiat