Author Topic: Need help with Fredding "Accelerator Rings"  (Read 6273 times)

0 Members and 1 Guest are viewing this topic.

Offline esarai

  • 29
  • Steathy boi
Need help with Fredding "Accelerator Rings"
Hi,
I'm trying to do a new mission which involves accelerator rings. Now, why the hell would peeps need accelerator rings when they've got subspace drives? Well, this system is riddled with subspace anomalies, and long-ranged jumps cause ships to tear themselves to pieces. So, To get around that, people made Magnetic Accelerator Rings, or MARs. I need help in figuring out how to make anyone who approaches the ring get super-accelerated.

I already tried to do it with just alpha 1, writing a bunch of sexps where if pilot's distance to accelerator ring is less than 750, he gets flung out to kingdom come. This didn't work, and I have no idea why.

A copy of the sexps follows so people can tell me what I messed up:




thanks.
« Last Edit: June 09, 2008, 11:05:28 pm by esarai »
<Nuclear>   truth: the good samaritan actually checked for proof of citizenship and health insurance
<Axem>   did anyone catch jesus' birth certificate?
<Nuclear>   and jesus didnt actually give the 5000 their fish...he gave it to the romans and let it trickle down
<Axem>and he was totally pro tax breaks
<Axem>he threw out all those tax collectors at the temple
<Nuclear>   he drove a V8 camel too
<Nuclear>   with a sword rack for his fully-automatic daggers

Esarai: hey gaiz, what's a good improvised, final attack for a ship fighting to buy others time to escape to use?
RangerKarl|AtWork: stick your penis in the warp core
DarthGeek: no don't do that
amki: don't EVER do that

 

Offline Jeff Vader

  • The Back of the Hero!
  • 212
  • Bwahaha
Re: Need help with FRED2
Hi,
I'm trying to do a new mission which involves accelerator rings. Now, why the hell would peeps need accelerator rings when they've got subspace drives? Well, this system is riddled with subspace anomalies, and long-ranged jumps cause ships to tear themselves to pieces. So, To get around that, people made Magnetic Accelerator Rings, or MARs. I need help in figuring out how to make anyone who approaches the ring get super-accelerated.

I already tried to do it with just alpha 1, writing a bunch of sexps where if pilot's distance to accelerator ring is less than 750, he gets flung out to kingdom come. This didn't work, and I have no idea why.
Haven't FREDded ever, but I've heard that that FRED2_Open is fun.

Quote
how do you put in images into the post rather than making a link?
Code: [Select]
[img]http://i279.photobucket.com/albums/kk124/esaraisaiea/MARSCoding.jpg[/img] or with very wide pictures, [lvlshot]http://i279.photobucket.com/albums/kk124/esaraisaiea/MARSCoding.jpg[/lvlshot]
23:40 < achillion > EveningTea: ass
23:40 < achillion > wait no
23:40 < achillion > evilbagel: ass
23:40 < EveningTea > ?
23:40 < achillion > 2-letter tab complete failure

14:08 < achillion > there's too much talk of butts and dongs in here
14:08 < achillion > the level of discourse has really plummeted
14:08 < achillion > Let's talk about politics instead
14:08 <@The_E > butts and dongs are part of #hard-light's brand now
14:08 <@The_E > well
14:08 <@The_E > EvilBagel's brand, at least

01:06 < T-Rog > welp
01:07 < T-Rog > I've got to take some very strong antibiotics
01:07 < achillion > penis infection?
01:08 < T-Rog > Chlamydia
01:08 < achillion > O.o
01:09 < achillion > well
01:09 < achillion > I guess that happens
01:09 < T-Rog > at least it's curable
01:09 < achillion > yeah
01:10 < T-Rog > I take it you weren't actually expecting it to be a penis infection
01:10 < achillion > I was not

14:04 < achillion > Sometimes the way to simplify is to just have a habit and not think about it too much
14:05 < achillion > until stuff explodes
14:05 < achillion > then you start thinking about it

22:16 < T-Rog > I don't know how my gf would feel about Jewish conspiracy porn

15:41 <-INFO > EveningTea [[email protected]] has joined #hard-light
15:47 < EvilBagel> butt
15:51 < Achillion> yes
15:53 <-INFO > EveningTea [[email protected]] has quit [Quit: http://www.mibbit.com ajax IRC Client]

18:53 < Achillion> Dicks are fun

21:41 < MatthTheGeek> you can't spell assassin without two asses

20:05 < sigtau> i'm mining titcoins from now on

00:31 < oldlaptop> Drunken antisocial educated freezing hicks with good Internet == Finland stereotype

11:46 <-INFO > Kobrar [[email protected]] has joined #hard-light
11:50 < achtung> Surely you've heard of DVDA
11:50 < achtung> Double Vaginal Double ANal
11:51 < Kobrar> ...
11:51 <-INFO > Kobrar [[email protected]] has left #hard-light []

 

Offline Backslash

  • 29
  • Bring Our Might To Bear
Re: Need help with FRED2: Accelerator Rings
You're not doing anything wrong... it's due to the way the game physics treats the Z object acceleration.  The speed was applied, but it got instantly reset to 0.

Try setting $use_newtonian_dampening in ai_profiles.tbl to YES.  This should make your example work properly. :)

 

Offline esarai

  • 29
  • Steathy boi
Re: Need help with FRED2: Accelerator Rings
Sweet. I'll try it next time I get near my FS2 computer. And using newtonian dampening should make it behave the way I want it to, too. I was trying to make the rings aligned in different paths so that the player must maneuver their craft in a very skilled manner, or else they get flung into dead-space or smashed to tiny bits.
<Nuclear>   truth: the good samaritan actually checked for proof of citizenship and health insurance
<Axem>   did anyone catch jesus' birth certificate?
<Nuclear>   and jesus didnt actually give the 5000 their fish...he gave it to the romans and let it trickle down
<Axem>and he was totally pro tax breaks
<Axem>he threw out all those tax collectors at the temple
<Nuclear>   he drove a V8 camel too
<Nuclear>   with a sword rack for his fully-automatic daggers

Esarai: hey gaiz, what's a good improvised, final attack for a ship fighting to buy others time to escape to use?
RangerKarl|AtWork: stick your penis in the warp core
DarthGeek: no don't do that
amki: don't EVER do that

 
Re: Need help with FRED2: Accelerator Rings
Sweet. I'll try it next time I get near my FS2 computer. And using newtonian dampening should make it behave the way I want it to, too. I was trying to make the rings aligned in different paths so that the player must maneuver their craft in a very skilled manner, or else they get flung into dead-space or smashed to tiny bits.
Sounds horrible to a bad pilot like me :nervous:

 

Offline Snail

  • SC 5
  • 214
  • Posts: ☂
Re: Need help with FRED2: Accelerator Rings
You're not doing anything wrong... it's due to the way the game physics treats the Z object acceleration.  The speed was applied, but it got instantly reset to 0.

Try setting $use_newtonian_dampening in ai_profiles.tbl to YES.  This should make your example work properly. :)
You're smart.

 

Offline esarai

  • 29
  • Steathy boi
Re: Need help with FRED2: Accelerator Rings
Sweet. I'll try it next time I get near my FS2 computer. And using newtonian dampening should make it behave the way I want it to, too. I was trying to make the rings aligned in different paths so that the player must maneuver their craft in a very skilled manner, or else they get flung into dead-space or smashed to tiny bits.
Sounds horrible to a bad pilot like me :nervous:


Don't worry, It shouldn't be that bad... Just make sure you're pointed at the next ring and watch out for random debris strewn about.
<Nuclear>   truth: the good samaritan actually checked for proof of citizenship and health insurance
<Axem>   did anyone catch jesus' birth certificate?
<Nuclear>   and jesus didnt actually give the 5000 their fish...he gave it to the romans and let it trickle down
<Axem>and he was totally pro tax breaks
<Axem>he threw out all those tax collectors at the temple
<Nuclear>   he drove a V8 camel too
<Nuclear>   with a sword rack for his fully-automatic daggers

Esarai: hey gaiz, what's a good improvised, final attack for a ship fighting to buy others time to escape to use?
RangerKarl|AtWork: stick your penis in the warp core
DarthGeek: no don't do that
amki: don't EVER do that

 

Offline Backslash

  • 29
  • Bring Our Might To Bear
Re: Need help with FRED2: Accelerator Rings
You're smart.
Why, thank you ;)  Really, I only already knew why this was because I tried to do it myself last year.  It was sure frustrating tracking down the reason back then!

Using set-object-speed like this was the reason I looked into that last year.  It allows for so many possibilities like this -- accelerator rings, catapult launches, etc. ;7 To say nothing of the potential for cutscenes...

Actually I had done it so that this option was enabled by default (because it made almost everything about fighter movement more customizable as a result).  Unfortunately it turned out that it messed up retail FS2/FSPort missions, because capships kept too much momentum upon jumping in.  So Turey helped move it to a ai_profiles flag.  In my opinion, any mod that is not shackled to retail table data should use this flag :D

Looking forward to your missions, esarai...

 

Offline esarai

  • 29
  • Steathy boi
Re: Need help with FRED2: Accelerator Rings
woah, I can't believe you found out how to solve that. I can't even find the ai_profiles.tbl file. Man I feel stupid. Where exactly would it be?
<Nuclear>   truth: the good samaritan actually checked for proof of citizenship and health insurance
<Axem>   did anyone catch jesus' birth certificate?
<Nuclear>   and jesus didnt actually give the 5000 their fish...he gave it to the romans and let it trickle down
<Axem>and he was totally pro tax breaks
<Axem>he threw out all those tax collectors at the temple
<Nuclear>   he drove a V8 camel too
<Nuclear>   with a sword rack for his fully-automatic daggers

Esarai: hey gaiz, what's a good improvised, final attack for a ship fighting to buy others time to escape to use?
RangerKarl|AtWork: stick your penis in the warp core
DarthGeek: no don't do that
amki: don't EVER do that

 

Offline Snail

  • SC 5
  • 214
  • Posts: ☂
Re: Need help with FRED2: Accelerator Rings
woah, I can't believe you found out how to solve that. I can't even find the ai_profiles.tbl file. Man I feel stupid. Where exactly would it be?
It's an SCP added table, you'd have to make it yourself, it's not in retail FS2.

 

Offline esarai

  • 29
  • Steathy boi
Re: Need help with FRED2: Accelerator Rings
So, Just make ai_profiles.tbl and it's only content should be:

#Ai Profiles
$Profile name: Accelerator
$use_newtonian_dampening: YES
#End

Or wait... Do I have to include the definitions for the AI Classes?

And this doesn't seem to work. Hey Backslash, could you post the code that let you do the accelerator thingy, cause this one isn't working.
« Last Edit: June 11, 2008, 01:57:41 pm by esarai »
<Nuclear>   truth: the good samaritan actually checked for proof of citizenship and health insurance
<Axem>   did anyone catch jesus' birth certificate?
<Nuclear>   and jesus didnt actually give the 5000 their fish...he gave it to the romans and let it trickle down
<Axem>and he was totally pro tax breaks
<Axem>he threw out all those tax collectors at the temple
<Nuclear>   he drove a V8 camel too
<Nuclear>   with a sword rack for his fully-automatic daggers

Esarai: hey gaiz, what's a good improvised, final attack for a ship fighting to buy others time to escape to use?
RangerKarl|AtWork: stick your penis in the warp core
DarthGeek: no don't do that
amki: don't EVER do that

 

Offline Backslash

  • 29
  • Bring Our Might To Bear
Re: Need help with FRED2: Accelerator Rings
Uh... maybe.  Sorry, I'm currently away from my gaming/coding computer so I can't test or give you the example mission yet, but I'll be back tomorrow.  Your event looks fine to me, though.

Try adding a +nocreate under the $Profile Name: line (and don't forget to capitalize Name), then name the file "something-aip.tbm" (you can change 'something' to whatever you want, but keep the -aip.tbm ).  If that doesn't work, scrap that and fill out a whole ai_profiles.tbl with the AI classes and all.  A simple copy paste from the sample in the wiki should be fine.

A way to test if the problem is in your ai_profiles table or not:  temporarily change the set-object-speed-z to set-object-speed-x (or y)... those directions should work no matter what.  (...unless your ship has a $Damp of 0.)

 
Re: Need help with FRED2: Accelerator Rings
Remember to have the actual AI profile set in your mission. I forgot to do that a couple of times...  :nervous:

 

Offline esarai

  • 29
  • Steathy boi
Re: Need help with FRED2: Accelerator Rings
Okay... I changed the acceleration direction, and it works both x and y, not z. It also does not last. You'll get a boost, but when you get out of range, you lose all your momentum, really fast. I'm going to try and make it work with booleans: If you've gotten close enough to the ring, then accelerated = true, and as long as accelerated = true you will have a velocity of 1400 or some such.  Means I need to make decelerator rings.

version 2:

speed : Integer Variable for defining speed
accelerated : boolean value to determine whether to apply speed or let pilot control his velocity.

If close to ring, add accelerator power to current velocity, save as speed variable.

speed variable is constantly applied while accelerated is true.

That brings me to another question... How do you make an event modify a variable? (making it behave kinda like "if A is true, then 350 + B = B")
« Last Edit: June 11, 2008, 07:11:35 pm by esarai »
<Nuclear>   truth: the good samaritan actually checked for proof of citizenship and health insurance
<Axem>   did anyone catch jesus' birth certificate?
<Nuclear>   and jesus didnt actually give the 5000 their fish...he gave it to the romans and let it trickle down
<Axem>and he was totally pro tax breaks
<Axem>he threw out all those tax collectors at the temple
<Nuclear>   he drove a V8 camel too
<Nuclear>   with a sword rack for his fully-automatic daggers

Esarai: hey gaiz, what's a good improvised, final attack for a ship fighting to buy others time to escape to use?
RangerKarl|AtWork: stick your penis in the warp core
DarthGeek: no don't do that
amki: don't EVER do that

 
Re: Need help with FRED2: Accelerator Rings
what are you using as the ring?
knossos or a new model?

 

Offline esarai

  • 29
  • Steathy boi
Re: Need help with FRED2: Accelerator Rings
I'm using an Arcadia, but I intend to make a specialized model soon.
« Last Edit: June 11, 2008, 08:09:53 pm by esarai »
<Nuclear>   truth: the good samaritan actually checked for proof of citizenship and health insurance
<Axem>   did anyone catch jesus' birth certificate?
<Nuclear>   and jesus didnt actually give the 5000 their fish...he gave it to the romans and let it trickle down
<Axem>and he was totally pro tax breaks
<Axem>he threw out all those tax collectors at the temple
<Nuclear>   he drove a V8 camel too
<Nuclear>   with a sword rack for his fully-automatic daggers

Esarai: hey gaiz, what's a good improvised, final attack for a ship fighting to buy others time to escape to use?
RangerKarl|AtWork: stick your penis in the warp core
DarthGeek: no don't do that
amki: don't EVER do that

 

Offline Retsof

  • 210
  • Sanity is over-rated.
Re: Need help with FRED2: Accelerator Rings
This mission sounds fun.  I hope it is a standalone so that I can play it when it's done.
:::PROUD VASUDAN RIGHTS SUPPORTER:::

"Get off my forum" -General Battuta
I can't help but hear a shotgun cocking with this.

 
Re: Need help with FRED2: Accelerator Rings
I'm using an Arcadia, but I intend to make a specialized model soon.

arcadia as a ring?

 

Offline Droid803

  • Trusted poster of legit stuff
  • 213
  • /人 ◕ ‿‿ ◕ 人\ Do you want to be a Magical Girl?
    • Skype
    • Steam
Re: Need help with FRED2: Accelerator Rings
The Arcadia has a hole in it, do you forget? :P
(´・ω・`)
=============================================================

 
Re: Need help with FRED2: Accelerator Rings
wouldn't it be cooler to use the construction rings ? (I forgot the name of these ring)
they are the one you don't see int he campaign but used in multiplayer
EDIT : wasn't it the ganymede ?
« Last Edit: June 12, 2008, 02:33:23 am by griffon67 »