Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public PlVers:__version =
- {
- version = 5,
- filevers = "1.4.2",
- date = "07/07/2015",
- time = "19:17:59"
- };
- new Float:NULL_VECTOR[3];
- new String:NULL_STRING[4];
- public Extension:__ext_core =
- {
- name = "Core",
- file = "core",
- autoload = 0,
- required = 0,
- };
- new MaxClients;
- public Extension:__ext_sdkhooks =
- {
- name = "sdkhooks",
- file = "sdkhooks.ext",
- autoload = 1,
- required = 1,
- };
- public Extension:__ext_sdktools =
- {
- name = "SDKTools",
- file = "sdktools.ext",
- autoload = 1,
- required = 1,
- };
- public Extension:__ext_smsock =
- {
- name = "Socket",
- file = "socket.ext",
- autoload = 1,
- required = 1,
- };
- new bool:xD = 1;
- new String:PLUGIN_NAME[20] = "Possessed Weapons";
- new String:PLUGIN_VERS[8] = "1.3.1";
- new Handle:g_hSQL;
- new bool:g_bMYSQL;
- new Handle:g_hTrie;
- new g_WeaponMaxLevel[25];
- new g_MyActivePossessedWeaponID[66] =
- {
- -1, ...
- };
- new String:g_sExplodeRadius[12];
- new String:g_sExplodeMagnitude[12];
- new Handle:g_hFreezeTimer[66];
- new g_FadeColor[4];
- new bool:g_bCSGO = 1;
- new g_ClientInfo[66][65];
- new g_WeaponLevelInfo[25][6][19];
- new g_ActiveFeature[66][19];
- new String:g_sWeapon[25][12];
- new String:FOR_IP_PORT[20] = "46.174.52.12:27205";
- new bool:bSocketOk;
- new bool:bSocketReceiveOk;
- public Plugin:myinfo =
- {
- name = "Possessed Weapons",
- description = "",
- author = "wS (World-Source.Ru)",
- version = "1.3.1",
- url = ""
- };
- new Handle:hCvarCsGoServer;
- new Handle:hCvarPwCmd;
- new Handle:hOnClientSettingsChanged;
- new Handle:hOnClientAuthorized;
- new Handle:hOnClientUpgradeLevel;
- new Handle:hOnClientUpgradeLevel_Post;
- new Handle:hOnCreditsChanged;
- new Handle:hOnClientUsePossessedWeapon;
- new String:sMenuSound[256];
- new Handle:hMenuSound;
- new Handle:g_hInfoPanel;
- new g_MyLastWeaponRef[66];
- new Handle:g_hChangeWeaponTimer[66];
- new Handle:g_hAmmoHistoryArray;
- new Handle:hRegenTimer[66];
- new bool:bRoundStartMsg;
- public __ext_core_SetNTVOptional()
- {
- MarkNativeAsOptional("GetFeatureStatus");
- MarkNativeAsOptional("RequireFeature");
- MarkNativeAsOptional("AddCommandListener");
- MarkNativeAsOptional("RemoveCommandListener");
- VerifyCoreVersion();
- return 0;
- }
- Float:operator/(Float:,_:)(Float:oper1, oper2)
- {
- return oper1 / float(oper2);
- }
- bool:operator>(Float:,Float:)(Float:oper1, Float:oper2)
- {
- return FloatCompare(oper1, oper2) > 0;
- }
- bool:operator<(Float:,Float:)(Float:oper1, Float:oper2)
- {
- return FloatCompare(oper1, oper2) < 0;
- }
- Float:DegToRad(Float:angle)
- {
- return angle * 3.1415927 / 180;
- }
- ScaleVector(Float:vec[3], Float:scale)
- {
- new var1 = vec;
- var1[0] = var1[0] * scale;
- vec[1] *= scale;
- vec[2] *= scale;
- return 0;
- }
- FindCharInString(String:str[], c, bool:reverse)
- {
- new i;
- new len = strlen(str);
- if (!reverse)
- {
- i = 0;
- while (i < len)
- {
- if (c == str[i])
- {
- return i;
- }
- i++;
- }
- }
- else
- {
- i = len + -1;
- while (0 <= i)
- {
- if (c == str[i])
- {
- return i;
- }
- i--;
- }
- }
- return -1;
- }
- ExplodeString(String:text[], String:split[], String:buffers[][], maxStrings, maxStringLength, bool:copyRemainder)
- {
- new reloc_idx;
- new idx;
- new total;
- new var1;
- if (maxStrings < 1 || !split[0])
- {
- return 0;
- }
- new var2 = SplitString(text[reloc_idx], split, buffers[total], maxStringLength);
- idx = var2;
- while (var2 != -1)
- {
- reloc_idx = idx + reloc_idx;
- total++;
- if (maxStrings == total)
- {
- if (copyRemainder)
- {
- strcopy(buffers[total + -1], maxStringLength, text[reloc_idx - idx]);
- }
- return total;
- }
- }
- total++;
- strcopy(buffers[total], maxStringLength, text[reloc_idx]);
- return total;
- }
- Handle:SQLite_UseDatabase(String:database[], String:error[], maxlength)
- {
- new Handle:kv;
- new Handle:db;
- kv = CreateKeyValues("", "", "");
- KvSetString(kv, "driver", "sqlite");
- KvSetString(kv, "database", database);
- db = SQL_ConnectCustom(kv, error, maxlength, false);
- CloseHandle(kv);
- return db;
- }
- Handle:StartMessageOne(String:msgname[], client, flags)
- {
- new players[1];
- players[0] = client;
- return StartMessage(msgname, players, 1, flags);
- }
- PrintToChatAll(String:format[])
- {
- decl String:buffer[192];
- new i = 1;
- while (i <= MaxClients)
- {
- if (IsClientInGame(i))
- {
- SetGlobalTransTarget(i);
- VFormat(buffer, 192, format, 2);
- PrintToChat(i, "%s", buffer);
- }
- i++;
- }
- return 0;
- }
- GetEntSendPropOffs(ent, String:prop[], bool:actual)
- {
- decl String:cls[64];
- if (!GetEntityNetClass(ent, cls, 64))
- {
- return -1;
- }
- if (actual)
- {
- return FindSendPropInfo(cls, prop, 0, 0, 0);
- }
- return FindSendPropOffs(cls, prop);
- }
- bool:GetEntityClassname(entity, String:clsname[], maxlength)
- {
- return !!GetEntPropString(entity, PropType:1, "m_iClassname", clsname, maxlength, 0);
- }
- SetEntityRenderMode(entity, RenderMode:mode)
- {
- static bool:gotconfig;
- static String:prop[32];
- if (!gotconfig)
- {
- new Handle:gc = LoadGameConfigFile("core.games");
- new bool:exists = GameConfGetKeyValue(gc, "m_nRenderMode", prop, 32);
- CloseHandle(gc);
- if (!exists)
- {
- strcopy(prop, 32, "m_nRenderMode");
- }
- gotconfig = true;
- }
- SetEntProp(entity, PropType:0, prop, mode, 1, 0);
- return 0;
- }
- SetEntityRenderColor(entity, r, g, b, a)
- {
- static bool:gotconfig;
- static String:prop[32];
- if (!gotconfig)
- {
- new Handle:gc = LoadGameConfigFile("core.games");
- new bool:exists = GameConfGetKeyValue(gc, "m_clrRender", prop, 32);
- CloseHandle(gc);
- if (!exists)
- {
- strcopy(prop, 32, "m_clrRender");
- }
- gotconfig = true;
- }
- new offset = GetEntSendPropOffs(entity, prop, false);
- if (0 >= offset)
- {
- ThrowError("SetEntityRenderColor not supported by this mod");
- }
- SetEntData(entity, offset, r, 1, true);
- SetEntData(entity, offset + 1, g, 1, true);
- SetEntData(entity, offset + 2, b, 1, true);
- SetEntData(entity, offset + 3, a, 1, true);
- return 0;
- }
- SetEntityGravity(entity, Float:amount)
- {
- static bool:gotconfig;
- static String:datamap[32];
- if (!gotconfig)
- {
- new Handle:gc = LoadGameConfigFile("core.games");
- new bool:exists = GameConfGetKeyValue(gc, "m_flGravity", datamap, 32);
- CloseHandle(gc);
- if (!exists)
- {
- strcopy(datamap, 32, "m_flGravity");
- }
- gotconfig = true;
- }
- SetEntPropFloat(entity, PropType:1, datamap, amount, 0);
- return 0;
- }
- AddFileToDownloadsTable(String:filename[])
- {
- static table = -1;
- if (table == -1)
- {
- table = FindStringTable("downloadables");
- }
- new bool:save = LockStringTables(false);
- AddToStringTable(table, filename, "", -1);
- LockStringTables(save);
- return 0;
- }
- wS_Protect_IpPort(&V)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_Protect_IpPort" (number 17)
- bool:wS_IpPortValid()
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_IpPortValid" (number 18)
- public cvar_hostip_ip_port_changed(Handle:cVar, String:OldValue[], String:NewValue[])
- {
- wS_Protect_IpPort(1);
- return 0;
- }
- bool:wS_Protect(ip[4], port)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_Protect" (number 20)
- wS_Protect_Stop(String:Error[])
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_Protect_Stop" (number 21)
- public Action:OnPluginStart_ChangeLevel(Handle:timer)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "OnPluginStart_ChangeLevel" (number 22)
- public server_spawn(Handle:event, String:name[], bool:silent)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "server_spawn" (number 23)
- wS_Socket(bool:bFirst)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_Socket" (number 24)
- public Action:TIMER_wS_Socket(Handle:timer)
- {
- wS_Socket(false);
- return Action:4;
- }
- public OnSocketError(Handle:socket, errorType, errorNum, any:data)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "OnSocketError" (number 26)
- public OnSocketConnected(Handle:socket, any:id)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "OnSocketConnected" (number 27)
- public OnSocketReceive(Handle:socket, String:receiveData[], dataSize, any:data)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "OnSocketReceive" (number 28)
- public OnSocketDisconnected(Handle:socket, any:data)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "OnSocketDisconnected" (number 29)
- public OnPluginStart()
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "OnPluginStart" (number 30)
- wS_Cvars()
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_Cvars" (number 31)
- public Action:AutoExecConfig_Timer(Handle:timer)
- {
- decl String:info[28];
- GetConVarString(hCvarPwCmd, info, 25);
- if (TrimString(info) < 1)
- {
- strcopy(info, 25, "sm_pw");
- }
- RegConsoleCmd(info, PwCmd_CallBack, "", 0);
- g_bCSGO = GetConVarBool(hCvarCsGoServer);
- return Action:4;
- }
- public cvar_ExplodeRadius(Handle:cvar, String:OldValue[], String:NewValue[])
- {
- strcopy(g_sExplodeRadius, 10, NewValue);
- return 0;
- }
- public cvar_ExplodeMagnitude(Handle:cvar, String:OldValue[], String:NewValue[])
- {
- strcopy(g_sExplodeMagnitude, 10, NewValue);
- return 0;
- }
- public cvar_FadeColor(Handle:cvar, String:OldValue[], String:NewValue[])
- {
- wS_UpdateFadeColor(cvar);
- return 0;
- }
- public cvar_RoundStartMsg(Handle:cvar, String:OldValue[], String:NewValue[])
- {
- wS_UpdateRoundStartMsgVar(cvar);
- return 0;
- }
- wS_UpdateFadeColor(Handle:cvar)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_UpdateFadeColor" (number 37)
- wS_GetWeaponID(String:item[])
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_GetWeaponID" (number 38)
- bool:wS_IsPossessedWeaponID(WeaponID)
- {
- return g_WeaponMaxLevel[WeaponID] > 0;
- }
- wS_ClearClientVars(client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_ClearClientVars" (number 40)
- wS_UpdateClientCache(client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_UpdateClientCache" (number 41)
- public Panel_CallBack(Handle:panel, MenuAction:action, client, item)
- {
- if (action == MenuAction:4)
- {
- wS_PlayMenuSound(client);
- }
- return 0;
- }
- wS_AddSteamToUpdateList(String:steamid[])
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_AddSteamToUpdateList" (number 43)
- Handle:wS_UpdateListHandle()
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_UpdateListHandle" (number 44)
- public Action:wS_Sql_Update_Timer(Handle:timer)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_Sql_Update_Timer" (number 45)
- wS_AddToPanelWeaponLevelInfo(Handle:panel, WeaponID, level, String:info[100], client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_AddToPanelWeaponLevelInfo" (number 46)
- wS_ClearActiveFeatures(client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_ClearActiveFeatures" (number 47)
- wS_SetColor(entity, r, g, b, a)
- {
- SetEntityRenderMode(entity, RenderMode:1);
- SetEntityRenderColor(entity, r, g, b, a);
- return 0;
- }
- wS_ClearTimer(&Handle:t)
- {
- if (t)
- {
- KillTimer(t, false);
- t = 0;
- }
- return 0;
- }
- bool:wS_BuyWeaponIdLevel(client, WeaponID, Level)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_BuyWeaponIdLevel" (number 50)
- bool:wS_AddCredits(client, credits)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_AddCredits" (number 51)
- wS_GetCvarSound(Handle:cvar, String:buffer[256])
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_GetCvarSound" (number 52)
- /* ERROR! java.lang.StackOverflowError */
- function "wS_LoadWeapons" (number 53)
- bool:wS_GetAuraColor(String:info[], color[4])
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_GetAuraColor" (number 54)
- public Action:wS_TryConnect_Timer(Handle:timer)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_TryConnect_Timer" (number 55)
- public SQL_CallBack(Handle:owner, Handle:hndl, String:error[], any:data)
- {
- if (!hndl)
- {
- LogError(error);
- }
- return 0;
- }
- public OnClientConnected(client)
- {
- wS_ClearClientVars(client);
- return 0;
- }
- public OnClientDisconnect(client)
- {
- wS_ClearClientVars(client);
- return 0;
- }
- public OnClientPutInServer(client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "OnClientPutInServer" (number 59)
- public Authorize_SQLCallBack(Handle:sql, Handle:result, String:error[], any:client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "Authorize_SQLCallBack" (number 60)
- public APLRes:AskPluginLoad2(Handle:myself, bool:late, String:error[], err_max)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "AskPluginLoad2" (number 61)
- wS_Forwards()
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_Forwards" (number 62)
- PW_OnClientSettingsChanged_event(client)
- {
- Call_StartForward(hOnClientSettingsChanged);
- Call_PushCell(client);
- Call_Finish(0);
- return 0;
- }
- PW_OnClientAuthorized_event(client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "PW_OnClientAuthorized_event" (number 64)
- bool:wS_CanUpgradeLevel(client, WeaponID, Level, MaxLevel)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_CanUpgradeLevel" (number 65)
- PW_OnClientUpgradeLevel_Post_event(client, WeaponID, Level, MaxLevel)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "PW_OnClientUpgradeLevel_Post_event" (number 66)
- PW_OnCreditsChanged_event(client, OldCr, NewCr)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "PW_OnCreditsChanged_event" (number 67)
- PW_OnClientUsePossessedWeapon_event(client, WeaponID)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "PW_OnClientUsePossessedWeapon_event" (number 68)
- public PW_IsClientAuthorized_(Handle:plugin, args)
- {
- return g_ClientInfo[GetNativeCell(1)][0];
- }
- public PW_GetCredits_(Handle:plugin, args)
- {
- return g_ClientInfo[GetNativeCell(1)][36];
- }
- public PW_SetCredits_(Handle:plugin, args)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "PW_SetCredits_" (number 71)
- public PW_AddCredits_(Handle:plugin, args)
- {
- return wS_AddCredits(GetNativeCell(1), GetNativeCell(2));
- }
- public PW_GetActiveWeaponID_(Handle:plugin, args)
- {
- return g_MyActivePossessedWeaponID[GetNativeCell(1)];
- }
- public PW_GetClientWeaponLevel_(Handle:plugin, args)
- {
- return g_ClientInfo[GetNativeCell(1)][37][GetNativeCell(2)];
- }
- public PW_GetWeaponMaxLevel_(Handle:plugin, args)
- {
- return g_WeaponMaxLevel[GetNativeCell(1)];
- }
- wS_SaveSoundHandle_hMenuSound(Handle:cvar)
- {
- hMenuSound = cvar;
- return 0;
- }
- wS_LoadSounds()
- {
- wS_GetCvarSound(hMenuSound, sMenuSound);
- return 0;
- }
- wS_PlayMenuSound(client)
- {
- if (strlen(sMenuSound) > 4)
- {
- ClientCommand(client, "play \"%s\"", sMenuSound);
- }
- return 0;
- }
- wS_ClearAura(client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_ClearAura" (number 79)
- wS_CreateAura(client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_CreateAura" (number 80)
- public Action:Transmit_Aura(entity, client)
- {
- new var1;
- if (g_ClientInfo[client][64] == entity)
- {
- var1 = MissingTAG:3;
- }
- else
- {
- var1 = MissingTAG:0;
- }
- return var1;
- }
- public Action:pw_credits_add(admin, args)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "pw_credits_add" (number 82)
- public Action:pw_clear(admin, args)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "pw_clear" (number 83)
- public Action:PwCmd_CallBack(client, args)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "PwCmd_CallBack" (number 84)
- wS_ShowMainMenu(client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_ShowMainMenu" (number 85)
- public MainMenu_CallBack(Handle:menu, MenuAction:action, client, item)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "MainMenu_CallBack" (number 86)
- wS_ShowInfoPanel(client)
- {
- SendPanelToClient(g_hInfoPanel, client, g_hInfoPanel_CallBack, 0);
- return 0;
- }
- wS_InfoPanel()
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_InfoPanel" (number 88)
- wS_AddDefaultInfoToInfoPanel()
- {
- CloseHandle(g_hInfoPanel);
- g_hInfoPanel = CreatePanel(Handle:0);
- DrawPanelText(g_hInfoPanel, "ОДЕРЖИМОЕ ОРУЖИЕ\n \nДает своему владельцу определенные навыки");
- DrawPanelText(g_hInfoPanel, "У каждого такого оружия может быть до 5 уровней");
- DrawPanelText(g_hInfoPanel, "Чем выше уровень одержимого оружия, тем большей силой оно обладает");
- DrawPanelText(g_hInfoPanel, "Если есть одержимый ak47, то в момент покупки обычного ak47 вам предложат его");
- return 0;
- }
- public g_hInfoPanel_CallBack(Handle:menu, MenuAction:action, client, item)
- {
- if (action == MenuAction:4)
- {
- wS_ShowMainMenu(client);
- }
- return 0;
- }
- wS_ShowWeaponListMenu(client, item)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_ShowWeaponListMenu" (number 91)
- public WeaponListMenu_CallBack(Handle:menu, MenuAction:action, client, item)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "WeaponListMenu_CallBack" (number 92)
- wS_ShowBuyPanel(client, WeaponID)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_ShowBuyPanel" (number 93)
- public BuyPanel_CallBack(Handle:panel, MenuAction:action, client, item)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "BuyPanel_CallBack" (number 94)
- public BuyPanelFinish_CallBack(Handle:panel, MenuAction:action, client, item)
- {
- if (action == MenuAction:4)
- {
- wS_ShowInventoryMenu(client);
- wS_PlayMenuSound(client);
- }
- return 0;
- }
- wS_ShowInventoryMenu(client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_ShowInventoryMenu" (number 96)
- public InventoryMenu_CallBack(Handle:menu, MenuAction:action, client, item)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "InventoryMenu_CallBack" (number 97)
- wS_ShowUpgradePanel(client, WeaponID, CurrentLevel)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_ShowUpgradePanel" (number 98)
- public Upgrade_Panel(Handle:panel, MenuAction:action, client, item)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "Upgrade_Panel" (number 99)
- public wS_OnClientChangeWeapon_Post(client, weapon)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_OnClientChangeWeapon_Post" (number 100)
- public Action:wS_OnClientChangeWeapon_Timer(Handle:timer, any:client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_OnClientChangeWeapon_Timer" (number 101)
- wS_ClearAmmoHistory()
- {
- if (g_hAmmoHistoryArray)
- {
- ClearArray(g_hAmmoHistoryArray);
- }
- return 0;
- }
- public Action:OnTakeDamage(victim, &attacker, &inflictor, &Float:damage, &damagetype)
- {
- new var2 = attacker;
- if (MaxClients >= var2 & 0 < var2)
- {
- new var1;
- if (damagetype == 4098 && g_ActiveFeature[attacker][1] > 0)
- {
- damage = damage + damage / 100.0 * float(g_ActiveFeature[attacker][1]);
- return Action:1;
- }
- }
- else
- {
- if (g_ActiveFeature[victim][13])
- {
- return Action:3;
- }
- }
- return Action:0;
- }
- public player_spawn(Handle:event, String:name[], bool:silent)
- {
- new client = GetClientOfUserId(GetEventInt(event, "userid"));
- wS_ClearTimer(g_hFreezeTimer[client]);
- ClientCommand(client, "lastinv");
- return 0;
- }
- public player_hurt(Handle:event, String:name[], bool:silent)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "player_hurt" (number 105)
- wS_TryCreateExplosion(attacker, victim, chance)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "wS_TryCreateExplosion" (number 106)
- public Action:g_hFreezeTimer_CallBack(Handle:timer, any:client)
- {
- g_hFreezeTimer[client] = 0;
- new var1;
- if (IsClientInGame(client) && IsPlayerAlive(client))
- {
- SetEntPropFloat(client, PropType:1, "m_flLaggedMovementValue", 1.0, 0);
- PW_OnClientSettingsChanged_event(client);
- }
- return Action:4;
- }
- wS_TryRegen(client)
- {
- new var1;
- if (g_ActiveFeature[client][7] > 0 && hRegenTimer[client] && GetEntProp(client, PropType:0, "m_iHealth", 4, 0) < 100)
- {
- hRegenTimer[client] = CreateTimer(1.0, hRegenTimer_CallBack, client, 1);
- }
- return 0;
- }
- wS_StopRegen(client)
- {
- wS_ClearTimer(hRegenTimer[client]);
- return 0;
- }
- public Action:hRegenTimer_CallBack(Handle:timer, any:client)
- {
- if (!xD)
- {
- /* ERROR! java.lang.Exception: Can't print expression: Heap */
- function "hRegenTimer_CallBack" (number 110)
- public player_team(Handle:event, String:name[], bool:silent)
- {
- if (GetEventInt(event, "team") < 1)
- {
- new client = GetClientOfUserId(GetEventInt(event, "userid"));
- if (0 < client)
- {
- wS_ClearAura(client);
- }
- }
- return 0;
- }
- public player_death(Handle:event, String:name[], bool:silent)
- {
- wS_ClearAura(GetClientOfUserId(GetEventInt(event, "userid")));
- return 0;
- }
- public round_end(Handle:event, String:name[], bool:silent)
- {
- wS_ClearAmmoHistory();
- return 0;
- }
- wS_UpdateRoundStartMsgVar(Handle:cvar)
- {
- bRoundStartMsg = GetConVarBool(cvar);
- return 0;
- }
- public round_start(Handle:event, String:name[], bool:silent)
- {
- if (bRoundStartMsg)
- {
- PrintToChatAll("\x04%t", "round_start_msg");
- }
- return 0;
- }
- public OnMapStart()
- {
- PrecacheModel("sprites/glow01.spr", true);
- wS_InfoPanel();
- return 0;
- }
- public OnConfigsExecuted()
- {
- wS_LoadSounds();
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement