

![]() |
| Please help us to raise in the ranks of podcasting and subscribe to our itunes feed using the link above. |
|
This will come in handy for SP mappers, nice little hack IW developers use... not so much a tutorial here but just explaining the theory, you can do the research on your own on how it's done. Thanks to Sparks. for this tutorial.
Rather than having to start your map over and over to test scripts, you can create start positions (similar to how Jason showcased at the E3 conference with All Ghuilled Up, but that was all scripted up for that demo).
Using Bog A for example... the developers have created "start" points, which is a dvar. You want to add the starts before _load because _load handles starts, ie Code: add_start( "melee", maps\bog_a_code::start_melee, &"STARTS_MELEE" ); maps\_load::main(); In Bog_A_Code, there are functions such as start_melee, start_breach, etc... These functions basically delete AI, teleport main characters + player, spawn new AI, flag flags and set up level. ie Code: start_melee() { ai = getaiarray( "axis" ); array_thread( ai, ::delete_me ); thread melee_sequence(); level.player setplayerangles( ( 0, 240, 0) ); level.player setorigin( ( 10181.9, 708.265, 100.567 ) ); } So you want to add to your SP dev shortcut, +set developer 1 +set developer_script 1 +start "melee" +devmap mapname (or you could launch the map from the main menu in-game) Launch the map, and you'll be taken to that part of the map/script of the level. :) Nice little hack so that when developing the level, you can quickly go to the areas and play from there, rather than starting from the beginning every time. For Bog A, these are the start points: Quote: melee breach alley shanty bog zpu cobras end And as a note, you can set the start point in console real-time, but have to do a map_restart. There's no reload of the map, it's an instantaneous teleport and refresh of the map. Hopefully someone finds this handy besides me. ;D Even if you don't plan on SP mapping, go try this dvar out on the Bog mission, pretty cool beans. |
Members Online
Latest MODSonline Poll
MODSonline Teamspeak
Partners of MODSonline
Friends of MODSonline
|