All right? I'm doing a script here where I need to know when a player opens a door and activates a zone, but I can not at all... tried using the following modes, but it did not work... Any tips? Thank you!
I have made a simple script to check in which zone the player is, you can check which zone you want.
from the function out of the _zombiemode_zone_manager file it says also that the function will check if the zone is activated or not.
first open the script: nazi_zombie_yourmapname.gsc
and scroll down untill you will see this:
Code Snippet
Plaintext
/*-------------------- FUNCTION CALLS - POST _Load ----------------------*/ level.zone_manager_init_func = ::dlc3_zone_init; level thread DLC3_threadCalls2();
add this under it:
Code Snippet
Plaintext
level thread check_players_in_zone();
it will look like this:
Code Snippet
Plaintext
/*-------------------- FUNCTION CALLS - POST _Load ----------------------*/ level.zone_manager_init_func = ::dlc3_zone_init; level thread DLC3_threadCalls2(); level thread check_players_in_zone();
now the last step:
add this:
Code Snippet
Plaintext
check_players_in_zone() { wait 6;
zone_to_check = "start_zone"; // put here the name of the Zone that you want to check
while(1) { if(player_in_zone(zone_to_check)) { iprintln("yes an player is in the zone: " + zone_to_check); } else { iprintln("no one is in that zone or the zone is not activated"); }
wait 1; } }
to the bottom of the script.
and you can edit this line to check which zone you want to check:
Code Snippet
Plaintext
zone_to_check = "start_zone"; // put here the name of the Zone that you want to check
I have made a simple script to check in which zone the player is, you can check which zone you want.
from the function out of the _zombiemode_zone_manager file it says also that the function will check if the zone is activated or not.
first open the script: nazi_zombie_yourmapname.gsc
and scroll down untill you will see this:
Code Snippet
Plaintext
/*-------------------- FUNCTION CALLS - POST _Load ----------------------*/ level.zone_manager_init_func = ::dlc3_zone_init; level thread DLC3_threadCalls2();
add this under it:
Code Snippet
Plaintext
level thread check_players_in_zone();
it will look like this:
Code Snippet
Plaintext
/*-------------------- FUNCTION CALLS - POST _Load ----------------------*/ level.zone_manager_init_func = ::dlc3_zone_init; level thread DLC3_threadCalls2(); level thread check_players_in_zone();
now the last step:
add this:
Code Snippet
Plaintext
check_players_in_zone() { wait 6;
zone_to_check = "start_zone"; // put here the name of the Zone that you want to check
while(1) { if(player_in_zone(zone_to_check)) { iprintln("yes an player is in the zone: " + zone_to_check); } else { iprintln("no one is in that zone or the zone is not activated"); }
wait 1; } }
to the bottom of the script.
and you can edit this line to check which zone you want to check:
Code Snippet
Plaintext
zone_to_check = "start_zone"; // put here the name of the Zone that you want to check