forked from UNLOZE/sm-plugins
added functionality to check the map on a bunch of map specific plugins. this way we dont have to load/unload plugins that usually causes slow map changes or even causes crashes. momsurffix was compiled with sourcemod 1.11
This commit is contained in:
@@ -12,14 +12,14 @@
|
||||
#define SPEED_FORWARD 1.0
|
||||
#define SPEED_TURNING 0.5
|
||||
|
||||
stock float FloatMod(float num, float denom)
|
||||
stock float FloatMod1(float num, float denom)
|
||||
{
|
||||
return num - denom * RoundToFloor(num / denom);
|
||||
}
|
||||
|
||||
stock float operator%(float oper1, float oper2)
|
||||
{
|
||||
return FloatMod(oper1, oper2);
|
||||
return FloatMod1(oper1, oper2);
|
||||
}
|
||||
|
||||
public bool IsValidPlayer(int player)
|
||||
@@ -27,7 +27,7 @@ public bool IsValidPlayer(int player)
|
||||
return player >= 1 && player <= 64 && IsValidEntity(player) && IsPlayerAlive(player);
|
||||
}
|
||||
|
||||
public float GetDistance(const float[3] v1, const float[3] v2)
|
||||
public float GetDistance(const float v1[3], const float v2[3])
|
||||
{
|
||||
return SquareRoot((v1[0] - v2[0]) * (v1[0] - v2[0]) + (v1[1] - v2[1]) * (v1[1] - v2[1]) + (v1[2] - v2[2]) * (v1[2] - v2[2]));
|
||||
}
|
||||
@@ -130,9 +130,8 @@ methodmap MovingNpc < Basic
|
||||
}
|
||||
}
|
||||
|
||||
public float GetTargetYaw(const float[3] start, const float[3] target)
|
||||
public float GetTargetYaw(const float start[3], const float target[3])
|
||||
{
|
||||
|
||||
float yaw = 0.00;
|
||||
float v[3];
|
||||
SubtractVectors(start, target, v);
|
||||
|
||||
Reference in New Issue
Block a user