Author Topic: Cloaked ships perhaps?  (Read 4864 times)

0 Members and 1 Guest are viewing this topic.

Offline Hades

  • FINISHING MODELS IS OVERRATED
  • 212
  • i wonder when my polycounts will exceed my iq
    • Skype
    • Steam
Cloaked ships perhaps?
Well?What do you think?





P.S. If you want to know how I did it just ask.

[attachment deleted by admin]
[22:29] <sigtau> Hello, #hard-light?  I'm trying to tell a girl she looks really good for someone who doesn't exercise.  How do I word that non-offensively?
[22:29] <RangerKarl|AtWork> "you look like a big tasty muffin"
----
<batwota> wouldn’t that mean that it’s prepared to kiss your ass if you flank it :p
<batwota> wow
<batwota> KILL

 

Offline Unknown Target

  • Get off my lawn!
  • 212
  • Push.Pull?
Re: Cloaked ships perhaps?
Uh...is this a glitch or did you just use a semi-transparent texture for the entire model?

 

Offline Hades

  • FINISHING MODELS IS OVERRATED
  • 212
  • i wonder when my polycounts will exceed my iq
    • Skype
    • Steam
Glass textures up the wazzu. :shaking:
It would be hard to see, it looks kind of cloaked.(No I know nothing about StarTrek)
You could use SEXPs to make it to were you cannot target it.
« Last Edit: September 01, 2007, 12:13:57 am by Hades »
[22:29] <sigtau> Hello, #hard-light?  I'm trying to tell a girl she looks really good for someone who doesn't exercise.  How do I word that non-offensively?
[22:29] <RangerKarl|AtWork> "you look like a big tasty muffin"
----
<batwota> wouldn’t that mean that it’s prepared to kiss your ass if you flank it :p
<batwota> wow
<batwota> KILL

 

Offline jr2

  • The Mail Man
  • 212
  • It's prounounced jayartoo 0x6A7232
    • Steam
Ever play Descent?  Looks sorta like that, IIRC

 

Offline --Steve-O--

  • 28
  • I might be the last man on earth to use TS3.2
isn't there a way to get fred to trigger a texture map change by using a keypress? so say you press "C" and FRED swaps the default texture map for the cloak map, press "C" again and it reverses the process. that would be a neat little trick.
"And so they dwelled in filth, on worlds made of dirt and feces, and there they lay until they stumbled into the skies." --the Mad Prophet

 

Offline Mobius

  • Back where he started
  • 213
  • Porto l'azzurro Dolce Stil Novo nella fantascienza
    • Skype
    • Twitter
    • The Lightblue Ribbon | Cultural Project
I'm not sure, but...you should be able to do it with Scripting.

Or you can simply use change-ship-class. Same entry, same POF, different textures(invisible). It can be easily triggered :)
The Lightblue Ribbon

Inferno: Nostos - Alliance
Series Resurrecta: {{FS Wiki Portal}} -  Gehenna's Gate - The Spirit of Ptah - Serendipity (WIP) - <REDACTED> (WIP)
FreeSpace Campaign Restoration Project
A tribute to FreeSpace in my book: Riflessioni dall'Infinito

 

Offline Getter Robo G

  • 211
  • Elite Super Robot Pilot
Hades... Can you make a version of that texture but at even more transparent and lighter so I can test it with a Klingon BOP? I had a texture from Trashman's archangel (The nameplate) and that sorta worked but was too white and needed to be more ghostly (transparent) and was not uniform coverage.

A generic transparent texture for cloaked ships would be great and you could use Fred to control when to change textures (or the SCP team can make a sexp to control cloaking) where you see that as a intermediate stage before going invisible.

Visible-cloaking texture-Invisible (ship cloaked) like that?

Comming out of cloak would be: Invisible-Cloaking Texture-Visible.

With appropriate voice files added of course ("She's Cloaking Captain!" & "Ship Decloaking!") :D
"Don't think of it as being out-numbered, think of it as having a WIDE target selection!"

"I am the one and ONLY Star Dragon..."
Proof for the noobs:  Member Search

[I'm Just an idea guy, NOT: a modeler, texturer, or coder... Word of advice, "Watch out for the ducks!"]

Robotech II - Continuing...
FS2 Trek - Snails move faster than me...
Star Blazers: Journey to Iscandar...
FS GUNDAM - The Myth lives on... :)

 

Offline colecampbell666

  • I See Dead Pictures
  • 212
  • Evolution and ascension.
Interesting Idea, but there would be a few complications arising from using "C"

"Now cloaking!" *Presses "C"*
"Orders recieved, attacking target!"
"No! I said cloaking!" *Presses "C" again*
"New orders, all units fire on target GTD Cloaked!"
*Alpha 1's anti-stupidity device detonates*
Gettin' back to dodgin' lasers.

 

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
if they ever get around to fixing rtt it might be possible to sctipt stuff like this in :D

come to think of it you could probibly do this with an animated texture, well sorta. you have several versions of a texture, one with full alpha, and several others incrimentally less alpha. then you tell your script to swap out the ship textures for progressively more transparent ones untill youre using very little alpha. then switch over to invisible when fully cloaked. if i did it id have a few maps with a noisy alpha map in the 0-8 range on the grey meter. then you randomly swap between them. this should cause a ghostly shimmer to hint you that the ship is there. or do like they had in avp, where you get the shimmer texture while moving around and go completely invisible when youre hardly moving.

side effect is you have to have this done for every texture the ship uses, thus increasing texture usage. could probibly be maid faster if you could replace say a -trans map for a model, without touching the diffuse texture. you may also have problem replacing ships that already use animated textures, like thruster flames. least in my build i found i had trouble indexing textures on ships with animated parts. should probibly mantis that bug if it hasnt been already.
« Last Edit: September 09, 2007, 11:12:36 am by Nuke »
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN

 

Offline Getter Robo G

  • 211
  • Elite Super Robot Pilot
Nice, but then an ani would need to be custom for each ship... UNLESS you made it overlay the ship like an effect and it slowly blurred out the ship and the ship mesh  goes before the ani ends... Yes... (well unless I'm thinking of something else) Technically, any glows on a ship should be seen also just dimmer, or getting brighter for an ideal cloak effect.

I already posted in the trek thread last year I think of what it looked like "going cloaked" it was a fredded timed event not a key press event. Once I foudn I did not like the look I stopped exploring the possibility.
"Don't think of it as being out-numbered, think of it as having a WIDE target selection!"

"I am the one and ONLY Star Dragon..."
Proof for the noobs:  Member Search

[I'm Just an idea guy, NOT: a modeler, texturer, or coder... Word of advice, "Watch out for the ducks!"]

Robotech II - Continuing...
FS2 Trek - Snails move faster than me...
Star Blazers: Journey to Iscandar...
FS GUNDAM - The Myth lives on... :)

  

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
youd need rtt to get a smooth translation or alot of textures. you could probibly do a white elephant ship, that would be used in certain mission. but the solution is not really feasable for every ship in the game. you might be able to do a rapid cloak effect, concealing the texture changeover in a cloud of particles.
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN

 
you might be able to do a rapid cloak effect, concealing the texture changeover in a cloud of particles.

That's sort of what Freelancer did. It worked pretty well.

 

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
i was about to report that texture replacement bug on mantis, but i tried to write a script to explain the bug but i couldnt get it to not work. so i guess it got fixed. i gonna try to make a cloaking system in the way i stated earlyer. with luck it will work.

http://www.youtube.com/watch?v=OTOWUAY8NJ0

Code: [Select]
;;cloakint


#Global Hooks
$GameInit:
[

cloaktex = { gr.loadTexture("apis-c00"), gr.loadTexture("apis-c01"), gr.loadTexture("apis-c02"),
gr.loadTexture("apis-c03"), gr.loadTexture("apis-c04"), gr.loadTexture("apis-c05"),
gr.loadTexture("apis-c06"), gr.loadTexture("apis-c07"), gr.loadTexture("apis-c08"),
gr.loadTexture("apis-c09"), gr.loadTexture("apis-c10"), gr.loadTexture("apis-c11"),
gr.loadTexture("apis-c12"), gr.loadTexture("apis-c13"), gr.loadTexture("apis-c14"),
gr.loadTexture("apis-c15") } --array of cloak textures

cloakticker = 750 -- countdown timer
cloaklevel = 0 -- cloaklevel, how cloaked we are
cmapindex = 0 -- this stores an index for which texture were using

]
$Simulation:
[

if cloakticker > 0 then --counting down to cloak engage, all this stuff is called every frame
cloakticker = cloakticker - 1
else
cloak = true
end

if cloak and cloaklevel < 160 then --if its time to cloak and were not already fully cloaked
cloaklevel = cloaklevel + 1

cmapindex = math.floor(cloaklevel / 10) --convert are cloaklevel into an index
end

ship = mn.Ships["Alpha 1"] --get alpha 1's ship

if cloaked ~= true and ship:isValid()and cmapindex > 0 then --if alphas alive and were cloaking set texture, but not if our cloak is complete
for i=1, #ship.Textures do
ship.Textures[i] = cloaktex[cmapindex] --change all the ships textures
end

if campindex == 16 then cloaked = true end --tell this if to stop changing textures when were done
end

]
#end

anyway i created a 16 frame cloaking animation, i added some noise to the alpha channel which i brightened up to almost white, i also copied the texture to a new layer and applied the glowing edges filter, set blending mode to darken and opacity to 10%. and saved the first frame as a dxt5. for each frame i increased the opacity the the glowey layer by 10% and decreased the brightness of the alpha chanel by 15. saving each time. when my opacity for my effect layer reached 100, i started increasing its contrast by 20%. untill 16 frames were created. i didnt create an eff instead i let the frames be handeled by the script. you could probibly rewrite it so that the game will automatically load cloak textures automatically for longer or shorter animations. mind you the apis is a 1 texture model. ships with more than one texture might look wierd or youd need to add more maps to the list for the other objects. also you break your lod textures. thruster flames are still drawn and youre still targetable. but i suppose a proper implementation would have fred trigger the script and enable stealth for you. also i only wrote this to engage and stay on, youd have to change the maps in reverse order to decloak, returning to the first map. the cloakmap eats up 5.33 megs of space, and will reside in vid mem untill you exit, as i wrote it. a proper implementation would need to free those textures when theyre no longer in use. i also got this example working in less than an hour.
« Last Edit: September 09, 2007, 03:18:28 pm by Nuke »
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN

 

Offline Getter Robo G

  • 211
  • Elite Super Robot Pilot
WOW!!! I'd say you're halfway there, it certainly did fade out over time!!!! :yes:

Now as to how to "de-cloak" can you Fred it to turn off/reverse?
(Note I barely understood how you did it, but not the implications of true functioning).

I'll send you an "appropriate" ship for testing purposes later.

Hopefully you'll get this to the point an idiot (like me) can use it.  :lol:

"Don't think of it as being out-numbered, think of it as having a WIDE target selection!"

"I am the one and ONLY Star Dragon..."
Proof for the noobs:  Member Search

[I'm Just an idea guy, NOT: a modeler, texturer, or coder... Word of advice, "Watch out for the ducks!"]

Robotech II - Continuing...
FS2 Trek - Snails move faster than me...
Star Blazers: Journey to Iscandar...
FS GUNDAM - The Myth lives on... :)

 

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
and what exactly is wrong with my zod assault fighter? :D
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN

 

Offline BS403

  • 29
  • I'm just sitting in my Cave.
wow thats some damn fine work Nuke :eek2:
http://woogleville.myminicity.com/

Homer: Aw, twenty dollars! I wanted a peanut!
Homer's Brain: Twenty dollars can buy many peanuts.
Homer: Explain how.
Homer's Brain: Money can be exchanged for goods and services.
Homer: Woo-hoo!

 

Offline JGZinv

  • 211
  • The Last Dual! Guardian
    • The FringeSpace Conversion Mod
A question for you Nuke, is/would your script be compatible with
weapons?

Logistics aside, I've got a potential use for it but I may not end up
using a weapon type for what I'm looking at doing. May have to go with
a ship as weapon.

Great work there and looking forward to see what develops.
True power comes not from strength, but from the soul and imagination.
Max to PCS2 to FS2 SCP Guide
The FringeSpace Conversion Mod

 

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
im not sure. both ship and ewapon are dirivitives of the object class. and if you can swap a ship's textures i dont see why you cant change a weapons.

as for cloaking im working on making the cloaking effect controlled by a sexps.
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN

 

Offline Goober5000

  • HLP Loremaster
  • 214
    • Goober5000 Productions
*checks watch*

Well, now we have a benchmark.  14 months from SCP implementation to half-assed community reimplementation. :sigh:
http://www.hard-light.net/forums/index.php/topic,40783.0.html
http://www.hard-light.net/forums/index.php/topic,41365.0.html

 

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
my implementation was only half assed because i was trying to inspire the others to pick up on scripting. it just happens that my implementation was suprising to me and was showoff worthy :D

i was sorta in the process of de-half assing it :D
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN