UGX-Mods 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

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - nabaro

Great map, but there were major frame drops at times. Idk why, but it would go from a constant 30-35 fps for 5 minutes to a 10-15 for 5 minutes for no reason whatsoever.
10 years ago
Thanks so much for all your help!
10 years ago
Is there a similar variable for players dead, not downed?
10 years ago
Thanks, I was thinking about using an array for the random locations. As I'm thinking about the logic, I realized I made a mistake: level.all_players_in_secret_area should be equal to the number of players alive, not the number of players in general. How do I do that?
10 years ago
Thanks, I'll modify it in the OP.
10 years ago
Don't have access to my mod tools right now, but can you guys see anything wrong with this script I just typed up which teleports zombies to a secret area if all the players are in it? Thanks in advance!

Code Snippet
Plaintext
#include common_scripts\utility; 
#include maps\_utility;
#include maps\_zombiemode_utility;
#include maps\_anim;

main()
{
flag_wait("all_players_connected");
players = get_players();
level.in_secret_area = 0;
level.all_players_in_secret_area = players.size;
for(i = 0; i < players.size; i++)
{
players[i] thread check_secret_area();
}
thread zombie_teleport();
}

check_secret_area()
{
secret_area = getEnt("secret_area", "targetname");
self.in_secret_area = 0;
while(1)
{
if(self isTouching(secret_area))
{
if(self.in_secret_area = 0)
{
level.in_secret_area = level.in_secret_area + 1;
wait(0.05);
}
else
{
wait(0.05);
}
self.in_secret_area = 1;
}
else
{
if(self.in_secret_area = 1)
{
level.in_secret_area = level.in_secret_area - 1;
self.in_secret_area = 0;
wait(0.05);
}
else
{
wait(0.05);
}
}
}
}

zombie_teleport()
{
tele_spot_1 = getEnt("tele_spot_1", "targetname");
tele_spot_2 = getEnt("tele_spot_2", "targetname");
tele_spot_3 = getEnt("tele_spot_3", "targetname");
tele_spot_4 = getEnt("tele_spot_4", "targetname");
tele_location = undefined;
while(1)
{
if(level.in_secret_area == level.all_players_in_secret_area)
{
zombies = getaispeciesarray("axis");
for(j = 0; j < zombies.size; j++)
{
if(level.in_secret_area == level.all_players_in_secret_area)
{
rand = randomintrange(1, 5);
if(rand == 1)
{
tele_location = tele_spot_1;
wait(0.05);
}
else if(rand == 2)
{
tele_location = tele_spot_2;
wait(0.05);
}
else if(rand == 3)
{
tele_location = tele_spot_3;
wait(0.05);
}
else if(rand == 4)
{
tele_location = tele_spot_4;
wait(0.05);
}
zombies[j] forceteleport(tele_location.origin, tele_location.angles);
playfx(level._effect["powerup_on"], tele_location.origin);
wait(1);
}
else
{
wait(0.05);
break;
}
}
}
else
{
wait(0.05);
}
}
}
      
   
EDIT: Added waits in the while loops. If I missed any, please let me know.
EDIT2: For clarification, the area is attached to the playable area until all players are on it.
10 years ago
Use this to port players from another CoD: https://www.youtube.com/watch?v=9KxFd4pqJoY
If you really want your own, unique players and are capable of making them, then you need to apply the CoD character rig to your character in Maya and then export it as shown in the video.
10 years ago
Oh. My bad, then.
10 years ago
I believe that you need to use different flags for entering the same zone from 2 different ways. For example:   
Code Snippet
Plaintext
add_adjacent_zone( "2a_zone", "3_zone", "enter_3_zone" );
add_adjacent_zone( "2b_zone", "3_zone", "enter_3_zone" );
should be:
Code Snippet
Plaintext
add_adjacent_zone( "2a_zone", "3_zone", "enter_3_zone_from_2a" );
add_adjacent_zone( "2b_zone", "3_zone", "enter_3_zone_from_2b" );
and etcetera.

Post Merge: April 29, 2014, 08:23:58 pm
Basically no two flags can be the same.
10 years ago
So basically I would use this function in a .csc file rather than a .gsc?
10 years ago
I think you should move the ui and font files. If your other map is stock, then perhaps you should wait till you have completed that to start the new one with UGX mod. (Actually, you have to install the font, not move it to root).
10 years ago
It is in zone_source/english/assetinfo/mapname.csv. Is that okay or should it be included elsewhere?
10 years ago
Unfortunately, this doesn't work and neither does
Code Snippet
Plaintext
PlayFx(level._effect["cherry_burst"], self.origin);
leading me to believe that there is a problem with the fx. Here is the full script now.
Code Snippet
Plaintext
#include maps\_anim; 
#include maps\_utility;
#include common_scripts\utility;
#include maps\_music;
#include maps\_zombiemode_utility;

main()
{
level._effect["cherry_burst"] = loadfx("env/electrical/fx_player_md");
flag_wait("all_players_connected");
wait(1);
players = get_players();
for(i = 0; i < players.size; i++)
{
players[i] thread cherry_effect();
players[i] thread cherry_down();
}
}

cherry_effect()

while(1)
{
self waittill( "reload_start" );
if( self HasPerk("specialty_boost"))
{
cherry_weapon = self GetCurrentWeapon();
ammo_left = self GetWeaponAmmoClip( cherry_weapon );
clip_size = WeaponClipSize( cherry_weapon );
ratio = ammo_left / clip_size;
damage = 1200 - (ratio * 1200);
iprintln( damage );
PlayFx(level._effect["cherry_burst"], self.origin);
touching_check = spawn("trigger_radius",self.origin,1,200,200);
zombies = getaispeciesarray("axis","all");
for(j = 0; j < zombies.size; j++)
{
if(zombies[j] IsTouching( touching_check ))
{
zombies[j] maps\_zombiemode_tesla::tesla_play_death_fx( 1 );
zombies[j] SetFlashBanged( true, 1 );
}
else
{
continue;
}
}
touching_check delete();
SetPlayerIgnoreRadiusDamage( true );
RadiusDamage( self.origin, 200, damage, 50, self );
wait(5);
}
else
{
}
}
}

cherry_down()
{
while(1)
{
if(self HasPerk("specialty_boost"))
{
self waittill_any( "fake_death", "death", "player_downed" );
touching_check = spawn("trigger_radius",self.origin,1,200,200);
zombies = getaispeciesarray("axis","all");
for(j = 0; j < zombies.size; j++)
{
if(zombies[j] IsTouching( touching_check ))
{
zombies[j] maps\_zombiemode_tesla::tesla_play_death_fx( 1 );
zombies[j] SetFlashBanged( true, 1 );
}
else
{
continue;
}
}
touching_check delete();
SetPlayerIgnoreRadiusDamage( true );
RadiusDamage( self.origin, 150, 1200, 50, self );
self UnSetPerk("specialty_boost");
}
else
{
wait(0.05);
continue;
}
}
}
10 years ago
So I would replace:
Code Snippet
Plaintext
 PlayFxOnTag(level._effect[ "cherry_burst" ], cherry_weapon, "tag_clip"); 
with
Code Snippet
Plaintext
 PlayFxOnTag(level._effect[ "cherry_burst" ], self, "tag_weapon_right");
?
10 years ago
Oh, in that case, what is the tag for a player's hand?
10 years ago
Loading ...