Hard Light Productions Forums
Modding, Mission Design, and Coding => The FRED Workshop => Topic started by: Mpez on February 15, 2011, 02:49:08 pm
-
I have an idea to simulate this http://i.ytimg.com/vi/-qRJDv5UcRc/hqdefault.jpg , http://lparchive.org/Freespace-2/Update%2033/img-1.png (the "command battle view") in game. I've got a problem though. Is there a way to use flat images (icons) in 3d space? I mean, to add icons into the game which would behave like those seen in the briefing (so, basically - how to implement sprites into FS?). I thought of simulating this using show-subtitle-image, but camera movements and zoom would be hard to do that way.
-
You could use glowpoints for that.
Make an invisible ship (take a preferably low-poly, like the SJD Sathanas) ship, change all textures to "invisible" in PCS2. Add one large glowpoint named whatever-your-sprite-is. Table this model into FS for use. Repeat for every sprite you want to get into FS this way.
-
Well, it works (kinda). I've done as you suggested (btw. kudos for Hades for helping me achieve that). It's working but...
http://img201.imageshack.us/img201/1512/fredp.jpg
I assume all glowpoint textures are somehow made round. The erinyes icon I made had proper proportions but after becoming a glowpoint it changed shape to what is shown in the link.
-
Hmm, try making the icon square, I suspect that will help.
-
Yeah, it helped. Thank you! :)
I've got one more problem. I made a quick "command style" interface and used it using the show-subtitle-image sexp:
$Formula: ( when
( has-time-elapsed 15 )
( show-subtitle-image
"2_Campaign4"
0
0
( true )
( true )
100
100
9999
)
)
The interface image is basically a graphic frame. The problem is I can't make the center transparent. I tried using the blue and green colours that are used in the original vps but the engine doesn't make them transparent.
-
The blue and green colours will only become transparent in specific circumstances, and this way is mostly deprecated.
Just make your screen a PNG with transparency, that should do the trick.
-
It's working, thanks for the help :)
[attachment deleted by ninja]
-
Ok, (probably) my last issue for now: does show-subtitle-image work with .anis? Is there a way of displaying animated images in the game (apart from fiddling with the hud)? I just want to make the CB_default.ani (default briefing ani) appear at the beginning of the mission.
-
Swifty's HUD code should allow that but it can't be done yet, to my knowledge.
-
I'll try the hard way then. I assume setting up 104 events for 104 frames of a shorter version of the ani won't be that painful. By the way, what is the maximum number of sexp events? ;)
-
You should probably just use one event with 104 arguments, each argument a frame filename, invalidating one argument every frame. :|
-
Something like this (0001, 0002 being the first 2 frames): ?
$Formula: ( when-argument
( any-of "1" )
( true )
( show-subtitle-image
"0001"
0
0
( true )
( true )
0
0
66
)
( invalidate-argument "1" )
( when-argument
( any-of "2" )
( true )
( show-subtitle-image
"0002"
0
0
( true )
( true )
0
0
66
)
( invalidate-argument "2" )
)
etc.
)
I'll try it tomorrow, thanks for your help.
EDIT: Ok, I tried it and it doesn't work. Apparently I don't know how to use arguments in this situation. If someone could provide a formula for the first frames I would be very grateful.
-
It's working, thanks for the help :)
Now team up with Ransom and create Windmills: The Interactive Movie.