[ASSAULTCUBE] Hack Tutorials
Code:
attackphysics(from, to); hits.setsizenodelete(0); raydamage(from, to, owner); attackfx(from, to, 0); gunwait = info.attackdelay; mag--; sendshoot(from, to);
dat gebeurd omdat er geen vijand is, ik was te lui om checks toe te voegen ^^
if a mod could update:
into
it would be much appreciated
fixes a crash when shooting if there is no enemy
if a mod could update:
Code:
float tdist=9999999.9; //max distance we want
int target=-1; // temporary target
vec newto; // where our new hit location is
loopv(players)
{
if(players[i]==NULL) continue; //if the pointer is not NULL
if(!isteam(player1->team, players[i]->team) && players[i] != player1 && players[i]->state == CS_ALIVE) // and the team isnt the same, its not pointing to our own player and the enemy is alive
{
if(from.distxy(players[i]->o)<tdist) // check if the distance is below the best distance
{
tdist=from.distxy(players[i]->o);// if it is save our new distance as best distance
target=i; // assign our target
}
}
}
newto = players[target]->o; // the new hit location is our enemys location
attackphysics(from, newto);// send the attack physics
hits.setsizenodelete(0);
raydamage(from, newto, owner); // apply the damage
attackfx(from, newto, 0); // apply the effects
gunwait = info.attackdelay; // apply the gun wait time
mag--; // decrease our ammo
sendshoot(from, newto); // send our shot over to the server
Code:
float tdist=9999999.9; //max distance we want
int target=-1; // temporary target
vec newto; // where our new hit location is
loopv(players)
{
if(players[i]==NULL) continue; //if the pointer is not NULL
if(!isteam(player1->team, players[i]->team) && players[i] != player1 && players[i]->state == CS_ALIVE) // and the team isnt the same, its not pointing to our own player and the enemy is alive
{
if(from.distxy(players[i]->o)<tdist) // check if the distance is below the best distance
{
tdist=from.distxy(players[i]->o);// if it is save our new distance as best distance
target=i; // assign our target
}
}
}
if(target != -1)
{
newto = players[target]->o; // the new hit location is our enemys location
attackphysics(from, newto);// send the attack physics
hits.setsizenodelete(0);
raydamage(from, newto, owner); // apply the damage
attackfx(from, newto, 0); // apply the effects
gunwait = info.attackdelay; // apply the gun wait time
mag--; // decrease our ammo
sendshoot(from, newto); // send our shot over to the server
}
else
{
attackphysics(from, to);// send the attack physics
hits.setsizenodelete(0);
raydamage(from, to, owner); // apply the damage
attackfx(from, to, 0); // apply the effects
gunwait = info.attackdelay; // apply the gun wait time
mag--; // decrease our ammo
sendshoot(from, to); // send our shot over to the server
}
fixes a crash when shooting if there is no enemydamnit how noob can i be it still doesnt work because i dont have VS 2008 SP1 im installing it right now it should work now
tell everyone else to get SP1 if it doesnt come with the VS 2008 + get SDK 1.1
my VS 2008 is pirated so i think thats why.
tell everyone else to get SP1 if it doesnt come with the VS 2008 + get SDK 1.1
my VS 2008 is pirated so i think thats why.
Umm ok so i did everything you said. But what should i build? like what type of project should i open? then build?
OMG! u haxxed mah account and forced me to post into this topic that now contains all of my codens 

c++
i need help with this, :S..i dont know where to start, pm me on reply in thread, or add my msn stallions39@hotmail.com thanks..
I couldn't get assaultcube to compile, so then i remembered " hey, sauerbraten compiles just fine! ". I then went snifting through the sauerbraten src and found pretty much the same code. You can go into physics.cpp and change the gravity settings and the jump force or you can make it so you can walk up walls. Since sauerbraten's code is slightly different, I found the guninfo in game.cpp/.h. I'm assuming the "part" variable is the spread, but with them all set to 0 there are no changes in the game. Everything else works perfecting except spread though. The rate of fire, damage, range of weapons, etc. are all changed to crazy numbers. chainsaw snipe ftw? Anyway, thanks for this tut, you opened new doors for me.
This thread is closed for replies.



