Recent Posts

broken avatar :(
×
broken avatar :(
User
Date Registered: N/A
Last active: N/A
Posts
N/A
Respect
0
Primary Group
Member
×
ERAWEX's Groups
ERAWEX's Contact & Social Links
Last post by ERAWEX - 3 hours ago
Hi there,

I have implemented two boss zombies into my map and they both work fine for a certain amout of time. Past round 30/31/32/33 none of them will spawn anymore and I have tried to figure out why but can't find an answer. It seems to not be directly related to the rounds but to the time that has past ingame to get there. Would anyone know whats causing this?

This is one of the scripts that im using for the boss zombie.

#include maps\_utility; 
#include common_scripts\utility;
#include maps\_zombiemode_utility;
#include animscripts\Utility;

#using_animtree( "generic_human" );

init()
{
    //level.scr_anim["napalm"]["walk"] = %Ai_walk_weary_a;            //Animacion parecida al napalm ( cambiar si les gusta mejor )
    level.scr_anim["napalm"]["walk"] = %ai_zombie_napalm_run;        //Animacion oficial napalm ( cambiar si les gusta mejor )
    level.scr_anim["napalm"]["explode"] = %ai_zombie_napalm_attack_01;

    level._zombie_napalm_fire_death["zombie"] = [];
    level._zombie_napalm_fire_death["zombie"][0]             = %ai_flame_death_a;
    level._zombie_napalm_fire_death["zombie"][1]            = %ai_flame_death_b;
    level._zombie_napalm_fire_death["zombie"][2]             = %ai_flame_death_c;
    level._zombie_napalm_fire_death["zombie"][3]             = %ai_flame_death_d;
    level._zombie_napalm_fire_death["zombie"][4]             = %ai_flame_death_e;
    level._zombie_napalm_fire_death["zombie"][5]             = %ai_flame_death_f;
    level._zombie_napalm_fire_death["zombie"][6]             = %ai_flame_death_g;
    level._zombie_napalm_fire_death["zombie"][7]             = %ai_flame_death_h;

    level._effect[ "napalm_spawn" ] = LoadFX( "napalm/napalm_boss_spawn" );
    level._effect[ "napalm_fire_trap" ] = LoadFX( "napalm/napalm_fire_trap" );
    level._effect[ "napalm_explo" ] = LoadFX( "explosions/default_explosion" );
    level._effect[ "napalm_fire_foot" ] = LoadFX( "napalm/napalm_foot" );
   
    set_zombie_var( "napalm_first_round",            4 );         //Ronda a iniciar + RandomIntRange( level.zombie_vars["napalm_rnd_min"], level.zombie_vars["napalm_rnd_max"] )
    set_zombie_var( "napalm_rnd_max",            3 );        //Numero maximo de ronda entre el proximo spawn
    set_zombie_var( "napalm_rnd_min",            2 );        //Numero menor de rondas entre el proximo spawn
    set_zombie_var( "napalm_health_multiplier",        8 );        //Incremento de vida
    set_zombie_var( "napalm_alive",                false );    //Napal vivo/muerto
    set_zombie_var( "napalm_explo_radius_plr",        80 );        //Napalm explotara cuando esta cercano al jugador ( a 80 de distancia )
    set_zombie_var( "napalm_vision_radius",            250 );        //Rango de Vision
    set_zombie_var( "napalm_trap_damage",            60 );        //DaƱo trampa a jugador / con PHP no afecta
    set_zombie_var( "napalm_trap_radius",            90 );        //Rango de la trampa (esta a corde con el tiempo del fx)
    set_zombie_var( "trap_time",                15 );        //Tiempo de la trampa (esta a corde con el tiempo del fx)

    precache_models();
    thread maps\_zombiemode_ai_napalm::main();
}

precache_models()
{
    precachemodel( "bo1_c_viet_zombie_napalm" );
    precachemodel( "bo1_c_viet_zombie_napalm_head" );
}

main()
{
    flag_wait("all_players_connected");
   
    level thread wait_for_spawn();
    level thread spawn_napalm();
}

wait_for_spawn()
{
    level.zombie_vars["napalm_first_round"] = level.zombie_vars["napalm_first_round"] + RandomIntRange( level.zombie_vars["napalm_rnd_min"], level.zombie_vars["napalm_rnd_max"] );
//    level.zombie_vars["napalm_first_round"] = level.zombie_vars["napalm_first_round"] + 1;

//    iprintlnbold("Ronda Spawn ---> " + level.zombie_vars["napalm_first_round"] );
    while( 1 )
    {
        if( flag("dog_round" ) )
        {
            wait(7);
            while( level.dog_intermission )
            {
                wait(0.5);
            }
            level.zombie_vars["napalm_first_round"] = level.zombie_vars["napalm_first_round"] + 1;
//            iprintlnbold("Proxima Ronda Spawn ---> " + level.zombie_vars["napalm_first_round"] );
        }
        else
        {
            if( level.round_number >= level.zombie_vars["napalm_first_round"] )
                level.napalm_active_on = true;
            else
                level.napalm_active_on = undefined;
        }
       
        wait(0.5);
    }
}

spawn_napalm()
{
    napalm_points = GetEntArray( "napalm_spawn", "targetname" );
    chosen_spot = undefined;

    if( !IsDefined( napalm_points ) || napalm_points.size == 0 )
        return;

    while( 1 )
    {
        if( isDefined( level.napalm_active_on ) && level.napalm_active_on == true )
        {
            if( !level.zombie_vars["napalm_alive"] )
            {   
                wait RandomIntRange(10, 15); //Tiempo de espera en hacer respawn
               
                napalm_points = array_randomize( napalm_points );

                for( i = 0; i < napalm_points.size; i++ )
                {
                    _napalm = spawn( "script_model", napalm_points[i].origin );
                    _napalm SetModel( "tag_origin" );
                    _napalm linkTo( napalm_points[i] );
                    _napalm.angles = napalm_points[i].angles;
                    _napalm.origin = napalm_points[i].origin;
   
                    if( zone_active( _napalm ) )
                    {
                        chosen_spot = napalm_points[i];
                        break;
                    }
                    wait 0.01;
                    _napalm delete();
                }
                level.zombie_vars["napalm_first_round"] = level.zombie_vars["napalm_first_round"] + RandomIntRange( level.zombie_vars["napalm_rnd_min"], level.zombie_vars["napalm_rnd_max"] );

//                level.zombie_vars["napalm_first_round"] = level.zombie_vars["napalm_first_round"] + 1;
//                iprintlnbold("Proxima Ronda Spawn ---> " + level.zombie_vars["napalm_first_round"] );

                level.zombie_vars["napalm_alive"] = true;
                napalm = spawn_zombie( chosen_spot );
                napalm thread maps\_zombiemode::round_spawn_failsafe();
                napalm thread napalm_prespawn();
            }
        }
        wait(0.5);
    }
}

zone_active( np )
{
    napalm = Getentarray( "start_zone", "script_noteworthy" ); //Reemplazar por el script_noteworthy de tu info_volume
    zone = undefined;
    poi = false;

    for( i=0; i < napalm.size; i++ )
    {
        if( np istouching( napalm[i]) )
        {
            zone = napalm[i].targetname;
            if( level.zones[ napalm[i].targetname ].is_enabled )
            {
                poi = true;
            }
        }
    }
    return poi;
}

napalm_prespawn()
{
    thread players_disableflamescreen();

    self.animname = "zombie";
   
    self maps\_zombiemode_spawner::zombie_spawn_init( true );
    self thread maps\_zombiemode_spawner::zombie_think();
       self maps\_zombiemode_spawner::zombie_setup_attack_properties();
       self thread maps\_zombiemode_spawner::find_flesh();

    self.gib_override = false;
     self.gibbed = true;
    self.no_damage_points = true;
    self.ignore_enemy_count = true;
    self.is_napalm = true;
    self.shrinkray_napalm = true;

    self.maxhealth = 100000;   
    self.health = 100000;
//    iprintlnbold("Napalm Vida ---> " + self.health );

    /*==== Spawn ====*/
    level thread napalm_area_effect( self.origin, "napalm_spawn" );
    //level thread napalm_plr_sound( "spawn" );

    self playsound("ignite");
    self playsound( "evt_napalm_zombie_spawn" );

    speed = "run";
    spawn_anim = random(level._zombie_rise_anims["zombie"][1][speed]);
    time = getanimlength(spawn_anim);
    self animscripted("napalm_spawn", self.origin + (0, 0, -45), self.angles, spawn_anim, "normal");
    wait( time );
    self thread napalm_health();
    /*==== End Spawn ====*/

    self thread maps\_zombiemode_spawner::zombie_eye_glow_stop();
   
    self thread napalm_walk();   
    self thread napalm_trail();
    self thread napalm_vision();
    self thread napalm_vox();
    self thread napalm_player();
    self thread napalm_death();
}

napalm_health()
{
    players = get_players();
     self.maxhealth = level.zombie_health * (players.size * level.zombie_vars["napalm_health_multiplier"] );
     self.health = level.zombie_health * (players.size * level.zombie_vars["napalm_health_multiplier"] );

//    iprintlnbold("Napalm Vida ---> " + self.health );
}

napalm_walk()
{
    self endon( "death" );

    while( isDefined( self ) )
    {
        walk = true;
        zombies = getaiarray( "axis" );
        while( zombies.size > 0 )
        {
            if( zombies.size == 1 || self.health < ( self.maxhealth / 4 ))
            {
                var = randomintrange(1, 4);
                self set_run_anim( "sprint" + var );                       
                self.run_combatanim = level.scr_anim[self.animname]["sprint" + var];
                walk = false;
            }
            wait(0.05);
            zombies = getaiarray("axis");
            if( isDefined( walk ) )   
            {
                self set_run_anim( "walk" + 2);                       
                self.run_combatanim = level.scr_anim["napalm"]["walk"];
            }
        }

        wait_network_frame();
    }   
}

napalm_player()
{
    self endon( "death" );
   
    while(1)
    {
        players = getplayers();
       
        for(i=0;i<players.size;i++)
        {
            if( self.shrinkray_napalm == true && Distance( self.origin, players[i].origin ) <= level.zombie_vars["napalm_explo_radius_plr"])
                {
                self playsound( "evt_napalm_zombie_charge" );

                //explode_wind_up = %ai_zombie_taunts_5f;
                explode_wind_up = level.scr_anim["napalm"]["explode"];
                time = getanimlength(explode_wind_up);
                self animscripted("napalm_explode", self.origin, self.angles, explode_wind_up, "normal");
                wait time/2.0;
                           
                self DoDamage( self.health + 666, self.origin, self );
               
                return;
                }
            wait .5;
        }
        wait_network_frame();
    }
}

napalm_vox()
{
    self endon( "death" );
   
    wait( 4 );
   
    napalm_wait = 4;
   
    while(1)
    {
        players = getplayers();
       
        for(i=0;i<players.size;i++)
        {
            if(DistanceSquared(self.origin, players[i].origin) > 1200 * 1200)
            {
                sound_amb = "zmb_napalm_ambient0" + randomint(2);
                self playsound( sound_amb );   
                napalm_wait = 7;       
            }
            else if(DistanceSquared(self.origin, players[i].origin) > 200 * 200)
            {
                sound_attack = "zmb_napalm_attack0" + randomint(2);
                self playsound( sound_attack );   
                napalm_wait = 5;   
            }
            else if(DistanceSquared(self.origin, players[i].origin) < 150 * 150)
                wait(.05);
        }
        wait randomfloatrange( 1, napalm_wait );       
    }
}

napalm_trail()
{
    self endon( "death" );

    self thread trail1();
    //self thread trail2();
}

trail1()
{
    while( isDefined( self ) )
    {
        PlayFxOnTag( level._effect["character_fire_death_torso"], self, "J_SpineLower" );
        wait 4;
    }
}

trail2()
{
    while( isDefined( self ) )
    {
        PlayFxOnTag( level._effect[ "napalm_fire_foot" ], self, "tag_origin" );
              wait .5;
    }
}

napalm_vision()
{
        while( isDefined( self ) )
       {
        players = get_players();
           
        for(i = 0; i < players.size; i++)
        {
            if ( !isdefined( self ) )
                break;

            if( distance(players[i] getOrigin(), self getOrigin()) <= level.zombie_vars["napalm_vision_radius"] && !players[i] maps\_laststand::player_is_in_laststand() )
            {
                players[i] setBurn( 0.5 );
                wait .05;
            }
            else
                players[i] setBurn( 0 );
                //players[i] setClientDvar("r_flamefx_enable", 0);
            wait .05;
        }
   
        wait_network_frame();
    }
    thread players_disableflamescreen();
}

napalm_death_explo()
{
    playsoundatposition( "zmb_napalm_explode", self.origin );
    PlayFx(level._effect["napalm_explo"], self getTagOrigin("J_MainRoot"));

    players = get_players();
    dist = level.zombie_vars["napalm_explo_radius_plr"];

    for(i = 0; i < players.size; i++)
    {
        players[i] setClientDvar("r_flamefx_enable", 0);

        if( Distance( self.origin, players[i].origin ) <= ( dist + 20 ))
            self thread napalm_damage(dist + 20, (240 + randomint(15)), players[i], 3.5);
           
        if( Distance( self.origin, players[i].origin ) > dist && Distance( self.origin, players[i].origin ) <= (dist + 70) )
            self thread napalm_damage(dist + 70, 120, players[i], 2.5);
           
        if( Distance( self.origin, players[i].origin ) > dist && Distance( self.origin, players[i].origin ) <= (dist + 120))
            self thread napalm_damage(dist + 120, 70, players[i], 1.5);

        if( Distance( self.origin, players[i].origin ) > dist && Distance( self.origin, players[i].origin ) <= (dist + 170))
            self thread napalm_damage(dist + 170, 30, players[i], .5);

        wait .2;
    }
}

napalm_damage(rango, da, player, t)
{
    if( !self HasPerk("specialty_detectexplosive") )
    {
        self RadiusDamage( self.origin, rango, da, da, self, "MOD_EXPLOSIVE" );
        player ShellShock( "explosion", t );
    }
}

napalm_area_effect( origin, fx )
{
    effectArea = spawn( "trigger_radius", origin, 0, level.zombie_vars["napalm_trap_radius"], 100 );

    PlayFX( level._effect[ fx ], origin );
       
    trap_time = 0;
   
    while( trap_time <= level.zombie_vars["trap_time"] )
    {
        players = get_players();
        zombies = GetAIArray( "axis" );
           
        for(i = 0; i < players.size; i++)
        {
            if( players[i] IsTouching( effectArea ) && !players[i] HasPerk("specialty_detectexplosive") && !players[i] maps\_laststand::player_is_in_laststand() )
                players[i] DoDamage( level.zombie_vars["napalm_trap_damage"], players[i].origin );
        }

        for(j = 0; j < zombies.size; j++)
        {   
            if( !zombies[j] IsTouching( effectArea ) )
                continue;

            if( (Isdefined(zombies[j].is_napalm) && zombies[j].is_napalm == true) || Isdefined(zombies[j].animname) && (zombies[j].animname == "engineer_zombie" || zombies[j].animname == "ape_zombie" ) )
                continue;

            if ( is_magic_bullet_shield_enabled( zombies[j] ) )
                continue;

            if( zombies[j].animname == "zombie" && !zombies[j].zmb_fire_anim && zombies[j].has_legs == true )
            {
                zombies[j].zmb_fire_anim = true;

                zombies[j].deathanim = random( level._zombie_napalm_fire_death[zombies[j].animname] );
                zombies[j] thread animscripts\death::flame_death_fx();
                wait 0.2;
                zombies[j] DoDamage( zombies[j].health + 666, zombies[j].origin );
            }
            else
            {
                zombies[j] thread animscripts\death::flame_death_fx();

                wait (randomfloatrange(0.1, 2.5));
                zombies[j] DoDamage( zombies[j].health + 666, zombies[j].origin );
            }
        }
           
        wait(1);
        trap_time = trap_time + 1;
    }
       
    effectArea Delete();
}

napalm_death()
{
    self waittill( "death" );

    if( isdefined(self.shrinkray_napalm) && self.shrinkray_napalm == true )
    {
        self thread napalm_death_explo();
        level thread napalm_area_effect( self.origin, "napalm_fire_trap" );

        //level thread napalm_plr_sound("kill");

        self delete();
    }

    level.zombie_vars["napalm_alive"] = false;
                 
    level waittill("between_round_over");
    level.zombie_vars["napalm_alive"] = false;
}

napalm_plr_sound( type )
{
    players = get_players();
   
    for(i = 0; i < players.size; i++)
        players[i] thread napalm_plr_sound_opc( type );
}

napalm_plr_sound_opc(opc)
{
    self endon( "disconnect" );

    index = maps\_zombiemode_weapons::get_player_index( self );
    plr = "plr_" + index + "_";
    if(opc == "spawn")
        self thread play_napalm_dialog_spawn(plr);   
    else
        self thread play_napalm_dialog_kill(plr);
    wait(3.5);
    //self thread play_tesla_sound("tesla_happy"); (moved to client)
    level clientNotify ("TGH");
}

play_napalm_dialog_spawn(player_index)
{
    waittime = 0.25;
    if(!IsDefined (self.vox_spawn_napalm))
    {
        num_variants = maps\_zombiemode_spawner::get_number_variants(player_index + "vox_spawn_napalm");
        //iprintlnbold(num_variants);
        self.vox_spawn_napalm = [];
        for(i=0;i<num_variants;i++)
        {
            self.vox_spawn_napalm[self.vox_spawn_napalm.size] = "vox_spawn_napalm_" + i;
            //iprintlnbold("vox_spawn_napalm_" + i);   
        }
        self.vox_spawn_napalm_available = self.vox_spawn_napalm;
    }

    if(!isdefined (level.player_is_speaking))
    {
        level.player_is_speaking = 0;
    }

    sound_to_play = random(self.vox_spawn_napalm_available);
    //iprintlnbold("LINE:" + player_index + sound_to_play);
    self maps\_zombiemode_spawner::do_player_playdialog(player_index, sound_to_play, waittime);
    self.vox_spawn_napalm_available = array_remove(self.vox_spawn_napalm_available,sound_to_play);
   
    if (self.vox_spawn_napalm_available.size < 1 )
    {
        self.vox_spawn_napalm_available = self.vox_spawn_napalm;
    }
}

play_napalm_dialog_kill(player_index)
{
    waittime = 0.25;
    if(!IsDefined (self.vox_kill_napalm))
    {
        num_variants = maps\_zombiemode_spawner::get_number_variants(player_index + "vox_kill_napalm");
        //iprintlnbold(num_variants);
        self.vox_kill_napalm = [];
        for(i=0;i<num_variants;i++)
        {
            self.vox_kill_napalm[self.vox_kill_napalm.size] = "vox_kill_napalm_" + i;
            //iprintlnbold("vox_kill_napalm_" + i);   
        }
        self.vox_kill_napalm_available = self.vox_kill_napalm;
    }

    if(!isdefined (level.player_is_speaking))
    {
        level.player_is_speaking = 0;
    }

    sound_to_play = random(self.vox_kill_napalm_available);
    //iprintlnbold("LINE:" + player_index + sound_to_play);
    self maps\_zombiemode_spawner::do_player_playdialog(player_index, sound_to_play, waittime);
    self.vox_kill_napalm_available = array_remove(self.vox_kill_napalm_available,sound_to_play);
   
    if (self.vox_kill_napalm_available.size < 1 )
    {
        self.vox_kill_napalm_available = self.vox_kill_napalm;
    }
}

players_disableflamescreen()
{
    wait 1.1;
    players = getPlayers();
    for(i=0;i<players.size;i++)
        players[i] setClientDvar("r_flamefx_enable", 0);
}
Any help on this issue would be greatly appreciated!
ERAWEX
 
broken avatar :(
×
broken avatar :(
User
Date Registered: N/A
Last active: N/A
Posts
N/A
Respect
0
Primary Group
Member
×
IceGrenade's Groups
IceGrenade's Contact & Social Links
Last post by IceGrenade - 12 hours ago
Browsing for a good map to play and stumbled across your map! OMFG how have I not seen this before! This looks incredible! Looks like you really went all in here bud. Will be streaming this tonight if you are interested to see. I know as a map maker I love to watch people playing my own maps so maybe you want to see. Anyhow, it will be at 5pm GMT aka 3.2hrs time https://www.youtube.com/c/IceGrenade/live :)
broken avatar :(
×
broken avatar :(
User
Date Registered: N/A
Last active: N/A
Posts
N/A
Respect
0
Primary Group
Member
×
klevi's Groups
klevi's Contact & Social Links
Last post by klevi - 14 hours ago
What is? 
broken avatar :(
×
broken avatar :(
User
Date Registered: N/A
Last active: N/A
Posts
N/A
Respect
0
Primary Group
Member
×
AveSatanna's Groups
AveSatanna's Contact & Social Links
Last post by AveSatanna - 1 day ago

- Lots and Lots of staffs :)
 
broken avatar :(
×
broken avatar :(
User
Date Registered: N/A
Last active: N/A
Posts
N/A
Respect
0
Primary Group
Member
×
ERAWEX's Groups
ERAWEX's Contact & Social Links
Last post by ERAWEX - 1 day ago
I don't know if you readed the ugx installer optional options but if you add the bik video at the root of your mod it would be automaticly installed into your friends main video folder.
I was finaly able to try this (sorry that too this long) but it sadly did not work, my friend still only sees the activision loading screen.

So what I did was place the mapname_load.bik into the root/mods/mapname folder and created a new installer with UGX Installer 1.1 and nothing really happen on my friends end. Is there something they need to do manually? or am I just setting this up wrong?




Double Post Merge: May 27, 2020, 03:37:01 pm
I don't know if you readed the ugx installer optional options but if you add the bik video at the root of your mod it would be automaticly installed into your friends main video folder.
 I have now also tried to include the .bik file in "appdata/local/activision/codwaw/mods/mapname" and that also didn't work. Would there be any other way?
broken avatar :(
×
broken avatar :(
User
Date Registered: N/A
Last active: N/A
Posts
N/A
Respect
0
Primary Group
Member
×
RadimaX's Groups
RadimaX's Contact & Social Links
Last post by RadimaX - 1 day ago
Is it possible to state that your map requires  T4M   in the thread title? Since it is not very obvious all the way down there...



broken avatar :(
×
broken avatar :(
User
Date Registered: N/A
Last active: N/A
Posts
N/A
Respect
0
Primary Group
Member
×
gympie6's Groups
gympie6's Contact & Social Links
Last post by gympie6 - 2 days ago
No problem. :)
broken avatar :(
×
broken avatar :(
User
Date Registered: N/A
Last active: N/A
Posts
N/A
Respect
0
Primary Group
Member
×
ERAWEX's Groups
ERAWEX's Contact & Social Links
Last post by ERAWEX - 2 days ago

oh sorry I will keep it simple:

radios()
{
    // For entities
    radiolist = getEntArray("radio_location", "targetname");
   
    // For structs, uncomment it if you use structs
    // radiolist = GetStructArray("radio_location", "targetname");
   
    for(i = 0; i < radiolist.size; i++)
    {
        radiolist[i] thread play_radio();
    }
}

play_radio(radio)
{
    while(1)
    {
        radio playsound("YOUR-SONG-NAME");
   
        // set here the time that you would like to wait.
        wait randomIntRange(150,300);
    }
   
    // you can also do this instead of using the whileloop
    // radio  playLoopSound ("YOUR-SONG-NAME");
}
You can add both of this at the bottom of your MAPNAME.gsc file
Then scroll up until you see this:
    /*--------------------
     ZOMBIE MODE
    ----------------------*/
    [[level.DLC3.weapons]]();
    [[level.DLC3.powerUps]]();   
    thread maps\dw_fx::init();   
   
    maps\_zombiemode::main();
under that add:
level thread radios();
Yes add entities or structs on the map and use the targetname: radio_location
 So it looks like this:
    /*--------------------
     ZOMBIE MODE
    ----------------------*/
    [[level.DLC3.weapons]]();
    [[level.DLC3.powerUps]]();   
    thread maps\dw_fx::init();   
   
    maps\_zombiemode::main();
   
    level thread radios();
 Oh wow! Thanks for the help man it is very appreciated!
broken avatar :(
×
broken avatar :(
User
Date Registered: N/A
Last active: N/A
Posts
N/A
Respect
0
Primary Group
Member
×
gympie6's Groups
gympie6's Contact & Social Links
Last post by gympie6 - 2 days ago
oh sorry I will keep it simple:

radios()
{
    // For entities
    radiolist = getEntArray("radio_location", "targetname");
   
    // For structs, uncomment it if you use structs
    // radiolist = GetStructArray("radio_location", "targetname");
   
    for(i = 0; i < radiolist.size; i++)
    {
        radiolist[i] thread play_radio();
    }
}

play_radio(radio)
{
    while(1)
    {
        radio playsound("YOUR-SONG-NAME");
   
        // set here the time that you would like to wait.
        wait randomIntRange(150,300);
    }
   
    // you can also do this instead of using the whileloop
    // radio  playLoopSound ("YOUR-SONG-NAME");
}
You can add both of this at the bottom of your MAPNAME.gsc file
Then scroll up until you see this:
    /*--------------------
     ZOMBIE MODE
    ----------------------*/
    [[level.DLC3.weapons]]();
    [[level.DLC3.powerUps]]();   
    thread maps\dw_fx::init();   
   
    maps\_zombiemode::main();
under that add:
level thread radios();
Yes add entities or structs on the map and use the targetname: radio_location
 So it looks like this:
    /*--------------------
     ZOMBIE MODE
    ----------------------*/
    [[level.DLC3.weapons]]();
    [[level.DLC3.powerUps]]();   
    thread maps\dw_fx::init();   
   
    maps\_zombiemode::main();
   
    level thread radios();
broken avatar :(
×
broken avatar :(
User
Date Registered: N/A
Last active: N/A
Posts
N/A
Respect
0
Primary Group
Member
×
ERAWEX's Groups
ERAWEX's Contact & Social Links
Last post by ERAWEX - 2 days ago
I am not a pro at this kind of stuff but this is how I made looping sound in Snowblind:

radios()
{
    radiolist = getEntArray("radio_location", "targetname");
    for(i = 0; i < radiolist.size; i++)
    {
        radiolist[i] thread play_radio(radiolist[i]);
    }
}

play_radio(radio)
{
    rememberLastSong = -1;
   
    while(1)
    {
        wait randomIntRange(150,300);
       
        rand = randomInt(6);
        if(rand == rememberLastSong)
        rand = randomInt(6);

        rememberLastSong = rand;       
        radioSong = ("radio_song" + rand);
       
        radio playsound(radioSong);   
        wait 200;
    }
}
 Yeah me neither :) Alright how would I go about to impement this? Would the comments in the script be right?
radios() //ADD THIS UNDER ZOMBIEMODE::MAIN IN mapname.gsc?
{
    radiolist = getEntArray("radio_location", "targetname");
    for(i = 0; i < radiolist.size; i++)
    {
        radiolist[i] thread play_radio(radiolist[i]);
    }
}

play_radio(radio) // and then paste this at the end of the .gsc?
{
    rememberLastSong = -1;
   
    while(1)
    {
        wait randomIntRange(150,300);
       
        rand = randomInt(6);
        if(rand == rememberLastSong)
        rand = randomInt(6);

        rememberLastSong = rand;       
        radioSong = ("radio_song" + rand);
       
        radio playsound(radioSong);   
        wait 200;
    }
}

//and then for the radiant part add a trigger with (targetname, radio_location) and then im done? is //that all?

Login

or login with an authentication provider below
Sign In with Google
Sign In with Twitter
Sign In with Discord
Sign In with Steam
Sign In with Facebook
Sign In with Twitch
Loading ...