Author Topic: C09032008  (Read 15772 times)

0 Members and 1 Guest are viewing this topic.

Offline WMCoolmon

  • Purveyor of space crack
  • Moderator
  • 213
Changes:
  • Added minor light info functions for scripting (gr.Lights, light handle) - no creation functions yet
  • Added drawModel function for scripting (Definitely tested...)
  • Fixed BTRL FTL effect and greatly improved it
  • Fixed default subspace effect (This may or may not take care of 1759)

Comments:
I spent a long time tracking down the bug I did fix, which was a problem involving a capital ship warping out before it had finished slowing down. The Colossus still disappears too soon in my test mission, but I'm at a loss to explain it at this point, given that the warp effect uses the same lifetime and takes a while to disappear afterwards.

There was also a bunch of convoluted code and bad calculations that caused the Colossus to appear out of thin air. Hopefully, this is not a bug that people have designed missions around, because it was pretty damn obvious that something was just not right. :p

FTL Effect:
I made the following changes to the BTRL FTL effect:
- Ships now warp out instantaneously, regardless of speed
- Ships now warp in with their initial velocity, and the AI takes control as soon as the ship appears.
- Added code to support the shockwave and to make the ship disappear at $Warpout time (or appear at $Warpin time)
- Added code to switch off collision detection when the ship disappears.
- Animations for warpout are now paged in with all ships in the mission
- The shockwave effect is automatically loaded from a file using the "-shockwave" suffix. EG, if you specify "$Warpin animation: myeffect", your shockwave file should be "myeffect-shockwave"
- Insane amount of tweaking to how the effect is shaped - it now uses the autocenter code for the ship and expands the polygon out using bounding box maxs and mins. This works well for Freespace 2 ships, not as well for BTRL ships, but I was unable to find a configuration which worked for BTRL ships. Effect radius is based on the longest X or Z bounding box dimensions, unless you manually override it with "$Warp* Radius:"

Supported fields:
$Warp* type: Should be "BTRL"
$Warp* Start Sound: Crap, I knew I forgot something
$Warp* End Sound: Ditto.
$Warpout speed: If specified, ship will try to reach this speed before FTLing
$Warp* time: No direct effect
$Warp* radius: Radius of flash effect (Does not affect length or shockwave radius)
$Warp* animation: Controls animation filename for flash across the ship (Shockwave: <animation>-shockwave)

Recommended settings:
The following settings will synchronize the shockwave with the middle of the flash in ftl_test
Code: [Select]
$Name: GTF Apollo
+nocreate
$Warpin type: BTRL
$Warpin time: 0.3667
$Warpin animation: ftl
$Warpout type: BTRL
$Warpout time: 0.3667
$Warpout animation: ftl

Trial package:
http://fs2source.warpcore.org/temp/wmc/ftl_test.zip

This is basically the media from BTRL, but with the graphics resized so there isn't a huge empty space off to the right of "ftl.eff". They will need to be redone/stretched to a power-of-2 texture and converted to DDS for final release.

The VP also includes a table that converts all FS2 fighters to the effect, as well as all BTRL demo ships.

Build:
http://fs2source.warpcore.org/exes/latest/C09032008.zip

You'll probably want this. ;)
-C

 

Offline Zacam

  • Magnificent Bastard
  • Administrator
  • 211
  • I go Sledge-O-Matic on Spammers
    • Minecraft
    • Steam
    • Twitter
    • ModDB Feature
Initial Pre-work test: Issue 1759 - Resolved by this build.
Report MediaVP issues, now on the MediaVP Mantis! Read all about it Here!
Talk with the community on Discord
"If you can keep a level head in all this confusion, you just don't understand the situation"

¤[D+¬>

[08/01 16:53:11] <sigtau> EveningTea: I have decided that I am a 32-bit registerkin.  Pronouns are eax, ebx, ecx, edx.
[08/01 16:53:31] <EveningTea> dhauidahh
[08/01 16:53:32] <EveningTea> sak
[08/01 16:53:40] * EveningTea froths at the mouth
[08/01 16:53:40] <sigtau> i broke him, boys

 

Offline WMCoolmon

  • Purveyor of space crack
  • Moderator
  • 213
-C

 

Offline Ace

  • Truth of Babel
  • 212
    • http://www.lordofrigel.com
There's still some incompatibility between the Btrl warp effect and the warp-effect SEXP.

With that SEXP set to a warp time of 1 second, the flash animation plays three or four times when using the SEXP. Effectively a blinking light following the ship.

Could changing that SEXP's options for timing from seconds to milliseconds fix this issue?
Ace
Self-plagiarism is style.
-Alfred Hitchcock

 

Offline chief1983

  • Still lacks a custom title
  • Moderator
  • 212
  • ⬇️⬆️⬅️⬅️🅰➡️⬇️
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • Fate of the Galaxy
Great news   :yes:

Makes me want to play FS2 with the BtRL warp effect, I think it would be interesting, save for a few missions that hinge on a long effect time.
Fate of the Galaxy - Now Hiring!  Apply within | Diaspora | SCP Home | Collada Importer for PCS2
Karajorma's 'How to report bugs' | Mantis
#freespace | #scp-swc | #diaspora | #SCP | #hard-light on EsperNet

"You may not sell or otherwise commercially exploit the source or things you created based on the source." -- Excerpt from FSO license, for reference

Nuclear1:  Jesus Christ zack you're a little too hamyurger for HLP right now...
iamzack:  i dont have hamynerge i just want ptatoc hips D:
redsniper:  Platonic hips?!
iamzack:  lays

 

Offline WMCoolmon

  • Purveyor of space crack
  • Moderator
  • 213
There's still some incompatibility between the Btrl warp effect and the warp-effect SEXP.

With that SEXP set to a warp time of 1 second, the flash animation plays three or four times when using the SEXP. Effectively a blinking light following the ship.

Could changing that SEXP's options for timing from seconds to milliseconds fix this issue?

The warp-effect SEXP generates a Freespace-style warp effect - I'm not sure why it should be even using the BSG effect, unless someone has gone to some trouble to replace the animation/model files for the original warp effect.
-C

 

Offline Ace

  • Truth of Babel
  • 212
    • http://www.lordofrigel.com
I'm using the BtrL demo .vps which don't have the FS2 warp. It'd be mind-blowingly wonderful if the warp-effect SEXP could be altered so that it would support the custom FTL effects (Homeworld, BtrL) though.
Ace
Self-plagiarism is style.
-Alfred Hitchcock

 

Offline pecenipicek

  • Roast Chicken
  • 211
  • Powered by copious amounts of coffee and nicotine
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • PeceniPicek's own deviantart page
TAP warp effect isnt affected by this build, right? i cant test at the moment.
Skype: vrganjko
Ho, ho, ho, to the bottle I go
to heal my heart and drown my woe!
Rain may fall and wind may blow,
and many miles be still to go,
but under a tall tree I will lie!

The Apocalypse Project needs YOU! - recruiting info thread.

 

Offline Colonol Dekker

  • HLP is my mistress
  • 213
  • Aken Tigh Dekker- you've probably heard me
    • My old squad sub-domain
TAP warp is so Suh-WeeeeeeeeeeeeeT.

WMCoolman, this si the build with the rearview cam right? Before i DL i just wanna doublecheck as the amount of builds i have is slowly growing out of control :)
Campaigns I've added my distinctiveness to-
- Blue Planet: Battle Captains
-Battle of Neptune
-Between the Ashes 2
-Blue planet: Age of Aquarius
-FOTG?
-Inferno R1
-Ribos: The aftermath / -Retreat from Deneb
-Sol: A History
-TBP EACW teaser
-Earth Brakiri war
-TBP Fortune Hunters (I think?)
-TBP Relic
-Trancsend (Possibly?)
-Uncharted Territory
-Vassagos Dirge
-War Machine
(Others lost to the mists of time and no discernible audit trail)

Your friendly Orestes tactical controller.

Secret bomb God.
That one time I got permabanned and got to read who was being bitxhy about me :p....
GO GO DEKKER RANGERSSSS!!!!!!!!!!!!!!!!!
President of the Scooby Doo Model Appreciation Society
The only good Zod is a dead Zod
NEWGROUNDS COMEDY GOLD, UPDATED DAILY
http://badges.steamprofile.com/profile/default/steam/76561198011784807.png

 

Offline chief1983

  • Still lacks a custom title
  • Moderator
  • 212
  • ⬇️⬆️⬅️⬅️🅰➡️⬇️
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • Fate of the Galaxy
It's the build that supports his rearview cam script.  The rearview is not an inherent feature of this build I believe, it still needs the script from the other thread.
Fate of the Galaxy - Now Hiring!  Apply within | Diaspora | SCP Home | Collada Importer for PCS2
Karajorma's 'How to report bugs' | Mantis
#freespace | #scp-swc | #diaspora | #SCP | #hard-light on EsperNet

"You may not sell or otherwise commercially exploit the source or things you created based on the source." -- Excerpt from FSO license, for reference

Nuclear1:  Jesus Christ zack you're a little too hamyurger for HLP right now...
iamzack:  i dont have hamynerge i just want ptatoc hips D:
redsniper:  Platonic hips?!
iamzack:  lays

 

Offline Colonol Dekker

  • HLP is my mistress
  • 213
  • Aken Tigh Dekker- you've probably heard me
    • My old squad sub-domain
Cheers Chief :yes:

*breaks down crying*

I have no idea when scripts became a feature of FS2, i thought it was all TBLS and fred.... my head hurts.
Campaigns I've added my distinctiveness to-
- Blue Planet: Battle Captains
-Battle of Neptune
-Between the Ashes 2
-Blue planet: Age of Aquarius
-FOTG?
-Inferno R1
-Ribos: The aftermath / -Retreat from Deneb
-Sol: A History
-TBP EACW teaser
-Earth Brakiri war
-TBP Fortune Hunters (I think?)
-TBP Relic
-Trancsend (Possibly?)
-Uncharted Territory
-Vassagos Dirge
-War Machine
(Others lost to the mists of time and no discernible audit trail)

Your friendly Orestes tactical controller.

Secret bomb God.
That one time I got permabanned and got to read who was being bitxhy about me :p....
GO GO DEKKER RANGERSSSS!!!!!!!!!!!!!!!!!
President of the Scooby Doo Model Appreciation Society
The only good Zod is a dead Zod
NEWGROUNDS COMEDY GOLD, UPDATED DAILY
http://badges.steamprofile.com/profile/default/steam/76561198011784807.png

 

Offline SypheDMar

  • 210
  • Student, Volunteer, Savior
    • Minecraft
The Colossus still disappears too soon in my test mission, but I'm at a loss to explain it at this point, given that the warp effect uses the same lifetime and takes a while to disappear afterwards.

There was also a bunch of convoluted code and bad calculations that caused the Colossus to appear out of thin air. Hopefully, this is not a bug that people have designed missions around, because it was pretty damn obvious that something was just not right. :p
I think this also happens to the Lucifer.

 

Offline WMCoolmon

  • Purveyor of space crack
  • Moderator
  • 213
I'm using the BtrL demo .vps which don't have the FS2 warp. It'd be mind-blowingly wonderful if the warp-effect SEXP could be altered so that it would support the custom FTL effects (Homeworld, BtrL) though.

I've given this a couple of days and I still can't think of anything really useful that these effects would do. That is, I can't think of a canon reason for BSG or Homeworld that you'd see an empty warp effect going by itself. Maybe a hyperspace window hanging out in midspace - you could do that with the warp-effect SEXP and a textured flat polygon though.

Now the hyperspace effect without a ship, you can actually do that already. You don't even need a SEXP for that. :p

TAP warp effect isnt affected by this build, right? i cant test at the moment.

No, I didn't make any changes to the TAP effect. It should still be the same as before.

TAP warp is so Suh-WeeeeeeeeeeeeeT.

WMCoolman, this si the build with the rearview cam right? Before i DL i just wanna doublecheck as the amount of builds i have is slowly growing out of control :)

Yeah, like chief says though, you do need the script for the rearview camera. The build itself doesn't have any inherent rearview code.
-C

 

Offline pecenipicek

  • Roast Chicken
  • 211
  • Powered by copious amounts of coffee and nicotine
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • PeceniPicek's own deviantart page
I'm using the BtrL demo .vps which don't have the FS2 warp. It'd be mind-blowingly wonderful if the warp-effect SEXP could be altered so that it would support the custom FTL effects (Homeworld, BtrL) though.

I've given this a couple of days and I still can't think of anything really useful that these effects would do. That is, I can't think of a canon reason for BSG or Homeworld that you'd see an empty warp effect going by itself. Maybe a hyperspace window hanging out in midspace - you could do that with the warp-effect SEXP and a textured flat polygon though.

Now the hyperspace effect without a ship, you can actually do that already. You don't even need a SEXP for that. :p
Do you remember that mission in homeworld 1 with the "junkyard dog"? eheheee :p

Quote
TAP warp effect isnt affected by this build, right? i cant test at the moment.

No, I didn't make any changes to the TAP effect. It should still be the same as before.
kk :)

Skype: vrganjko
Ho, ho, ho, to the bottle I go
to heal my heart and drown my woe!
Rain may fall and wind may blow,
and many miles be still to go,
but under a tall tree I will lie!

The Apocalypse Project needs YOU! - recruiting info thread.

 

Offline Colonol Dekker

  • HLP is my mistress
  • 213
  • Aken Tigh Dekker- you've probably heard me
    • My old squad sub-domain
How do i "use" scriptys?

Actually i'll check the wiki, ignore this post :nod:
Campaigns I've added my distinctiveness to-
- Blue Planet: Battle Captains
-Battle of Neptune
-Between the Ashes 2
-Blue planet: Age of Aquarius
-FOTG?
-Inferno R1
-Ribos: The aftermath / -Retreat from Deneb
-Sol: A History
-TBP EACW teaser
-Earth Brakiri war
-TBP Fortune Hunters (I think?)
-TBP Relic
-Trancsend (Possibly?)
-Uncharted Territory
-Vassagos Dirge
-War Machine
(Others lost to the mists of time and no discernible audit trail)

Your friendly Orestes tactical controller.

Secret bomb God.
That one time I got permabanned and got to read who was being bitxhy about me :p....
GO GO DEKKER RANGERSSSS!!!!!!!!!!!!!!!!!
President of the Scooby Doo Model Appreciation Society
The only good Zod is a dead Zod
NEWGROUNDS COMEDY GOLD, UPDATED DAILY
http://badges.steamprofile.com/profile/default/steam/76561198011784807.png

 

Offline WMCoolmon

  • Purveyor of space crack
  • Moderator
  • 213
Do you remember that mission in homeworld 1 with the "junkyard dog"? eheheee :p

A little bit. I remember something about it being unusual, but not anything about the hyperspace effect specifically that you're referring to. If it's just something sitting there for the whole mission, you could probably get away with using drawPolygon. :drevil: Make sure you change "Mission" to the mission you're using.

junkyard-sct.tbm
Code: [Select]
#Conditional Hooks
$Application: Freespace 2
$Mission: junkyard
$On Mission Start: [
--Load the effect texture
if not g_HyperspaceTexture then
g_HyperspaceTexture = gr.loadTexture("nbackpurp2", true)
if not g_HyperspaceTexture:isValid() then
g_HyperspaceTexture = nil
end
end
]

$On Object Render: [
if not g_HyperspaceRendered and g_HyperspaceTexture then
--This will draw it at 0,0,0
--You'll need extra arguments to draw it somewhere else
gr.drawPolygon(g_HyperspaceTexture)

--Set a render marker this frame so the effect
--doesn't get rerendered with every single object
g_HyperspaceRendered = true
end
]

$On Frame: [
--Reset the render marker for this frame
g_HyperspaceRendered = nil
]

$On Mission End: [
if g_HyperspaceTexture then
--Unload the effect texture
g_HyperspaceTexture:unload()
g_HyperspaceTexture = nil

--Clean up
g_HyperspaceRendered = nil
end
]
#End

How do i "use" scriptys?

Actually i'll check the wiki, ignore this post :nod:

Copy the code to a file named "<something>-sct.tbm" and save it in data/tables, or <mod>/data/tables, where <something> is a meaningful name (Like "rearview-sct.tbm") and <mod> is a mod directory of your choice. I usually give name recommendations with modular scripting tables, the most important thing is to get the "-sct.tbm" suffix and save them in a "data/tables" directory.
-C

 

Offline Colonol Dekker

  • HLP is my mistress
  • 213
  • Aken Tigh Dekker- you've probably heard me
    • My old squad sub-domain
Ohhhhhhhhhh, So it's a script tbm like a shp or wep, sct. That's another one to remember now.

Cheers. Excellent ;) :yes:
Campaigns I've added my distinctiveness to-
- Blue Planet: Battle Captains
-Battle of Neptune
-Between the Ashes 2
-Blue planet: Age of Aquarius
-FOTG?
-Inferno R1
-Ribos: The aftermath / -Retreat from Deneb
-Sol: A History
-TBP EACW teaser
-Earth Brakiri war
-TBP Fortune Hunters (I think?)
-TBP Relic
-Trancsend (Possibly?)
-Uncharted Territory
-Vassagos Dirge
-War Machine
(Others lost to the mists of time and no discernible audit trail)

Your friendly Orestes tactical controller.

Secret bomb God.
That one time I got permabanned and got to read who was being bitxhy about me :p....
GO GO DEKKER RANGERSSSS!!!!!!!!!!!!!!!!!
President of the Scooby Doo Model Appreciation Society
The only good Zod is a dead Zod
NEWGROUNDS COMEDY GOLD, UPDATED DAILY
http://badges.steamprofile.com/profile/default/steam/76561198011784807.png

 

Offline pecenipicek

  • Roast Chicken
  • 211
  • Powered by copious amounts of coffee and nicotine
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • PeceniPicek's own deviantart page
Do you remember that mission in homeworld 1 with the "junkyard dog"? eheheee :p

A little bit. I remember something about it being unusual, but not anything about the hyperspace effect specifically that you're referring to. If it's just something sitting there for the whole mission, you could probably get away with using drawPolygon. :drevil: Make sure you change "Mission" to the mission you're using.

junkyard-sct.tbm
Code: [Select]
#Conditional Hooks
$Application: Freespace 2
$Mission: junkyard
$On Mission Start: [
--Load the effect texture
if not g_HyperspaceTexture then
g_HyperspaceTexture = gr.loadTexture("nbackpurp2", true)
if not g_HyperspaceTexture:isValid() then
g_HyperspaceTexture = nil
end
end
]

$On Object Render: [
if not g_HyperspaceRendered and g_HyperspaceTexture then
--This will draw it at 0,0,0
--You'll need extra arguments to draw it somewhere else
gr.drawPolygon(g_HyperspaceTexture)

--Set a render marker this frame so the effect
--doesn't get rerendered with every single object
g_HyperspaceRendered = true
end
]

$On Frame: [
--Reset the render marker for this frame
g_HyperspaceRendered = nil
]

$On Mission End: [
if g_HyperspaceTexture then
--Unload the effect texture
g_HyperspaceTexture:unload()
g_HyperspaceTexture = nil

--Clean up
g_HyperspaceRendered = nil
end
]
#End
probably, a drawn poly and a looping hyperspace sound being played at the center of the drawn poly, with an everytime sexp that basically does the following

everytime - when
-> docked with <Junkyard Dog>
      -> distance from ship to <insert coordinates of the hs poly>
      -> set ship coordinates <central place for gathering junk>

that would be a rough sexp equivalent of how the ships behaved in that mission. the sexp could use a bit of polish just to make sure that something doesnt bork it, but i think it'd work :p
(it'd probably be doable in script too, but i dont even know how to write the lua code :p , i can edit it no prob but i have no idea where to start with it)
Skype: vrganjko
Ho, ho, ho, to the bottle I go
to heal my heart and drown my woe!
Rain may fall and wind may blow,
and many miles be still to go,
but under a tall tree I will lie!

The Apocalypse Project needs YOU! - recruiting info thread.

 

Offline chief1983

  • Still lacks a custom title
  • Moderator
  • 212
  • ⬇️⬆️⬅️⬅️🅰➡️⬇️
    • Minecraft
    • Skype
    • Steam
    • Twitter
    • Fate of the Galaxy
Ohhhhhhhhhh, So it's a script tbm like a shp or wep, sct. That's another one to remember now.

Cheers. Excellent ;) :yes:

That's definitely one you don't need to remember :)
Fate of the Galaxy - Now Hiring!  Apply within | Diaspora | SCP Home | Collada Importer for PCS2
Karajorma's 'How to report bugs' | Mantis
#freespace | #scp-swc | #diaspora | #SCP | #hard-light on EsperNet

"You may not sell or otherwise commercially exploit the source or things you created based on the source." -- Excerpt from FSO license, for reference

Nuclear1:  Jesus Christ zack you're a little too hamyurger for HLP right now...
iamzack:  i dont have hamynerge i just want ptatoc hips D:
redsniper:  Platonic hips?!
iamzack:  lays

 

Offline Colonol Dekker

  • HLP is my mistress
  • 213
  • Aken Tigh Dekker- you've probably heard me
    • My old squad sub-domain
Thanks, i'll get my head round this at some point.
Campaigns I've added my distinctiveness to-
- Blue Planet: Battle Captains
-Battle of Neptune
-Between the Ashes 2
-Blue planet: Age of Aquarius
-FOTG?
-Inferno R1
-Ribos: The aftermath / -Retreat from Deneb
-Sol: A History
-TBP EACW teaser
-Earth Brakiri war
-TBP Fortune Hunters (I think?)
-TBP Relic
-Trancsend (Possibly?)
-Uncharted Territory
-Vassagos Dirge
-War Machine
(Others lost to the mists of time and no discernible audit trail)

Your friendly Orestes tactical controller.

Secret bomb God.
That one time I got permabanned and got to read who was being bitxhy about me :p....
GO GO DEKKER RANGERSSSS!!!!!!!!!!!!!!!!!
President of the Scooby Doo Model Appreciation Society
The only good Zod is a dead Zod
NEWGROUNDS COMEDY GOLD, UPDATED DAILY
http://badges.steamprofile.com/profile/default/steam/76561198011784807.png