Call of Duty 5: Scriptable Lights: Difference between revisions

From COD Modding & Mapping Wiki
Jump to navigation Jump to search
(New page: Image:Nutshell.png A quick tutorial to place and use Flickering/Strobing Lights in MP levels; == In Radiant == *Right click in the 2D window and choose Light. *Check the '''PRIMARY_O...)
 
mNo edit summary
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
[[Image:Nutshell.png]] A quick tutorial to place and use Flickering/Strobing Lights in MP levels;
{{Warning_advanced}}
{{Note|A quick tutorial to place and use Flickering/Strobing Lights in MP levels}}


== In Radiant ==
== In Radiant ==
Line 8: Line 9:
**for a flickering light, give it a targetname of '''flicker_light'''
**for a flickering light, give it a targetname of '''flicker_light'''


[[Image:information.png]] Note that n info_null must be connected to a Primary Light for it to work, see [[Call of Duty 5: Advanced Lighting#Practical Example|HERE]]
{{Info|Note that n info_null must be connected to a Primary Light for it to work, see [[Call of Duty 5: Advanced Lighting#Practical Example|HERE]]}}


== Map GSC ==
== Map GSC ==
Line 17: Line 18:


*You must be using a MAP CSC (Clientscript) for this to work.
*You must be using a MAP CSC (Clientscript) for this to work.


== Zone File ==
== Zone File ==
Line 22: Line 24:
Make sure to have the follwing lines in your zone file:
Make sure to have the follwing lines in your zone file:


rawfile,clientscripts/mp/_load.csc
<syntaxhighlight>
rawfile,clientscripts/mp/_lights.csc
rawfile,clientscripts/mp/_load.csc
rawfile,maps/mp/mp_yourmap.gsc
rawfile,clientscripts/mp/_lights.csc
rawfile,maps/mp/mp_yourmap.csc
rawfile,maps/mp/mp_yourmap.gsc
rawfile,maps/mp/mp_yourmap.csc
</syntaxhighlight>
 


== Extras==
== Extras==
Line 36: Line 41:
* add a key '''script_delay_max''' for the most amount of time to wait, and the value of it;
* add a key '''script_delay_max''' for the most amount of time to wait, and the value of it;


For best results when using a strobe light, set the script_delay_min and script_delay_max values to the same number.<br>
For best results when using a strobe light, set the script_delay_min and script_delay_max values to the same number.
you can also use a script_wait on the light to delay between pulsing, flickering, or strobing.<br>
 
<br>
You can also use a script_wait on the light to delay between pulsing, flickering, or strobing.<br>
[[Image:information.png]] script_wait is best used for a slow strobe light, like a beacon light.
 
{{Info|script_wait is best used for a slow strobe light, like a beacon light.}}


===Glow===
===Glow===
Line 46: Line 52:


*Right-click in 2D view > script > struct
*Right-click in 2D view > script > struct
* give the script_sturct a targetname of '''lantern_glowFX_origin'''
* give the script_struct a targetname of '''lantern_glowFX_origin'''
*Place the script_struct in the exact position you want the glow to appear.
*Place the script_struct in the exact position you want the glow to appear.




Some Sources from: [http://wiki.treyarch.com/wiki/Dynamic_Lighting Treyarch's Wiki]
Some Sources from: [http://wiki.treyarch.com/wiki/Dynamic_Lighting Treyarch's Wiki]
[[Category:Lighting]]
[[Category:Lighting]]
[[Category:Call of Duty 5]]
[[Category:Call of Duty 5]]
[[Category:Mapping]]
[[Category:Mapping]]
[[Category:Advanced Editing]]
[[Category:Advanced Editing]]

Latest revision as of 15:11, 16 December 2010

A quick tutorial to place and use Flickering/Strobing Lights in MP levels

In Radiant

  • Right click in the 2D window and choose Light.
  • Check the PRIMARY_OMNI and PRIMARY_SCRIPTABLE boxes.
    • for a strobe light, give it a targetname of strobe_light
    • for a flickering light, give it a targetname of flicker_light
Note that n info_null must be connected to a Primary Light for it to work, see HERE

Map GSC

  • make sure your MAP GSC contains the following line on the top:
maps\mp\_load::main();
  • You must be using a MAP CSC (Clientscript) for this to work.


Zone File

Make sure to have the follwing lines in your zone file:

rawfile,clientscripts/mp/_load.csc
rawfile,clientscripts/mp/_lights.csc
rawfile,maps/mp/mp_yourmap.gsc
rawfile,maps/mp/mp_yourmap.csc


Extras

Delay

To set a random delay on the lights, used for flickering, pulsing, and strobing speeds:

  • add a key script_delay_min for the least amount of time to wait, and the value of it;
  • add a key script_delay_max for the most amount of time to wait, and the value of it;

For best results when using a strobe light, set the script_delay_min and script_delay_max values to the same number.

You can also use a script_wait on the light to delay between pulsing, flickering, or strobing.

script_wait is best used for a slow strobe light, like a beacon light.

Glow

For Lanterns for instance you can add glow like this:

  • Right-click in 2D view > script > struct
  • give the script_struct a targetname of lantern_glowFX_origin
  • Place the script_struct in the exact position you want the glow to appear.


Some Sources from: Treyarch's Wiki