Hard Light Productions Forums

Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: Photoncody on March 26, 2007, 07:08:24 pm

Title: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on March 26, 2007, 07:08:24 pm
How many times this happen to you? Your on one custom campain mission, and when you enter the mission, theres 25 fighter wings and 3 corvettes ready to smash you to pieces. I would like if we could spawn a ship out of subspace any time we would like, and we can command it like a fighter. (Or if it is a fighter) And I would like it to be a infinite use thing. (Yes I know we can spawn volition pirate ship already with the cheat, arrrrwalktheplank, but I want a REAL ship like one the can use beam cannons and be able to take our commands. (There is a poll)
Please post.

-Photoncody
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Getter Robo G on March 26, 2007, 07:17:45 pm
1) This belongs more in modding. We already have something like that either implemented or being worked on (never really paid it much attention it;s nice bit of whimsy but I see no practical purpose to it).

2) I voted NO cause I'm that damn good. :D

3) This is something I expect from Takashi, please don't vie for status as noob of the year...
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: phreak on March 26, 2007, 07:59:05 pm
arrrrwalktheplank
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: takashi on March 26, 2007, 08:08:38 pm
i can make a missle that spawns ships, which in turn spawn missles, if thats what you want.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on March 26, 2007, 08:20:15 pm
That exactly what I want.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Goober5000 on March 26, 2007, 08:23:48 pm
I like pancakes.

Also, ship-create.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: jr2 on March 26, 2007, 08:27:05 pm
~+K
Hold ~ while pressing K, watch the currently targeted craft go KA-BOOM!  (As Nuke would say.)
'Nuff said.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on March 26, 2007, 09:13:29 pm
I like pancakes.

->Also, ship-create.<-
Have no idea what that means!
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Turey on March 26, 2007, 09:15:51 pm
www.freespace2.com
`u
`x

I don't know WHY anyone would want to spawn an asteroid, but meh.

I like pancakes.

->Also, ship-create.<-
Have no idea what that means!

It's a SEXP.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: redsniper on March 27, 2007, 01:11:08 pm
$50 Tyrant says something childish and immature about that acronym.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on March 27, 2007, 02:41:26 pm
www.freespace2.com
`u
`x

I don't know WHY anyone would want to spawn an asteroid, but meh.

I like pancakes.

->Also, ship-create.<-
Have no idea what that means!

It's a SEXP.
And I have no idea what that means eithier!
EDIT:Can takashi please post? I'm getting impatent. :sigh: :wtf:
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Wanderer on March 27, 2007, 03:01:45 pm
Special EXPression - used in FreeSpace to control mission structures and are also the main tools used when creating new missions with FRED (freespace editor).
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Getter Robo G on March 27, 2007, 05:01:36 pm
Wow...

I didn't notice the option for pancakes before (I thought Goob was just being Goob! - He hates us all you know)  :lol:

Perhaps linking him to that thread that showed the command in action (Hercs? filled the sky) would help get him on the right track...  :p

Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Turey on March 27, 2007, 05:21:41 pm
Wow...

I didn't notice the option for pancakes before (I thought Goob was just being Goob! - He hates us all you know)  :lol:

Perhaps linking him to that thread that showed the command in action (Hercs? filled the sky) would help get him on the right track...  :p



http://www.hard-light.net/forums/index.php/topic,35794.0.html

That thread is the source of the quote in my sig, so it was easy to find.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Col. Fishguts on March 27, 2007, 06:00:31 pm
Exactly what I was thinking. The shoal of Hercs is a stunning view.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Aardwolf on March 27, 2007, 08:27:49 pm
Special Expression?

I thought it was "Symbollic Expression"

Edit: That "bug" is awesome!
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Nuke on March 27, 2007, 08:46:51 pm
you cant spawn ships out of the thin air, theres no air in space, duh :D
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Gregster2k on March 27, 2007, 08:53:37 pm
A gun that is tied to ship-create would be more fun.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Goober5000 on March 27, 2007, 10:22:50 pm
you cant spawn ships out of the thin air, theres no air in space, duh :D
That's why it's thin. :p
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: karajorma on March 28, 2007, 03:56:42 am
Special Expression?

I thought it was "Symbollic Expression"

Edit: That "bug" is awesome!

Quote from: The FRED2 Help
This file explains how to use SEXPs, or symbolic expressions, to program complex behavior into your missions. (It's pronounced "sex pee". Stop snickering!)

And yeah it's not really a bug as I can still do it now that the code is working. It's just a little harder.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Goober5000 on March 28, 2007, 08:32:02 am
It's actually pronounced "ess exp". :)

But I always mentally pronounced it as /seksp/.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Turey on March 28, 2007, 09:58:36 am
But I always mentally pronounced it as /seksp/.

Ditto.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Grizzly on March 28, 2007, 10:18:36 am
Its funny to see that someone uses my idea of tags.

I pronounce it as: sex-pee
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: jr2 on March 28, 2007, 10:18:44 am
Err... it was 'ess exp'?

Too late now.  I'm stuck on the other way.  Gah!!
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: redsniper on March 29, 2007, 02:14:04 pm
(http://img.photobucket.com/albums/v458/redsniper7/sexp.png)
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: jr2 on March 29, 2007, 02:17:47 pm
Yeah, I read that one, too!
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Cobra on March 29, 2007, 05:28:39 pm
i can make a missle that spawns ships, which in turn spawn missles, if thats what you want.

:wakka:

And arrrrwalktheplank works fine for me. I actually spawned about 30 Volition Bravos in The Mystery of the Trinity mission. No ship got through the flak. :D
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Snail on March 29, 2007, 05:59:30 pm
Mah, VBravos sucks weapon-wise, really.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Bob-san on March 29, 2007, 06:20:09 pm
I like pancakes too... but waffles > pancakes! waffles&icecream > waffles > pancakes > pop tarts > nothing > cereal



Just modify the VBravo in the tables.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on March 29, 2007, 06:34:15 pm
I like pancakes too... but waffles > pancakes! waffles&icecream > waffles > pancakes > pop tarts > nothing > cereal



Just modify the VBravo in the tables.
How do I do that???
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Turey on March 29, 2007, 06:49:47 pm
I like pancakes too... but waffles > pancakes! waffles&icecream > waffles > pancakes > pop tarts > nothing > cereal



Just modify the VBravo in the tables.
How do I do that???

Create a text file, put this in it:
Code: [Select]
#Ship Classes
$Name: @Volition Bravos
+nocreate
#End

Then, use the Wiki to fill in the stuff between +nocreate and #End.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: jr2 on March 29, 2007, 08:11:20 pm
... save it as ships.tbm, and put it in your \data\tables folder, correct?
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on March 29, 2007, 09:01:22 pm
I HAVE NO UNDERSTANDING OF LUA AND IT IS DRIVING ME CRAZY!!!!!!!!!!!!! :mad: :mad: :mad:
THE TUTORIAL PAGES DO NOT HELP AND I AM WANTING A MODDED VBRAVO SHIP BUT I DO NOT UNDERSTAND!!!! :mad: :mad: :hopping:
 :mad2: PLEASE HELP ME!!!!! :( :( :(
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Cobra on March 29, 2007, 09:16:50 pm
Whoah, whoah, calm down.

You don't need to know LUA programming to know how to edit tables.

Read Karajorma's FAQ (http://homepage.ntlworld.com/karajorma/FAQ/intro.html). It'll tell you lots of things (though really it's the basics to help you get started) about modding Freespace.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on March 29, 2007, 10:25:15 pm
It didn't work... :( I tried editing the ships.tbl file, and it reset itself every time I tried editing it. :mad: Just need to know....
Can anyone help?

-Photoncody
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: jr2 on March 29, 2007, 10:31:24 pm
Ah, you need to extract it from the .vp first.  The extracted file will override the .vp file.  See, VP files are a container file, with many files inside them.  The files cannot be edited inside the .vp.  You need to extract it.  Inside the .vp are folders... FS looks for files in the real folders (the ones you can see in Windows Explorer) first; then in looks inside of the .vp.  So, if you extract a file from the .vp, and place it in the actual directory, FS will not look at the file in the .vp, but will instead use the one you extracted.

Now, the file you're looking for is ships.tbl, you need to extract it from the .vp  It is in the /data/tables directory inside of the .vp, so you need to place it in \FreeSpace2\data\tables, then you can edit the copy that is outside the .vp, and the one inside will not be used.

See?
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on March 29, 2007, 11:01:27 pm
Thank you jr2. Thanks VERY much!!!
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: jr2 on March 29, 2007, 11:14:22 pm
np :)
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Goober5000 on March 30, 2007, 02:15:08 am
(http://img.photobucket.com/albums/v458/redsniper7/sexp.png)
The FRED2 help is wrong about that.  Just like IMDB was wrong about Stephen Baldwin voicing Snipes. :)

Sexps were used in LISP before they were used in FreeSpace.  In fact, FreeSpace sexps are based on LISP:
http://en.wikipedia.org/wiki/S-expression
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on March 30, 2007, 09:02:05 am
Anyone know how to make the beam cannons on my VBravo ship? I keep trying to put fighters there, but they just don't fire. could anyone help?
Quote
And, um, takashi the spawn misile I want to be a perseus fighter that it spawns.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Cobra on March 30, 2007, 10:57:51 am
Uhh, Photon, don't listen to takashi. You can't spawn a fully working ship from a missile. Notice how you've never gotten a response from him? He never made one. :P It's just not possible to do something like that.

OK, you know where the turrets section is, right?
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on March 30, 2007, 11:59:28 am
Not really. I am a very big n00b when it comes to modding.  :doubt:
can give me link? :)
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Cobra on March 30, 2007, 12:00:00 pm
Not really. I am a very big n00b when it comes to modding.  :doubt:
can give me link? :)

I meant in the tables.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on April 09, 2007, 04:42:30 pm
Sorry for the long-waited respond! Hey Cobra, can you help me with the turrets section? I've put the ships there and they still didn't fire. I put the entry (more like edit) in the tables but no luck. Can you help?
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: takashi on April 09, 2007, 09:56:00 pm
be patient. triple spawning with missles behaving like ships requires a new build.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Turey on April 10, 2007, 01:30:03 am
be patient. triple spawning with missles behaving like ships requires a new build.

Who's going to write the code for this? You?
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: TrashMan on April 10, 2007, 10:14:09 am
(http://img.photobucket.com/albums/v458/redsniper7/sexp.png)
The FRED2 help is wrong about that.  Just like IMDB was wrong about Stephen Baldwin voicing Snipes. :)

Sexps were used in LISP before they were used in FreeSpace.  In fact, FreeSpace sexps are based on LISP:
http://en.wikipedia.org/wiki/S-expression

Maby FRED SEXP's and LISP sexp's aren't the same, so they are not pronounced the same.
REagardles, official documentation sez sex pee
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Photoncody on April 10, 2007, 06:16:32 pm
No I ment the turrets section in the tables. Cobra helping me put beam turrets on the VBravo ship and MAKE THEM WORK.


Tell me what I'm doing wrong, Cobra.
Code: [Select]
$Name:                          @Volition Bravos
$Short name: VPirate
$Species:                       Terran
+Tech Description:
XSTR("Harr! The FS2 Volition Bravos is the scurviest ship in the known universe. Furl yer sails, strike yer colors, and prepare to be boarded by the FreeSpace 2 team!", -1)
$end_multi_text
$POF file:                      pirate2t-01.pof
$Detail distance: (0, 600, 1500, 5000)
$Show damage: YES
$Density:                       1
$Damp:                          0.2
$Rotdamp:                       1.0
$Max Velocity: 0.0, 0.0, 60.0
$Rotation time: 40.0, 40.0, 40.0
$Rear Velocity: 0.0
$Forward accel: 10.0
$Forward decel: 5.0
$Slide accel: 0.0
$Slide decel: 0.0
$Expl inner rad: 125.0
$Expl outer rad: 650.0
$Expl damage: 200.0
$Expl blast: 3500.0
$Expl Propagates: YES ;; If set to Yes, then when the ship dies, the explosion propagates through it.
$Shockwave Speed: 500.0 ;; speed shockwave expands at, 0 means no shockwave
$Default PBanks: ()
$Default SBanks: ()
$SBank Capacity: ()
$Shields:                       0
$Power Output: 90.0
$Max Oclk Speed: 25.0
$Max Weapon Eng: 100.0
$Hitpoints:                     10000000000
$Flags:                         ( "corvette" "no_fred" )
$AI Class:                      Captain
$Afterburner: NO
$Countermeasures: 0
$Scan time:                     2000
$EngineSnd: 186                   ;; Engine sound of ship
$Closeup_pos: 0.0, 0.0, -900
$Closeup_zoom: 0.5
$Score: 10
$Subsystem:                     turret01, 2, 5.0
$Default PBanks: ( "AAAf" )
$Subsystem:                     turret02, 2, 5.0
$Default PBanks: ( "Standard Flak" )
$Subsystem:                     turret03, 2, 5.0
$Default PBanks: ( "Heavy Flak" )
$Subsystem:                     turret04, 2, 5.0
$Default PBanks: ( "AAAf" )
$Subsystem:                     turret05, 2, 5.0
$Default PBanks: ( "Standard Flak" )
$Subsystem:                     turret06, 2, 5.0
$Default PBanks: ( "Heavy Flak" )
$Subsystem:                     turret07a, 2, 5.0
$Default PBanks: ( "BGreen" )
$Subsystem:                     turret08, 2, 5.0
$Default PBanks: ( "Terran Huge Turret" )
$Subsystem:                     turret09a, 2, 5.0
$Default PBanks: ( "Terran Huge Turret" )
$Subsystem:                     communications,  10, 0
$Subsystem:                     navigation,             10, 0
$Subsystem:                     engine01,                        10, 0
$Subsystem:                     sensors,                        10, 0
$Subsystem:                     weapons,                        10, 0
:sigh:
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: Goober5000 on April 10, 2007, 09:15:49 pm
Maby FRED SEXP's and LISP sexp's aren't the same, so they are not pronounced the same.
REagardles, official documentation sez sex pee
First of all, FRED sexps and LISP sexps are the same.  In fact, practically all of the non-game-specific sexps come directly from LISP.

Second of all, just because something is official doesn't mean it's correct.  The IMDB example should have clued you in to that fact.  If you need a second example, the Official FS1 Strategy Guide says that the SD Tantalus is a Cain-class cruiser.

Third of all, the documentation was written by Peter Drake, who is a writer, not a coder.  Thus it is quite probably that he may have been ignorant of the word's origin.
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: jr2 on April 11, 2007, 03:14:34 am
No I ment the turrets section in the tables. Cobra helping me put beam turrets on the VBravo ship and MAKE THEM WORK.


Tell me what I'm doing wrong, Cobra.

Try this, there's a slight difference; see if it changes anything (copy it over):
Code: [Select]
$Name:                          @Volition Bravos
$Short name:                              VPirate
$Species:                       Terran
+Tech Description:
XSTR("Harr! The FS2 Volition Bravos is the scurviest ship in the known universe. Furl yer sails, strike yer colors, and prepare to be boarded by the FreeSpace 2 team!", -1)
$end_multi_text
$POF file:                      pirate2t-01.pof
$Detail distance:                    (0, 600, 1500, 5000)
$Show damage:                         YES
$Density:                       1
$Damp:                          0.2
$Rotdamp:                       1.0
$Max Velocity:                         0.0, 0.0, 60.0
$Rotation time:                         40.0, 40.0, 40.0
$Rear Velocity:                         0.0
$Forward accel:                         10.0
$Forward decel:                         5.0
$Slide accel:                         0.0
$Slide decel:                         0.0
$Expl inner rad:                    125.0
$Expl outer rad:                    650.0
$Expl damage:                         200.0
$Expl blast:                         3500.0
$Expl Propagates:                    YES                    ;; If set to Yes, then when the ship dies, the explosion propagates through it.
$Shockwave Speed:                    500.0               ;; speed shockwave expands at, 0 means no shockwave
$Default PBanks:                    ()
$Default SBanks:                    ()
$SBank Capacity:                    ()
$Shields:                       0
$Power Output:                         90.0
$Max Oclk Speed:                    25.0
$Max Weapon Eng:                    100.0
$Hitpoints:                     10000000000
$Flags:                         ( "corvette" "no_fred" )
$AI Class:                      Captain
$Afterburner:                         NO
$Countermeasures:                    0
$Scan time:                     2000
$EngineSnd:                              186                   ;; Engine sound of ship
$Closeup_pos:                         0.0, 0.0, -900
$Closeup_zoom:                         0.5
$Score:                                   10
$Subsystem:                     turret01, 2, 5.0
     $Default PBanks:               ( "AAAf" )
$Subsystem:                     turret02, 2, 5.0
     $Default PBanks:               ( "Standard Flak" )
$Subsystem:                     turret03, 2, 5.0
     $Default PBanks:               ( "Heavy Flak" )
$Subsystem:                     turret04, 2, 5.0
     $Default PBanks:               ( "AAAf" )
$Subsystem:                     turret05, 2, 5.0
     $Default PBanks:               ( "Standard Flak" )
$Subsystem:                     turret06, 2, 5.0
     $Default PBanks:               ( "Heavy Flak" )
$Subsystem:                     turret07a, 2, 5.0
     $Default PBanks:               ( "BGreen" )
$Subsystem:                     turret08, 2, 5.0
     $Default PBanks:               ( "Terran Huge Turret" )
$Subsystem:                     turret09a, 2, 5.0
     $Default PBanks:               ( "Terran Huge Turret" )
$Subsystem:                     communications,  10, 0
$Subsystem:                     navigation,             10, 0
$Subsystem:                     engine01,                        10, 0
$Subsystem:                     sensors,                        10, 0
$Subsystem:                     weapons,                        10, 0
Title: Re: IDEA:Spawn ships out of thin air as a cheat
Post by: takashi on April 11, 2007, 06:21:34 pm
yeah. im writing the code. timeframe is 3000 years.