Archived copy of war3source.com, the War3Source forum (2009–2020), rebuilt from the Internet Archive by wc3mods.net. This page was captured on 2012-10-24 (original capture). Forum · All archived topics · Wiki · Bug tracker · Blog
Chat

War3:Source
October 24, 2012, 10:16:32 AM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Download: http://war3source.com/index.php?board=9.0
What is War3Source?: http://war3source.com/index.php?topic=200.0
Sample Stats: http://war3source.com/war3stats
Steam Community Group: http://steamcommunity.com/groups/war3source
War3Source SVN Checkout: http://ownageclan.com/svn/war3source/
War3Source servers: http://www.game-monitor.com/search.php?vars=war3_version=
 
   Home   Help Search Login Register  
Pages: [1] 2
  Print  
Author Topic: Admin commands to add levels  (Read 1665 times)
urelind
Newbie
*
Posts: 18


View Profile Email
« on: July 07, 2010, 12:19:01 PM »

Hi Cheesy
I have been looking EVERYWHERE but i cant find any Wc3 commands for CS Source for adding levels Sad

Please tell me what the commands are Cheesy

Also war3admin dosent work in-game when i say it D:
Logged
[Oddity]TeacherCreature
Sr. Member
****
Posts: 463


View Profile
« Reply #1 on: July 07, 2010, 12:20:23 PM »

the command is part of hte admin and you need rcon flag as an admin to use it
Logged

urelind
Newbie
*
Posts: 18


View Profile Email
« Reply #2 on: July 07, 2010, 12:25:16 PM »

I got rcon and all that, but what is the command?
Logged
urelind
Newbie
*
Posts: 18


View Profile Email
« Reply #3 on: July 07, 2010, 12:33:14 PM »

and rcon flags in what? sourcemod? if it is how do i give myself them?
Logged
Ownz
Developer
Administrator
Hero Member
*****
Posts: 2045



View Profile WWW Email
« Reply #4 on: July 07, 2010, 12:47:55 PM »

war3_setlevel
Logged

DarkEnergy
[Oddity]TeacherCreature
Sr. Member
****
Posts: 463


View Profile
« Reply #5 on: July 07, 2010, 01:01:06 PM »

in ur admin cfg where you put flags just put

"flags" "z"

and once you do that u can use set level

or bind a <key> war3admin
Logged

urelind
Newbie
*
Posts: 18


View Profile Email
« Reply #6 on: July 07, 2010, 01:06:20 PM »

Thanks, also why are players levels and such not saving when map changes or they exit the server?
Logged
Ownz
Developer
Administrator
Hero Member
*****
Posts: 2045



View Profile WWW Email
« Reply #7 on: July 07, 2010, 01:12:35 PM »

correct database settings?
Logged

DarkEnergy
urelind
Newbie
*
Posts: 18


View Profile Email
« Reply #8 on: July 07, 2010, 01:13:27 PM »

dunno? tell me what i need to do Tongue havent even touched a database
Logged
Ownz
Developer
Administrator
Hero Member
*****
Posts: 2045



View Profile WWW Email
« Reply #9 on: July 07, 2010, 01:20:17 PM »

sourcemod/config/database.cfg

set driver_default to "sqlite"
Logged

DarkEnergy
urelind
Newbie
*
Posts: 18


View Profile Email
« Reply #10 on: July 07, 2010, 01:42:25 PM »

Also, how do i add custom races?

And would Warcraft: Source races work with this mod?
Logged
Ownz
Developer
Administrator
Hero Member
*****
Posts: 2045



View Profile WWW Email
« Reply #11 on: July 07, 2010, 02:01:04 PM »

put it in your plugins folder

and this is not WCS
Logged

DarkEnergy
urelind
Newbie
*
Posts: 18


View Profile Email
« Reply #12 on: July 07, 2010, 02:17:27 PM »

I know that its not WCS.

So do i have to make a race and then get the file to be a .smx?

Whats if i wanna make my own?

Sorry im noob at these things
Logged
Ownz
Developer
Administrator
Hero Member
*****
Posts: 2045



View Profile WWW Email
« Reply #13 on: July 07, 2010, 02:19:26 PM »

how can you make your own race if you dont know sourcemod or english?
Logged

DarkEnergy
[Oddity]TeacherCreature
Sr. Member
****
Posts: 463


View Profile
« Reply #14 on: July 07, 2010, 07:33:34 PM »

be nice

lol

The answer is yes you need to create aa SP file in a text editor like notepad, using dourcepawn language NOT ES and when your done you compile it with youre sourcemod scripting file.

That will make it a SMX file and then your done put it in your plugin folder and youhave a new race
Logged

Naris
Jr. Member
**
Posts: 60


View Profile Email
« Reply #15 on: July 07, 2010, 08:45:10 PM »

What's dourcepawn?  Grin
Logged
Ownz
Developer
Administrator
Hero Member
*****
Posts: 2045



View Profile WWW Email
« Reply #16 on: July 07, 2010, 09:08:17 PM »

sourcepawn
Logged

DarkEnergy
urelind
Newbie
*
Posts: 18


View Profile Email
« Reply #17 on: July 08, 2010, 05:50:56 AM »

Oddity, thats what i did Smiley

But i cant select my new race in the "changerace" menu

Here is my SM Plugins that shows up in the console.

[SM] Listing 38 plugins:
  01 "War3Source Race - Shadow Hunter" (1.0.0.0) by PimpinJuice & Ownz
  02 "Basic Comm Control" (1.3.3) by AlliedModders LLC
  03 "Admin File Reader" (1.3.3) by AlliedModders LLC
  04 "War3Source_011_KnifeHunter.smx"
  05 "Reserved Slots" (1.3.3) by AlliedModders LLC
  06 "War3Source Race - Blood Mage" (1.0.0.0) by PimpinJuice & Ownz
  07 "Client Preferences" (1.3.3) by AlliedModders LLC
  08 "War3Source - Shopitems" (1.0.0.0) by PimpinJuice
  09 "Basic Ban Commands" (1.3.3) by AlliedModders LLC
  10 "Server Crontab Module" (1.0.1.0) by dubbeh
  11 "War3Source Race - Undead Scourge" (1.0.0.0) by PimpinJuice
  12 "War3Source Race - Night Elf" (1.0.0.0) by PimpinJuice
  13 "Player Commands" (1.3.3) by AlliedModders LLC
  14 "Sound Commands" (1.3.3) by AlliedModders LLC
  15 "Nextmap" (1.3.3) by AlliedModders LLC
  16 <Failed> "WC(WoW)" (1.14) by Stinkyfax
  17 "War3Source Race - Warden" (1.0.0.0) by PimpinJuice & Ownz
  18 "Fun Votes" (1.3.3) by AlliedModders LLC
  19 "Anti-Flood" (1.3.3) by AlliedModders LLC
  20 "Server Crontab" (1.0.1.0) by dubbeh
  21 "Basic Commands" (1.3.3) by AlliedModders LLC
  22 "War3Source Race - Soul Reaper" (1.0) by Ownz
  23 "Admin Menu" (1.3.3) by AlliedModders LLC
  24 "Admin Help" (1.3.3) by AlliedModders LLC
  25 "CS:S DM Preset Spawns" (2.1.0.446) by AlliedModders LLC
  26 "CS:S DM Spawn Protection" (2.1.0.446) by AlliedModders LLC
  27 "CS:S DM Basics" (2.1.0.446) by AlliedModders LLC
  28 "CS:S DM Equipment" (2.1.0.446) by AlliedModders LLC
  29 "CS:S DM Bot Quotas" (2.1.0.446) by AlliedModders LLC
  30 "War3Source Race - Corrupted Disciple" (1.0) by PimpJuice and Ownz
  31 "Basic Votes" (1.3.3) by AlliedModders LLC
  32 "Fun Commands" (1.3.3) by AlliedModders LLC
  33 "Basic Info Triggers" (1.3.3) by AlliedModders LLC
  34 "War3Source Race - Orcish Horde" (1.0.0.0) by PimpinJuice
  35 "War3Source Race - Crypt Lord" (1.0.0.0) by PimpinJuice & Ownz
  36 "Basic Chat" (1.3.3) by AlliedModders LLC
  37 "War3Source" (1.1.1) by PimpinJuice and Ownz
  38 "War3Source Race - Human Alliance" (1.0.0.0) by PimpinJuice

  04 "War3Source_011_KnifeHunter.smx" is the race i made, and it loaded fine without any errors, so now the question is, how do i make it show up in the Changerace menu so players can select it?
« Last Edit: July 08, 2010, 06:12:48 AM by urelind » Logged
Ownz
Developer
Administrator
Hero Member
*****
Posts: 2045



View Profile WWW Email
« Reply #18 on: July 08, 2010, 07:12:57 AM »

lol @   16 <Failed> "WC(WoW)" (1.14) by Stinkyfax

i see this is linux by its distinct failure of proper order

show us your knifeHunter source file
Logged

DarkEnergy
[Oddity]TeacherCreature
Sr. Member
****
Posts: 463


View Profile
« Reply #19 on: July 08, 2010, 07:43:39 AM »

yea have to see source file.

Sorry about my typing at the gym before posting and my arms were jelly
Logged

urelind
Newbie
*
Posts: 18


View Profile Email
« Reply #20 on: July 08, 2010, 07:45:38 AM »

KK,Owns Cheesy
Okay, It's the Human Alliance race, i just modified the teleport cooldown, so i typed it a bit wrong, didn't make it.

credits goes to Anthony Iacono  Cheesy

Code:
/**
 * File: War3Source_HumanAlliance.sp
 * Description: The Human Alliance race for War3Source.
 * Author(s): Anthony Iacono
 */
 
#pragma semicolon 1

#include <sourcemod>
#include "W3SIncs/War3Source_Interface"
#include <sdktools>
#include <sdktools_functions>
#include <sdktools_tempents>
#include <sdktools_tempents_stocks>

new thisRaceID;
new iTeleportCount[65];

new Handle:MaxTeleportCvar;
new Handle:TeleportCooldownCvar;
new bool:bIsBashed[65];
new bool:bInFreezeTime;
new Handle:FreezeTimeCvar;


// Chance/Info Arrays
new Float:BashChance[5]={0.0,0.15,0.21,0.27,0.32};
new Float:TeleportDistance[5]={0.0,600.0,800.0,1000.0,1200.0};

new Float:InvisibilityAlphaTF[5]={1.0,0.84,0.68,0.53,0.35};

new Float:InvisibilityAlphaCS[5]={1.0,0.90,0.8,0.7,0.6};


new DevotionHealth[5]={0,15,25,35,45};

new Float:LastDamageTime[66];

// Effects
new BeamSprite,HaloSprite;

new String:teleportSound[]="war3source/blinkarrival.wav";

public Plugin:myinfo =
{
name = "War3Source Race - Human Alliance",
author = "PimpinJuice",
description = "The Human Alliance race for War3Source.",
version = "1.0.0.0",
url = "http://pimpinjuice.net/"
};

public OnPluginStart()
{
HookEvent("player_spawn",PlayerSpawnEvent);
HookEvent("round_start",RoundStartEvent);
FreezeTimeCvar=FindConVar("mp_freezetime");
MaxTeleportCvar=CreateConVar("war3_human_teleport_max","0","Max amount of teleports per round, 0 for unlimited");
TeleportCooldownCvar=CreateConVar("war3_human_teleport_cooldown","0.0","Cooldown between teleports");


CreateTimer(0.1,TFHPBuff,_,TIMER_REPEAT);

}
new bool:war3ready;
public OnWar3PluginReady()
{
war3ready=true;
thisRaceID=War3_CreateRace("Human Alliance",
"human",
"You are now part of the Human Alliance.",
"You will be part of the Human Alliance when you die or respawn.",
"Invisibility",
"Makes you partially invisible, \n62% visibility - 37% visibility.",
"Devotion Aura",
"Gives you additional 15-45 health pool.",
"Bash",
"Have a 15-32% chance to render an \nenemy immobile for 1 second.",
"Teleport",
"Allows you to teleport to where you \naim, 60-120 feet being the range.");
}

public OnMapStart()
{
BeamSprite=PrecacheModel("materials/sprites/lgtning.vmt");
HaloSprite=PrecacheModel("materials/sprites/halo01.vmt");

War3_PrecacheSound(teleportSound);


//CreateTimer(0.2, LoadSounds);
}
public Action:LoadSounds(Handle:h){
new String:longsound[512];

Format(longsound,sizeof(longsound), "sound/%s", teleportSound);
AddFileToDownloadsTable(longsound);

if(PrecacheSound(teleportSound, true)){
PrintToServer("TPrecacheSound %s",longsound);
}
else{
PrintToServer("Failed: PrecacheSound %s",longsound);
}
}

public OnWar3PlayerAuthed(client)
{
}

public OnRaceSelected(client,oldrace,race)
{
if(race!=thisRaceID)
{
War3_SetBuff(client,fInvisibilitySkill,thisRaceID,1.0); // if we aren't their race anymore we shouldn't be controlling their alpha
}
else
{
ActivateSkills(client);

}
}
public ActivateSkills(client)
{
if(War3_GetRace(client)==thisRaceID)
{

new skill_devo=War3_GetSkillLevel(client,thisRaceID,1);
if(skill_devo)
{
// Devotion Aura
new hpadd=DevotionHealth[skill_devo];
new Float:vec[3];
GetClientAbsOrigin(client,vec);
vec[2]+=25.0;
new ringColor[4]={0,0,0,0};
new team=GetClientTeam(client);
if(team==2)
{
ringColor={255,0,0,255};
}
else if(team==3)
{
ringColor={0,0,255,255};
}
TE_SetupBeamRingPoint(vec,40.0,10.0,BeamSprite,HaloSprite,0,15,1.0,15.0,0.0,ringColor,10,0);
TE_SendToAll();

SetEntityHealth(client,GetClientHealth(client)+hpadd);
//War3_ChatMessage(client,"+%d HP",hpadd);
}

new skilllevel=War3_GetSkillLevel(client,thisRaceID,0);
new Float:alpha=(War3_GetGame()==Game_CS)?InvisibilityAlphaCS[skilllevel]:InvisibilityAlphaTF[skilllevel];
//if(skill_invis>0)
//War3_ChatMessage(client,"You fade %s into the backdrop.",(skill_invis==1)?"slightly":(skill_invis==2)?"well":(skill_invis==3)?"greatly":"dramatically");
War3_SetBuff(client,fInvisibilitySkill,thisRaceID,alpha);

}
}

public OnUltimateCommand(client,race,bool:pressed)
{
new userid=GetClientUserId(client);
if(race==thisRaceID && pressed && userid>1 && IsPlayerAlive(client) && !bInFreezeTime && GetEntityMoveType(client)!=MOVETYPE_NONE)
{
new ult_level=War3_GetSkillLevel(client,race,3);
if(ult_level>0)
{
new max_teles=GetConVarInt(MaxTeleportCvar);
if(max_teles<0) max_teles=0;

//if(War3_HasFlag(client)){
// PrintHintText(client,"No teleporting with Flag");
//}
if(max_teles>0&&iTeleportCount[client]>=max_teles)
{
PrintHintText(client,"Used max of %d Teleports",max_teles);
}
else if(War3_SkillNotInCooldown(client,thisRaceID,3,true))
{
TeleportPlayerView(client,TeleportDistance[ult_level]);
}
}
else
{
PrintHintText(client,"Level Your Ultimate First");
}
}
}



public OnSkillLevelChanged(client,race,skill,oldskilllevel,newskilllevel)
{
if(race==thisRaceID&&skill==0&&newskilllevel>=0&&War3_GetRace(client)==thisRaceID)
{
new Float:alpha=(War3_GetGame()==Game_CS)?InvisibilityAlphaCS[newskilllevel]:InvisibilityAlphaTF[newskilllevel];
if(newskilllevel>0 && IsPlayerAlive(client)) // dont tell them if they are dead
//War3_ChatMessage(client,"You fade %s into the backdrop.",(newskilllevel==1)?"slightly":(newskilllevel==2)?"well":(newskilllevel==3)?"greatly":"dramatically");
War3_SetBuff(client,fInvisibilitySkill,thisRaceID,alpha);
}
}

public Action:OnWar3TakeDamage(victim,attacker,inflictor,Float:damage,damagetype)
{
LastDamageTime[victim]=GetGameTime();
if(IS_PLAYER(victim)&&IS_PLAYER(attacker)&&victim>0&&attacker>0&&attacker!=victim)
{

new vteam=GetClientTeam(victim);
new ateam=GetClientTeam(attacker);
if(vteam!=ateam)
{
new race=War3_GetRace(attacker);
if(race==thisRaceID)
{
new skill_bash=War3_GetSkillLevel(attacker,race,2);
if(skill_bash && !War3_GetImmunity(victim,Immunity_Skills))
{
// Bash
new Float:chance_mod=War3_ChanceModifier(attacker,inflictor,damagetype);
new Float:percent=BashChance[skill_bash];
if(GetRandomFloat(0.0,1.0)<=percent*chance_mod && !bIsBashed[victim] && IsPlayerAlive(attacker))
{
PrintHintText(victim,"You got Bashed");
PrintHintText(attacker,"Bash!");
bIsBashed[victim]=true;
SetEntityMoveType(victim,MOVETYPE_NONE);
War3_FlashScreen(victim,RGBA_COLOR_RED);
CreateTimer(0.25,UnfreezePlayer,GetClientUserId(victim));
}
}
}
}
}
}

// Events
public PlayerSpawnEvent(Handle:event,const String:name[],bool:dontBroadcast)
{
new userid=GetEventInt(event,"userid");
new client=GetClientOfUserId(userid);
if(client>0)
{

bIsBashed[client]=false;
SetEntityMoveType(client,MOVETYPE_WALK);
iTeleportCount[client]=0;
new race=War3_GetRace(client);
if(race==thisRaceID)
{
ActivateSkills(client);
}
}
}

public RoundStartEvent(Handle:event,const String:name[],bool:dontBroadcast)
{
if(War3_GetGame()!=Game_TF)
{
bInFreezeTime=true;
CreateTimer(GetConVarFloat(FreezeTimeCvar),EndFreezeTime);
}
}

// Misc stuff
public Action:EndFreezeTime(Handle:timer,any:param)
{
bInFreezeTime=false;
}

public Action:UnfreezePlayer(Handle:timer,any:userid)
{
new client=GetClientOfUserId(userid);
if(client>0)
{
//PrintHintText(client,"NO LONGER BASHED");
SetEntityMoveType(client,MOVETYPE_WALK);
bIsBashed[client]=false;
}
}

// Teleport Stuff
// By: stinkyfax
// Much thanks, this would be a nightmare without him.
new ClientTracer;
new Float:emptypos[3];
new Float:oldpos[66][3];
new Float:teleportpos[66][3];
bool:TeleportPlayerView(client,Float:distance)
{
if(client>0)
{
if(IsPlayerAlive(client))
{
new Float:angle[3];
GetClientEyeAngles(client,angle);
new Float:endpos[3];
new Float:startpos[3];
GetClientEyePosition(client,startpos);
new Float:dir[3];
GetAngleVectors(angle, dir, NULL_VECTOR, NULL_VECTOR);

ScaleVector(dir, distance);
//PrintToChatAll("DIR %f %f %f",dir[0],dir[1],dir[2]);

AddVectors(startpos, dir, endpos);

GetClientAbsOrigin(client,oldpos[client]);


//PrintToChatAll("1");

ClientTracer=client;
TR_TraceRayFilter(startpos,endpos,MASK_PLAYERSOLID,RayType_EndPoint,AimTargetFilter);
TR_GetEndPosition(endpos);


//new Float:normal[3];
//TR_GetPlaneNormal(INVALID_HANDLE,normal);

//ScaleVector(normal, 20.0);


if(enemyImmunityInRange(client,endpos)){
PrintHintText(client,"Enemy Immunity");
return false;
}

//PrintToChatAll("1endpos %f %f %f",endpos[0],endpos[1],endpos[2]);
distance=GetVectorDistance(startpos,endpos);
GetAngleVectors(angle, dir, NULL_VECTOR, NULL_VECTOR);///get dir again
ScaleVector(dir, distance-33.0);

AddVectors(startpos,dir,endpos);
//PrintToChatAll("DIR %f %f %f",dir[0],dir[1],dir[2]);

//PrintToChatAll("2endpos %f %f %f",endpos[0],endpos[1],endpos[2]);

//endpos[1]=(startpos[1]+(distance*Sine(DegToRad(angle[1]))));
//endpos[0]=(startpos[0]+(distance*Cosine(DegToRad(angle[1]))));
//if(!CheckPlayerBox(endpos,startpos,client))
// return false;
emptypos[0]=0.0;
emptypos[1]=0.0;
emptypos[2]=0.0;

endpos[2]-=30.0;
getEmptyLocationHull(client,endpos);

//PrintToChatAll("emptypos %f %f %f",emptypos[0],emptypos[1],emptypos[2]);
if(GetVectorLength(emptypos)<1.0){
PrintHintText(client,"No empty teleport location found");
return false; //it returned 0 0 0
}


TeleportEntity(client,emptypos,NULL_VECTOR,NULL_VECTOR);
EmitSoundToAll(teleportSound,client);
EmitSoundToAll(teleportSound,client);



teleportpos[client][0]=emptypos[0];
teleportpos[client][1]=emptypos[1];
teleportpos[client][2]=emptypos[2];

CreateTimer(0.1,checkTeleport,client);






return true;
}
}
return false;
}
public Action:checkTeleport(Handle:h,any:client){
new Float:pos[3];

GetClientAbsOrigin(client,pos);
if(GetVectorDistance(teleportpos[client],pos)<0.1)//he didnt move in this 0.1 second
{
TeleportEntity(client,oldpos[client],NULL_VECTOR,NULL_VECTOR);
PrintHintText(client,"You cannot teleport there");
}
else{

iTeleportCount[client]+=1;

PrintHintText(client,"TELEPORTED");

new Float:cooldown=GetConVarFloat(TeleportCooldownCvar);
War3_CooldownMGR(client,cooldown,thisRaceID,3,_,_,_,"Teleport");
}
}
public bool:AimTargetFilter(entity,mask)
{
return !(entity==ClientTracer);
}
/*
bool:CheckPlayerBox(Float:bottom[3],Float:start[3],client)
{
new Float:edge[3][8];
//point A
edge[2][0]=bottom[2];
edge[0][0]=bottom[0]+12.5;
edge[1][0]=bottom[1]+12.5;
//point B
edge[2][1]=edge[2][0];
edge[0][1]=edge[0][0]+25.0;
edge[1][1]=edge[1][0];
//point C
edge[2][2]=edge[2][1];
edge[0][2]=edge[0][1];
edge[1][2]=edge[1][1]+25.0;
//point D
edge[2][3]=edge[2][2];
edge[0][3]=edge[0][2]-25.0;
edge[1][3]=edge[1][2];
//other buttons
for(new i=0;i<4;i++)
{
for(new x=0;x<2;x++)
{
edge[x][i+4]=edge[x][i];
}
edge[2][i+4]=edge[2][i]+67.0;
}
for(new i=0;i<4;i++)
{
decl Float:point[3];
point[0]=edge[0][i];
point[1]=edge[1][i];
point[2]=edge[2][i];
decl Float:endpoint[3];
endpoint[0]=edge[0][i+4];
endpoint[1]=edge[1][i+4];
endpoint[2]=edge[2][i+4];
TR_TraceRayFilter(point,endpoint,MASK_PLAYERSOLID,RayType_EndPoint,AimTargetFilter);
if(TR_DidHit())
{
return false;
}
}
for(new i=0;i<7;i++)
{
decl Float:point[3];
point[0]=edge[0][i];
point[1]=edge[1][i];
point[2]=edge[2][i];
decl Float:endpoint[3];
endpoint[0]=edge[0][i+1];
endpoint[1]=edge[1][i+1];
endpoint[2]=edge[2][i+1];
TR_TraceRayFilter(point,endpoint,MASK_PLAYERSOLID,RayType_EndPoint,AimTargetFilter);
if(TR_DidHit())
{
return false;
}
}
new Float:top[3];
top=bottom;
top[2]+=90;
ClientTracer=client;
TR_TraceRayFilter(top,bottom,MASK_PLAYERSOLID,RayType_EndPoint,AimTargetFilter);
new bool:temp;
temp=TR_DidHit();
if(temp)
{
return false;
}
ClientTracer=client;
TR_TraceRayFilter(start,top,MASK_PLAYERSOLID,RayType_EndPoint,AimTargetFilter);
temp=TR_DidHit();
if(temp)
{
return false;
}
return true;
}  */


new absincarray[]={0,4,-4,8,-8,12,-12,18,-18,22,-22,25,-25};//,27,-27,30,-30,33,-33,40,-40}; //for human it needs to be smaller

public bool:getEmptyLocationHull(client,Float:originalpos[3]){


new Float:mins[3];
new Float:maxs[3];
GetClientMins(client,mins);
GetClientMaxs(client,maxs);

//PrintToChatAll("min : %.1f %.1f %.1f MAX %.1f %.1f %.1f",mins[0],mins[1],mins[2],maxs[0],maxs[1],maxs[2]);
new absincarraysize=sizeof(absincarray);

new limit=5000;
for(new x=0;x<absincarraysize;x++){
if(limit>0){
for(new y=0;y<=x;y++){
if(limit>0){
for(new z=0;z<=y;z++){
new Float:pos[3]={0.0,0.0,0.0};
AddVectors(pos,originalpos,pos);
pos[0]+=float(absincarray[x]);
pos[1]+=float(absincarray[y]);
pos[2]+=float(absincarray[z]);

//PrintToChatAll("hull at %.1f %.1f %.1f",pos[0],pos[1],pos[2]);
//PrintToServer("hull at %d %d %d",absincarray[x],absincarray[y],absincarray[z]);
TR_TraceHullFilter(pos,pos,mins,maxs,CONTENTS_SOLID|CONTENTS_MOVEABLE,CanHitThis,client);
//new ent;
if(TR_DidHit(_))
{
//PrintToChatAll("2");
//ent=TR_GetEntityIndex(_);
//PrintToChatAll("hit %d self: %d",ent,client);
}
else{
//TeleportEntity(client,pos,NULL_VECTOR,NULL_VECTOR);
AddVectors(emptypos,pos,emptypos); ///set this gloval variable
limit=-1;
break;
}

if(limit--<0){
break;
}
}

if(limit--<0){
break;
}
}
}

if(limit--<0){
break;
}

}

}

}

public bool:CanHitThis(entityhit, mask, any:data)
{
if(entityhit == data )
{// Check if the TraceRay hit the itself.
return false; // Don't allow self to be hit, skip this result
}
if(War3_ValidPlayer(entityhit)&&War3_ValidPlayer(data)&&War3_GetGame()==Game_TF&&GetClientTeam(entityhit)==GetClientTeam(data)){
return false; //skip result, prend this space is not taken cuz they on same team
}
return true; // It didn't hit itself
}


public bool:enemyImmunityInRange(client,Float:playerVec[3])
{
//ELIMINATE ULTIMATE IF THERE IS IMMUNITY AROUND
//new Float:playerVec[3];
//GetClientAbsOrigin(client,playerVec);
new Float:otherVec[3];
new team = GetClientTeam(client);

for(new i=1;i<=MaxClients;i++)
{
if(War3_ValidPlayer(i,true)&&GetClientTeam(i)!=team&&War3_GetImmunity(i,Immunity_Ultimates))
{
GetClientAbsOrigin(i,otherVec);
if(GetVectorDistance(playerVec,otherVec)<300)
{
return true;
}
}
}
return false;
}            

public Action:TFHPBuff(Handle:h,any:data){
if(war3ready&&War3_GetGame()==Game_TF){
//only create timer of TF2
for(new i=1;i<=MaxClients;i++){
if(War3_ValidPlayer(i,true)){
if(War3_GetRace(i)==thisRaceID&&GetGameTime()>LastDamageTime[i]+10.0){
new skill_devo=War3_GetSkillLevel(i,thisRaceID,1);
if(skill_devo)
{
// Devotion Aura
new curhp =GetClientHealth(i);
new maxhp =War3_GetMaxHP(i);
new hpadd=DevotionHealth[skill_devo];
if(curhp>=maxhp&&curhp<maxhp+hpadd){ ///we should add
new newhp=curhp+2;
if(newhp>maxhp+hpadd){
newhp=maxhp+hpadd;
}

SetEntityHealth(i,newhp);
}
}
}
}
}
}  
}



Logged
Ownz
Developer
Administrator
Hero Member
*****
Posts: 2045



View Profile WWW Email
« Reply #21 on: July 08, 2010, 09:09:43 AM »

just change the cvar for the cooldown
Logged

DarkEnergy
[Oddity]TeacherCreature
Sr. Member
****
Posts: 463


View Profile
« Reply #22 on: July 08, 2010, 09:34:01 AM »

Has anyone had luck altering war3config because mine doesnt work at all! - honestly I havent tried adding it to server.cfg that would probably do it

but yea that would be way easier lol
Logged

iceman
Full Member
***
Posts: 162



View Profile
« Reply #23 on: July 08, 2010, 10:08:37 AM »

war3source.cfg in the cfg folder works for me.
Logged
urelind
Newbie
*
Posts: 18


View Profile Email
« Reply #24 on: July 08, 2010, 10:20:24 AM »

"war3_human_teleport_cooldown","0.0","Cooldown between teleports");

How do i make it so it actually takes effect on the race?
Logged
Pages: [1] 2
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!