Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » Scripts
Scripts [message #19418] Thu, 08 May 2003 10:25 Go to next message
kawolsky is currently offline  kawolsky
Messages: 1012
Registered: February 2003
Location: England
Karma: 0
General (1 Star)
I have just started making scripts,
does anyone no of any GOOD, WORKING scripts (notice i say WORKING, not "gimme mod that crashes me to desktop when i activate")
any help would be......good
thnx


http://www.n00bstories.com/image.fetch.php?id=1014344989
http://www.renevo.com/wol_stats/?nick=aimbots0&img=2
"It's a question of mind over matter, I don't mind and you don't fu*king matter"
Scripts [message #19419] Thu, 08 May 2003 10:27 Go to previous messageGo to next message
kawolsky is currently offline  kawolsky
Messages: 1012
Registered: February 2003
Location: England
Karma: 0
General (1 Star)
at the moment i have the recon bike one the cargo truck one and SSM one,
(i would like one for hover craft if anyone knows it)


http://www.n00bstories.com/image.fetch.php?id=1014344989
http://www.renevo.com/wol_stats/?nick=aimbots0&img=2
"It's a question of mind over matter, I don't mind and you don't fu*king matter"
Scripts [message #19424] Thu, 08 May 2003 10:46 Go to previous messageGo to next message
[REHT]Spirit is currently offline  [REHT]Spirit
Messages: 277
Registered: April 2003
Karma: 0
Recruit

http://www.theoriginialmrbob.com/~namehunter/TechHQ.html has some. They might lag up MP after a while, though (if you're going to play them online).
Scripts [message #19602] Fri, 09 May 2003 08:50 Go to previous messageGo to next message
kawolsky is currently offline  kawolsky
Messages: 1012
Registered: February 2003
Location: England
Karma: 0
General (1 Star)
[REHT

Spirit]www.theoriginialmrbob.com/~namehunter/TechHQ.html has some. They might lag up MP after a while, though (if you're going to play them online).


that site does not work


http://www.n00bstories.com/image.fetch.php?id=1014344989
http://www.renevo.com/wol_stats/?nick=aimbots0&img=2
"It's a question of mind over matter, I don't mind and you don't fu*king matter"
Scripts [message #19615] Fri, 09 May 2003 11:45 Go to previous messageGo to next message
England is currently offline  England
Messages: 618
Registered: February 2003
Location: High Wycombe, England
Karma: 0
Colonel
Its the http://www.theoriginalmrbob.com/~namehunter/TechHQ.html he cant spell

In the end it doesn't matter if you are who you say you are. You will still mean nothing to me.

When i have kids, everytime i drive past a fast food restaurant, im gonna punch my kid in the face, then they'll never wanna come..
Scripts [message #19640] Fri, 09 May 2003 13:56 Go to previous messageGo to next message
Dante
Messages: 1039
Registered: February 2003
Karma: 0
General (1 Star)
i still don't see the draw to c130 drop cinematics that only drop on Nod side...

it is possible to drop on both sides when the c130 comes in, yet i always see them so one sided...


try more original ideas like this

;_________________________________________
;
; Available Cinematic Script Commands
;
; time/frame	Create_Object,	id (slot), preset_name, x, y, z, facing, animation
; id can be -1 to mean do not store this object, and do not destroy
; 0 Create_Object, 0, .44 Magnum, 0, 0, 0, 180, "Human.jump"
;
; time/frame	Destroy_Object, id (slot)
; 0 Destroy_Object, 0
;
; time/frame	Play_Animation, id (slot), animation_name, looping, sub_obj_name
; 0 Play_Animation, 0, "Human.Jump", false
;
; time/frame	Control_Camera,	id ( slot )
; use id -1 for disabling control;
; note this will also disable star control and disbale the hud
; 0 Control_Camera,	0
;
;_________________________________________

;*******************  CHEAT SHEET ******************************

;Start frame	create_object	slot number	model	x,y,z,facing	animation name( model*hierarchy*.anim )
;Start frame	Play_Animation 	slot number	anim name ( model*hierarchy*.anim )	looping		Sub Object
;Start frame	Play_Audio	wave filename	slot number	bone name
;								* no slot # / bone name = 2D Audio
;0= NO LOOP ( kills object when finshed )	1= LOOP


; ****************************** camera
-0	Enable_Letterbox,	1, 1
-0	Create_Object,		0, "X3D_Tester"
-0	Play_Animation,		0, "X3D_Tester.X3D_Tester", 1
-0	Control_Camera,		0
-0	Set_Screen_Fade_Color,		0,0,0,0
-0	Set_Screen_Fade_Opacity,	1,0
-0	Set_Screen_Fade_Opacity,	0,2
-950	Set_Screen_Fade_Opacity,	0,1.5
-1100	Set_Screen_Fade_Opacity,	0,0
-1001	Control_Camera,		-1
-1001	Destroy_Object, 	0
-1001	Enable_Letterbox,	0, 1


; ****************************** Drop Off Guy
; ****************************** Path

-351	Create_Object,		2, "X5D_Chinookfly",			0, 0, 0, 0
-351	Play_Animation,		2, "X5D_Chinookfly.X5D_Chinookfly", 1
-630 	Destroy_Object,		2

; ****************************** Nod Chinook

-351	Create_Real_Object,	1, "Nod_Transport_Helicopter", 2, "BN_chinook_1"
-351      Attach_Script,          1, "M07_Disable_Hibernation", "1"		
-351	Play_Animation,		1, "v_Nod_Trnspt.v_Nod_Trnspt", 1
-351	Attach_To_Bone,		1, 2, "BN_chinook_1"
-630 	Destroy_Object,		1


; ****************************** Parachute_2

-529	Create_Object,		4, "X5D_Parachute",			0, 0, 0, 0
-529	Play_Animation,		4, "X5D_Parachute.X5D_ParaC_2", 1
-620	Destroy_Object,		4


; ****************************** Box 2
-505	Create_Object,		7, "X5D_Box02",				0, 0, 0, 0
-505	Play_Animation,		7, "X5D_Box02.X5D_Box02", 1
-620 	Destroy_Object,		7

; ****************************** Troop 1
-515	Create_Real_Object,	10, "Nod_MiniGunner_1Off", 7, "Box02"
-515    Attach_Script,          10, "M00_No_Falling_Damage_DME", ""
-515	Attach_To_Bone,		10, 7, "Box02"
-515	Play_Animation,		10, "H_A_X5D_ParaT_2", 0
-615	Attach_To_Bone,		10, -1, "Box02"
-700	Play_Animation, 	10, "H_A_PUNCHCOMBO", 0
-791	Play_Animation, 	10, "H_A_CRESENTKICK", 0
-825	Play_Animation, 	10, "H_A_PUNCHCOMBO", 0
;-900	Play_Animation, 	10, "H_A_SIDEKICK", 0
;-915	Play_Animation, 	10, "H_A_PUNCHCOMBO", 0

-1001	Attach_Scripts, 	10, "M00_Base_Defense", "0,300,2"


; ****************************** sounds
-0	Play_Audio,		"OnYourFeet"



stuff like this is more useful, than spawning 900 bots in a Nod base[/quote]


Scripts [message #19642] Fri, 09 May 2003 14:02 Go to previous messageGo to next message
[REHT]Spirit is currently offline  [REHT]Spirit
Messages: 277
Registered: April 2003
Karma: 0
Recruit

Dante

i still don't see the draw to c130 drop cinematics that only drop on Nod side...

it is possible to drop on both sides when the c130 comes in, yet i always see them so one sided...



Aye, we haven't quite figured out how to make it drop on both sides in more then one map. That's why he does things like add orcas and stuff. For some reason or another he's going more for "jam whatever you can with whatever animations you can to make the greatest and neatest effect" scripts atm.

Personally I don't care so long as it looks cool Very Happy

And in my opinion, the mutant one is balanced. SP mutants are weak on their own, do a lot of damage in groups, yet still have not a lot of HP. So long as you can keep them off the tiberium, you'll have no prob knocking them off. I've listened to storys he's told me about this and "GDI is usually the team winning mainly due to the fact that they get a lot of points from killing mutants".

Plus he tries to stick to server-side modding with c130s, so he doesnt normally do custom paths.
Scripts [message #19658] Fri, 09 May 2003 15:32 Go to previous messageGo to next message
Dante
Messages: 1039
Registered: February 2003
Karma: 0
General (1 Star)
here ya go.... a little tut for the cinematics i just whipped up real quick

So you want to create new Text Cinematic Scripts, but aren't sure what all that jibberish means....


Here is a good breakdown quick tutorial on how to make them, and what exactly you are doing when you make them.

Ok, first, lets look at the available commands, then I will discuss each one.
I am not 100% positive the actual use for the unk* parameters.


time/frame Create_Object, id (slot), preset_name, x, y, z, facing, animation
time/frame Create_Real_Object, id (slot), preset_name, id (to create at), bone_name_at
time/frame Destroy_Object, id (slot)
time/frame Play_Animation, id (slot), animation_name, looping, sub_obj_name
time/frame Play_Audio, wave_filename, id (slot), bone_name
time/frame Attach_Script, id (slot), Script_Name, Script_Parameters
time/frame Attach_To_Bone, id (slot), id (slot) 2, bone_name
time/frame Control_Camera, enable
time/frame Enable_Letterbox, enable, unk1
time/frame Set_Screen_Fade_Color, unk1, unk2, unk3, unk4
time/frame Set_Screen_Fade_Opacity, fade_in_depth, fade_out_depth
time/frame Send_Custom, id, message, parameter
time/frame Set_Primary, id (slot)


Each Item Explained:
Create_Object:
use this to create script used objects ONLY, these cannot be killed, as they are just "visual effects"
id (slot) = use this to identify the object for later script calls, or set to -1 to have it not be destroyed after the script expires.
preset_name = This is the w3d name of the object to create without the .w3d at the end, you better have this in either you .mix, .pkg, or data dir, or it will crash the game.
x = x position on the map to create
y = y position on the map to create
z = z position on the map to create
facing = the direction the object will be facing when created
animation = creation animation to play

Create_Real_Object:
use this script to create any objects that you will be keeping in the level, like Troops dropped from a chinook
id (slot) = use this to identify the object for later script calls, or set to -1 to have it not be destroyed after the script expires.
preset_name = This is the preset name of the item to create, you can find these in the Object tree in Level Edit, you can create ANY of these.
id (to create at) = the object that this will be created at, the engine uses this as a reference point of where to create it.
bone_name_at = the specific bone to create the object at.
if the id(to create at) and the bone_name_at are blank, it will create at the root of the script (where it was called from)

Destroy_Object:
this is a cleanup script, use this to get rid of cinematic items no longer in use, and objects that are being destryed via a cinematic.
id (slot) = id of the object to destroy

Play_Animation:
Use this to play an animation from within the w3d of the object, or by forcing a skeleton animation from a character.
id (slot) = the id of the object you want to play the animation
animation_name = this is ALWAYS the w3d name - the .w3d, then the animation name (mode.animation)
looping = 0 will only play it once, 1 will loop it until the object is destroyed
sub_obj_name = this specifies that a sub object to the id (slot) is to play the animation, example would be having a character move the mouth to talk
the sub_obj_name is optional

Play_Audio:
use this to play any sounds during a text cinematic
wave_filename = contrary to popular belief, this is the preset name of the sound, they can be found in LE under Sounds.
id (slot) = id of the cinematic object to attach to
bone_name = bone name of the location to play it at
if the id (slot) and bone_name are left blank, the sound becomes a 2d sound, if the preset is 3d, it will be heard only at the root of the scripts (where it was called from)

Attach_Script:
use this to attach scripts to real objects that are created in the cinematic.
id (slot) = id of the object to attach the script to
Script_Name = name of the script to attach
Script_Parameters = parameters of the script, if you have more than one parameter seperate them by commas.
the script name and the script paramaters must be in quotation marks

Attach_to_Bone:
this script is to attach objects either real or cinematic to a bone of another object.
id (slot) = id of the object you want to attach
id (slot) 2 = id of the object you want to attach to
bone_name = name of the bone on the object you are attaching to that you wish to attach to
note, to detach from the bone, set the id (slot) 2 to -1

Control_Camera:
this is used to control the camera during special circumstances in game, DONOT FORGET to disable this, or Ren will be stuck.
enable = 0 to control, -1 to resume normal game
if you don't have a camera object, the camera will show at the script root (where it was called from)

Enable_Letterbox:
this is used to give it that "widescreen" effect in cutscenes.
enable = 1 to enable it, 0 to disable it
unk1 = not sure what this is, but is always set to 1
another one that you don't want to forget to turn off

Set_Screen_Fade_Color:
this one i am quite unfamiliar with, but i am sure that it has something to do with the color of the screen when you use the set screen fade opacity.
unk1, unk2, unk3, unk4 = all unknown values, but almost always 0, 0, 0, 0

Set_Screen_Fade_Opacity:
this script is used to "smooth" the transitions of controlling the camera, as it can have a choppy appearance when you enable and disable it.
fade_in_depth = this is the amount to fade in, i believe 2 is max
fade_out_depth = this is the amount to fade out, again, i believe that 2 is the max.

Send_Custom:
this script is used to communicate with the other scripts on object in a level, don't use this unless you knwo what you are doing
id = id of the object IN the level, you MUST know the id of the object, otherwise you are sending it no where.
message = this is the message number you are sending
parameter = this is the parameter for that message
this is one of the least used scripts for regular in game cinematics

Set_Primary:
this scripts sets the scenes primary object
id (slot) = the id of the object to set to primary
again, this is a rarely used item.


Part 2 [message #19660] Fri, 09 May 2003 15:33 Go to previous messageGo to next message
Dante
Messages: 1039
Registered: February 2003
Karma: 0
General (1 Star)
Now.. you have a good idea of what each one does, lets examine an example script, and what it does.

We will create a basic drop off, with a letterbox camera watching it happen.
Here is the resources used in this example, all found in always.dat

Presets Used in this Example Scipt:
Objects:
GDI_Transport_Helicopter
GDI_MiniGunner_0
Sounds:
OnYourFeet
Door_Open
Rope_Out
Door_Close
Rope_Retract

W3D Animations Used:
XG_TransprtBone.w3d
BN_Trajectory.w3d
XG_RT_rope.w3d
XG_RT_TroopBone.w3d
XG_RT_AudioA.w3d
XG_RT_AudioZ.w3d

Scripts Used:
WS Scripts.dll:
M00_Base_Defense
Custom Scripts.dll:
n/a

ok, on to the scripting:

First, lets do the camera stuff, as it is the most important to get right.

-0 Enable_Letterbox, 1, 1
-0 Control_Camera, 0
-0 Set_Screen_Fade_Color, 0, 0, 0, 0
-0 Set_Screen_Fade_Opacity, 1, 0
-10 Set_Screen_Fade_Opacity, 0, 0
-760 Set_Screen_Fade_Opacity, 0, 2
-800 Set_Screen_Fade_Opacity, 0, 0
-800 Control_Camera, -1
-800 Enable_Letterbox, 0, 1

now, what did we just do there, simple, first we turned on letterbox and enabled the control of the camera.
next we set the fade color and started a fade in effect
now, after a full 760 frames of our cinematic plays, we will begin the fade out a little bit slower than the fade in
then finally disable camera control, and take away the letterbox effect.

next, lets create some real stuff to look at (*note, by adding the above to a cinematic, you may not be able to view the next items without a custom camera view)

first the path, which is named XG_TransprtBone.w3d and is in always.dat
-0 Create_Object, 1, "XG_TransprtBone",
-0 Play_Animation, 1, "XG_TransprtBone.XG_RT_TrajA", 0
-401 Play_Animation, 1, "XG_TransprtBone.XG_RT_TrajL", 1
-1000 destroy_object, 1

now, you are wondering what THAT did?, simple, it created a path definition (bones only w3d) and played a couple of the internal animations for it at certain times

next, we create3 a chinook that can be killed
-0 Create_Real_Object, 2, "GDI_Transport_Helicopter", 1, "BN_Trajectory"
-0 Attach_to_Bone, 2,1,"BN_Trajectory"
-0 Play_Animation, 2, "v_GDI_trnspt.XG_RT_trnsptA",0
-401 Play_Animation, 2, "v_GDI_trnspt.XG_RT_trnsptL",1
-1000 destroy_object, 2

there, we hae created a visual item, attached it to a path, and played the specified internal animations at the same time as our path is happening
basically, the first animation is the flying, the second animation is the troop information


now to create a rope for the soldier to go down

-0 Create_Object, 3, "XG_RT_rope", 0, 0, 0, 0
-0 Play_Animation, 3, "XG_RT_rope.XG_RT_ropeA", 0
-401 Play_Animation, 3, "XG_RT_rope.XG_RT_ropeL", 1
-760 destroy_object, 3

the animations in this part are simply having the rope wiggle around a bit from at the time the troop is on it, and unrooling and rolling up at the specified times

next, make a troop bone, why you ask, so the troop moved DOWN the rope instead of just sitting in the chinook

-401 Create_Object, 4, "XG_RT_TroopBone", 0, 0, 0, 0,
-401 Play_Animation, 4, "XG_RT_TroopBone.XG_RT_TroopBone",0
-490 destroy_object, 4

now there is a bone in place, and ready to "slide" down the rope when the troop drops

now lets create a character that will drop out of the chinook

-401 Create_Real_Object, 5, "GDI_MiniGunner_0", 2, "SPAWNER"
-401 Play_Animation, 5, "S_A_Human.H_A_TroopDrop", 0
-401 Attach_to_Bone, 5,4,"Troop_L"
-490 Attach_to_Bone, 5,-1,"Troop_L"
-690 Attach_Script, 5, "M00_Base_Defense","300,10,2"

now, notice here, that it has a bone that it creates at, and an id specified, that means that it will create where the spawner bone is on the transport helicopter.
then, at the specified time, it plays the rope animation, attaches to the rope (because of the troop bone it slides down) then removes from the rope.
and finally, we gave it a basic base defense script that will enable a bit of AI in the unit.

finally, we do basic cleanups for our objects

1000000 Destroy_Object, 1
1000000 Destroy_Object, 2
1000000 Destroy_Object, 3
1000000 Destroy_Object, 4

the 1000000 is a standard time amount in all the westwood text cinematics, i personally would just use 800

oh wait you ask, what about adding some sound to this cinematic????

you don't want a boring silent chinook coming and and not making any sound do you?

ok, here we go, lets do the sound section now. im not going to get too exact, but you will get the idea

-0 Play_Audio, "OnYourFeet"
-280 Create_Object, 6, "XG_RT_AudioA"
-280 Play_Animation, 6, "XG_RT_AdioA.XG_RT_AudioA", 0
-280 Play_Audio, "Door_Open", 6, "BN_CH_Dooropen"
-281 Play_Audio, "Rope_Out", 6, "BN_Rope"
-668 Create_Object, 7, "XG_RT_AudioZ"
-668 Play_Animation, 7, "XG_RT_AudioZ.XG_RT_AudioZ", 0
-668 Play_Audio, "Door_Close", 7, "BN_CH_Doorclose"
-668 Play_Audio, "Rope_Retract", 7, "BN_Rope"
1000000 Destroy_Object, 6
1000000 Destroy_Object, 7


wow, thats alot of sound effect no? simply explained, first, play some background music to set your mood
next, create audio bones to attach the 3d sound effects to
then, at the correct times, play the door open sound effect, the rope rolling out sound effect, the play the door close and the rope retract sfx

wait... what about the chinook sound effect, how will i hear that???
well some items have the built in sound effect, the chinook for example uses the engine run sound effect while an animation is playing.

if you are wondering, how do you find out how long animations are, simply open up the w3d in w3d viewer, and then select the animation, in the status bar, it will show you the total number of frames for that animation.
as far as bone names, you can open the w3d up in wdump and check out the bone names from there.

now, there you have it, that is how you can create all types of cinematics, and you have the use of them throughout the entire level.
by creating test_cinematic objects, or attaching the poke_and_play_cinematic you can add some really kewl effects to your mod.




mirrored on http://Modx.RenEvo.Com


Scripts [message #19675] Fri, 09 May 2003 16:38 Go to previous messageGo to next message
[REHT]Spirit is currently offline  [REHT]Spirit
Messages: 277
Registered: April 2003
Karma: 0
Recruit

Laughing

What I ment was: We don't know (although haven't looked) the co-ords for a position that will work for GDI on all maps. We know dang well how to work c130 scripts (or at least we think we do, lol), we just haven't looked up the map co-ords.

However, that's a dang good tutorial there.
Scripts [message #19676] Fri, 09 May 2003 16:42 Go to previous messageGo to next message
Dante
Messages: 1039
Registered: February 2003
Karma: 0
General (1 Star)
with a bit of mix editing server-side, and some customizations, each map can have a different c130 drop script...

Scripts [message #19677] Fri, 09 May 2003 16:45 Go to previous messageGo to next message
[REHT]Spirit is currently offline  [REHT]Spirit
Messages: 277
Registered: April 2003
Karma: 0
Recruit

........??????!!! Confused

Oooooooooooooooooooh wait I see.

Last time I heard someone doing that, he got stuck with a curse Laughing

Maaaan I never thought about that. And yet........I wonder.......
Scripts [message #19686] Fri, 09 May 2003 19:25 Go to previous messageGo to next message
bigwig992 is currently offline  bigwig992
Messages: 555
Registered: February 2003
Location: Nashua, NH
Karma: 0
Colonel
Awesome, I always wondered about cinematic scripts, I'm going to give it a try.

-The ONLY Renegade fan to pee off a school.
http://www.n00bstories.com/image.fetch.php?id=1055662786
http://www.n00bstories.com/stats/renegade_stats.php?player=bigwig992&team=gdi
Scripts [message #19697] Fri, 09 May 2003 20:45 Go to previous messageGo to next message
Captkurt
Messages: 488
Registered: February 2003
Karma: 0
Commander
Dante

here ya go.... a little tut for the cinematics i just whipped up real quick

So you want to create new Text Cinematic Scripts, but aren't sure what all that jibberish means....


Here is a good breakdown quick tutorial on how to make them, and what exactly you are doing when you make them.

Ok, first, lets look at the available commands, then I will discuss each one.
I am not 100% positive the actual use for the unk* parameters.


time/frame Create_Object, id (slot), preset_name, x, y, z, facing, animation
time/frame Create_Real_Object, id (slot), preset_name, id (to create at), bone_name_at
time/frame Destroy_Object, id (slot)
time/frame Play_Animation, id (slot), animation_name, looping, sub_obj_name
time/frame Play_Audio, wave_filename, id (slot), bone_name
time/frame Attach_Script, id (slot), Script_Name, Script_Parameters
time/frame Attach_To_Bone, id (slot), id (slot) 2, bone_name
time/frame Control_Camera, enable
time/frame Enable_Letterbox, enable, unk1
time/frame Set_Screen_Fade_Color, unk1, unk2, unk3, unk4
time/frame Set_Screen_Fade_Opacity, fade_in_depth, fade_out_depth
time/frame Send_Custom, id, message, parameter
time/frame Set_Primary, id (slot)


Each Item Explained:
Create_Object:
use this to create script used objects ONLY, these cannot be killed, as they are just "visual effects"
id (slot) = use this to identify the object for later script calls, or set to -1 to have it not be destroyed after the script expires.
preset_name = This is the w3d name of the object to create without the .w3d at the end, you better have this in either you .mix, .pkg, or data dir, or it will crash the game.
x = x position on the map to create
y = y position on the map to create
z = z position on the map to create
facing = the direction the object will be facing when created
animation = creation animation to play

Create_Real_Object:
use this script to create any objects that you will be keeping in the level, like Troops dropped from a chinook
id (slot) = use this to identify the object for later script calls, or set to -1 to have it not be destroyed after the script expires.
preset_name = This is the preset name of the item to create, you can find these in the Object tree in Level Edit, you can create ANY of these.
id (to create at) = the object that this will be created at, the engine uses this as a reference point of where to create it.
bone_name_at = the specific bone to create the object at.
if the id(to create at) and the bone_name_at are blank, it will create at the root of the script (where it was called from)

Destroy_Object:
this is a cleanup script, use this to get rid of cinematic items no longer in use, and objects that are being destryed via a cinematic.
id (slot) = id of the object to destroy

Play_Animation:
Use this to play an animation from within the w3d of the object, or by forcing a skeleton animation from a character.
id (slot) = the id of the object you want to play the animation
animation_name = this is ALWAYS the w3d name - the .w3d, then the animation name (mode.animation)
looping = 0 will only play it once, 1 will loop it until the object is destroyed
sub_obj_name = this specifies that a sub object to the id (slot) is to play the animation, example would be having a character move the mouth to talk
the sub_obj_name is optional

Play_Audio:
use this to play any sounds during a text cinematic
wave_filename = contrary to popular belief, this is the preset name of the sound, they can be found in LE under Sounds.
id (slot) = id of the cinematic object to attach to
bone_name = bone name of the location to play it at
if the id (slot) and bone_name are left blank, the sound becomes a 2d sound, if the preset is 3d, it will be heard only at the root of the scripts (where it was called from)

Attach_Script:
use this to attach scripts to real objects that are created in the cinematic.
id (slot) = id of the object to attach the script to
Script_Name = name of the script to attach
Script_Parameters = parameters of the script, if you have more than one parameter seperate them by commas.
the script name and the script paramaters must be in quotation marks

Attach_to_Bone:
this script is to attach objects either real or cinematic to a bone of another object.
id (slot) = id of the object you want to attach
id (slot) 2 = id of the object you want to attach to
bone_name = name of the bone on the object you are attaching to that you wish to attach to
note, to detach from the bone, set the id (slot) 2 to -1

Control_Camera:
this is used to control the camera during special circumstances in game, DONOT FORGET to disable this, or Ren will be stuck.
enable = 0 to control, -1 to resume normal game
if you don't have a camera object, the camera will show at the script root (where it was called from)

Enable_Letterbox:
this is used to give it that "widescreen" effect in cutscenes.
enable = 1 to enable it, 0 to disable it
unk1 = not sure what this is, but is always set to 1
another one that you don't want to forget to turn off

Set_Screen_Fade_Color:
this one i am quite unfamiliar with, but i am sure that it has something to do with the color of the screen when you use the set screen fade opacity.
unk1, unk2, unk3, unk4 = all unknown values, but almost always 0, 0, 0, 0

Set_Screen_Fade_Opacity:
this script is used to "smooth" the transitions of controlling the camera, as it can have a choppy appearance when you enable and disable it.
fade_in_depth = this is the amount to fade in, i believe 2 is max
fade_out_depth = this is the amount to fade out, again, i believe that 2 is the max.

Send_Custom:
this script is used to communicate with the other scripts on object in a level, don't use this unless you knwo what you are doing
id = id of the object IN the level, you MUST know the id of the object, otherwise you are sending it no where.
message = this is the message number you are sending
parameter = this is the parameter for that message
this is one of the least used scripts for regular in game cinematics

Set_Primary:
this scripts sets the scenes primary object
id (slot) = the id of the object to set to primary
again, this is a rarely used item.


Good Stuff, thanks Dante
Scripts [message #19702] Fri, 09 May 2003 21:45 Go to previous messageGo to next message
bigwig992 is currently offline  bigwig992
Messages: 555
Registered: February 2003
Location: Nashua, NH
Karma: 0
Colonel
Hm. The only thing I don't understand is how the camera moves around during the cinematic, how do you control where and how the camera moves?

Also, this is what I have so far. I don't have commando onthis computer, so I'm missing a lot of extra things I could add in.

*****************Camera
-0 Enable_Letterbox, 1 1
-0 Control_Camera, 0
-0 Set_Screen_Fade_Color, 0, 0, 0, 0
-0 Set_Screen_Fade_Opacity, 1, 0
-2 Set_Screen_Fade_Opacity, 0, 0
-65 Set_Screen_Fade_Opacity, 0, 2
-72 Set_Screen_Fade_Opacity, 0, 0
-72 Set_Screen_Fade_Opacity, 0, 0
-72 Control_Camera, -1
-72 Enable_Letterbox, 0, 1
*****************Animation
-0 Create_Object, 1, "flying_bone", 0, 0, 20
-0 Play_Animation, 1, "flying_animation"
*****************A-10
-0 Create_Object, 2, "GDI_A10_Flyover", 0, 0, 20
-0 Attach_to_Bone, 2, 1, "Box01"
-71 Destory_Object, 2
*****************Pilot Eject
-30 Create_Real_Object, 3, "AI_GDI_RocketLancher", 1, "Box01"
-30 Create_Object, 4, "eject_stationary"
-30 Attach_to_Bone, 4, 1, "Box01"
-30 Attach_to_Bone, 3, 4, "eject"
-30 Attach_Script, 3, "M00_Base_Defense", "0,300,2"
-40 Play_Animation, 4, "eject_bone"
-50 Attach_to_Bone, 3, -2, "eject"
*****************Sounds
-0 Play_Audio



-The ONLY Renegade fan to pee off a school.
http://www.n00bstories.com/image.fetch.php?id=1055662786
http://www.n00bstories.com/stats/renegade_stats.php?player=bigwig992&team=gdi
Scripts [message #19716] Fri, 09 May 2003 23:00 Go to previous messageGo to next message
Dante
Messages: 1039
Registered: February 2003
Karma: 0
General (1 Star)
bigwig992

Hm. The only thing I don't understand is how the camera moves around during the cinematic, how do you control where and how the camera moves?

Also, this is what I have so far. I don't have commando onthis computer, so I'm missing a lot of extra things I could add in.

*****************Camera
-0 Enable_Letterbox, 1 1
-0 Control_Camera, 0
-0 Set_Screen_Fade_Color, 0, 0, 0, 0
-0 Set_Screen_Fade_Opacity, 1, 0
-2 Set_Screen_Fade_Opacity, 0, 0
-65 Set_Screen_Fade_Opacity, 0, 2
-72 Set_Screen_Fade_Opacity, 0, 0
-72 Set_Screen_Fade_Opacity, 0, 0
-72 Control_Camera, -1
-72 Enable_Letterbox, 0, 1
*****************Animation
-0 Create_Object, 1, "flying_bone", 0, 0, 20
-0 Play_Animation, 1, "flying_animation"
*****************A-10
-0 Create_Object, 2, "GDI_A10_Flyover", 0, 0, 20
-0 Attach_to_Bone, 2, 1, "Box01"
-71 Destory_Object, 2
*****************Pilot Eject
-30 Create_Real_Object, 3, "AI_GDI_RocketLancher", 1, "Box01"
-30 Create_Object, 4, "eject_stationary"
-30 Attach_to_Bone, 4, 1, "Box01"
-30 Attach_to_Bone, 3, 4, "eject"
-30 Attach_Script, 3, "M00_Base_Defense", "0,300,2"
-40 Play_Animation, 4, "eject_bone"
-50 Attach_to_Bone, 3, -2, "eject"
*****************Sounds
-0 Play_Audio




ok, #1, CRIMMY PLEASE CHANGE THE CODE WINDOW COLOR!!!! that green on green sucks ass

next, i assume the following after looking at this script...
#1, you want a stationary camera
#2, you have the following w3d's
flying_bone.w3d (next play_animation line needs to be flying_bone.flying_animation btw) with the flying_animation named properly inside it
GDI_A10_Flyover.w3d
eject_stationary.w3d (and again, eject_stationary.eject_bone for the play_animation) and an animation inside that w3d named eject_bone and a bone named eject
#3, you have created a new preset named AI_GDI_RocketLancher in LE
#4, that your entire script is only 72 frames (that is REALLY short cinematic, as it is frames, and most people get about 30-60 frames per second in Ren)

now, other than the two play_animation problems stated above, you need to correct the following.
#1, you need a sound to play for the Play_Sound Wink else it will crash Ren
#2, -50 Attach_to_Bone, 3, -2, "eject" -2 is not an option for attach_to_bone
#3, -72 Set_Screen_Fade_Opacity, 0, 0
-72 Set_Screen_Fade_Opacity, 0, 0
is pointless, you are doing the same thing twice

ok, now, in order to move the camera during the animation you must create a w3d for the camera path.


Scripts [message #19721] Sat, 10 May 2003 00:47 Go to previous messageGo to next message
Blazer is currently offline  Blazer
Messages: 3322
Registered: February 2003
Location: Phoenix, AZ
Karma: 0
General (3 Stars)
Administrator/General

Dante

with a bit of mix editing server-side, and some customizations, each map can have a different c130 drop script...


Dante is absolutely right. In fact AGES ago (before the flying patch) Abjab and I came up with c130drop scripts for each of the renegade levels, and I had a mother-of-all batch files that would automatically change it for each level. The end effect was that both teams got their flying vehicles.
Scripts [message #19722] Sat, 10 May 2003 01:00 Go to previous messageGo to next message
Blazer is currently offline  Blazer
Messages: 3322
Registered: February 2003
Location: Phoenix, AZ
Karma: 0
General (3 Stars)
Administrator/General

Quote:

ok, #1, CRIMMY PLEASE CHANGE THE CODE WINDOW COLOR!!!! that green on green sucks ass


LOL I agree, it looks like gatorade Smile
Scripts [message #19725] Sat, 10 May 2003 02:15 Go to previous messageGo to next message
General Havoc is currently offline  General Havoc
Messages: 1564
Registered: February 2003
Location: Birmingham, England, Unit...
Karma: 0
General (1 Star)
Yeah, I got the camera script from that test cinematic map you made. I understand how the script works but I couldn't figure out how you got the animation to trigger when you poked Locke. I just used JFW_Zone_Play_Cinematic to test it. The other problem was how do you know which way the camer faces in RenX when your making the aimation because that can really be a pain trying to align it, also what the animation is saved as? Pure animation?

Nice tutorial though Wink

_General Havoc


Visit my website at http://renhelp.laeubi-soft.de powered by laeubi.de
"SHUT UP AND MOD" - Dante
"ACK is the Simon Cowell of modding" - Ultron10
Scripts.dll Debugger, Map Scripter and Tutorial writer

Computer Science Bsc
Aston University in Birmingham, UK
Scripts [message #19736] Sat, 10 May 2003 05:20 Go to previous messageGo to next message
Dante
Messages: 1039
Registered: February 2003
Karma: 0
General (1 Star)
a really kewl script...

Poke_And_Play_Cinematic


Scripts [message #19738] Sat, 10 May 2003 05:40 Go to previous messageGo to next message
[REHT]Spirit is currently offline  [REHT]Spirit
Messages: 277
Registered: April 2003
Karma: 0
Recruit

Blazer

Dante

with a bit of mix editing server-side, and some customizations, each map can have a different c130 drop script...


Dante is absolutely right. In fact AGES ago (before the flying patch) Abjab and I came up with c130drop scripts for each of the renegade levels, and I had a mother-of-all batch files that would automatically change it for each level. The end effect was that both teams got their flying vehicles.


Yea, and I see how it's done. Or at least one way to do it, lol.

I feel REALLY embarrased about that because I keep feeling like I'm the guy stressing creativity...........and I forget aalll about this.
Scripts [message #19745] Sat, 10 May 2003 09:27 Go to previous messageGo to next message
bigwig992 is currently offline  bigwig992
Messages: 555
Registered: February 2003
Location: Nashua, NH
Karma: 0
Colonel
Dante

bigwig992

Hm. The only thing I don't understand is how the camera moves around during the cinematic, how do you control where and how the camera moves?

Also, this is what I have so far. I don't have commando onthis computer, so I'm missing a lot of extra things I could add in.

*****************Camera
-0 Enable_Letterbox, 1 1
-0 Control_Camera, 0
-0 Set_Screen_Fade_Color, 0, 0, 0, 0
-0 Set_Screen_Fade_Opacity, 1, 0
-2 Set_Screen_Fade_Opacity, 0, 0
-65 Set_Screen_Fade_Opacity, 0, 2
-72 Set_Screen_Fade_Opacity, 0, 0
-72 Set_Screen_Fade_Opacity, 0, 0
-72 Control_Camera, -1
-72 Enable_Letterbox, 0, 1
*****************Animation
-0 Create_Object, 1, "flying_bone", 0, 0, 20
-0 Play_Animation, 1, "flying_animation"
*****************A-10
-0 Create_Object, 2, "GDI_A10_Flyover", 0, 0, 20
-0 Attach_to_Bone, 2, 1, "Box01"
-71 Destory_Object, 2
*****************Pilot Eject
-30 Create_Real_Object, 3, "AI_GDI_RocketLancher", 1, "Box01"
-30 Create_Object, 4, "eject_stationary"
-30 Attach_to_Bone, 4, 1, "Box01"
-30 Attach_to_Bone, 3, 4, "eject"
-30 Attach_Script, 3, "M00_Base_Defense", "0,300,2"
-40 Play_Animation, 4, "eject_bone"
-50 Attach_to_Bone, 3, -2, "eject"
*****************Sounds
-0 Play_Audio




ok, #1, CRIMMY PLEASE CHANGE THE CODE WINDOW COLOR!!!! that green on green sucks ass

next, i assume the following after looking at this script...
#1, you want a stationary camera
#2, you have the following w3d's
flying_bone.w3d (next play_animation line needs to be flying_bone.flying_animation btw) with the flying_animation named properly inside it
GDI_A10_Flyover.w3d
eject_stationary.w3d (and again, eject_stationary.eject_bone for the play_animation) and an animation inside that w3d named eject_bone and a bone named eject
#3, you have created a new preset named AI_GDI_RocketLancher in LE
#4, that your entire script is only 72 frames (that is REALLY short cinematic, as it is frames, and most people get about 30-60 frames per second in Ren)

now, other than the two play_animation problems stated above, you need to correct the following.
#1, you need a sound to play for the Play_Sound Wink else it will crash Ren
#2, -50 Attach_to_Bone, 3, -2, "eject" -2 is not an option for attach_to_bone
#3, -72 Set_Screen_Fade_Opacity, 0, 0
-72 Set_Screen_Fade_Opacity, 0, 0
is pointless, you are doing the same thing twice

ok, now, in order to move the camera during the animation you must create a w3d for the camera path.


I'll try to make those changes. And oh yes, the:
-50 Attach_to_Bone, 3, -2, "eject"
is what I thought meant detatch object from bone. Oh, and give me a break on the 70 frame animation thing, this is my first cinematic ever. Smile
EDIT: Oh yeah, are animations another w3d with an animation in it, or is there a way in RenX to save just the animations? I have things like "eject_bone.w3d" (ejecting animation) and "eject_stationary.w3d", same bone just no animation. *sigh*, Dante, I think I'll need your help on AIM. Wink


-The ONLY Renegade fan to pee off a school.
http://www.n00bstories.com/image.fetch.php?id=1055662786
http://www.n00bstories.com/stats/renegade_stats.php?player=bigwig992&team=gdi
Scripts [message #19747] Sat, 10 May 2003 09:48 Go to previous messageGo to next message
bigwig992 is currently offline  bigwig992
Messages: 555
Registered: February 2003
Location: Nashua, NH
Karma: 0
Colonel
Alright, I think I get it now, I just need to know, how do I name the animation inside the w3d? Sorry, I'm not really a RenX wiz Wink .

-The ONLY Renegade fan to pee off a school.
http://www.n00bstories.com/image.fetch.php?id=1055662786
http://www.n00bstories.com/stats/renegade_stats.php?player=bigwig992&team=gdi
Scripts [message #19757] Sat, 10 May 2003 12:49 Go to previous messageGo to next message
Dante
Messages: 1039
Registered: February 2003
Karma: 0
General (1 Star)
just call them like this

play_animation eject_bone.eject_bone
play_animation eject_stationary.eject_stationary


Scripts [message #19758] Sat, 10 May 2003 13:05 Go to previous messageGo to previous message
Dante
Messages: 1039
Registered: February 2003
Karma: 0
General (1 Star)
quick explanation of some items i missed, that really don't have anything to do with text cinematic scripting....


when you see an object lets say test1.w3d, that plays an animation test2.swing_test3 then most likely test1.w3d and test3.w3d where exported using a skeleton (test2.w3d). soo, to recap in lamens terms

test1.w3d = hierarchal model exported with test2.w3d skeleton
test2.w3d = skeleton model (just bones)
swing_test3.w3d = a hierarchal animated model exported with the test2.w3d skeleton

this isn't uncommon


Previous Topic: Revamped Stealth Generators
Next Topic: Ceiling guns in CnC mode
Goto Forum:
  


Current Time: Mon Dec 23 22:15:26 MST 2024

Total time taken to generate the page: 0.01166 seconds