Handle g_hTimer;
/* в шапку плагина */
bool g_bVariable;
Handle g_hTimer;
/* в паблик OnPluginStart() */
HookEvent("round_start", Event_Start, EventHookMode_PostNoCopy);
HookEvent("round_end", Event_End, EventHookMode_PostNoCopy);
/* там где раунд начинается, если нет добавить */
public void Event_Start(Event event, const char[] name, bool dontBroadcast)
{
g_hTimer = CreateTimer(5.0, _Timer, _, TIMER_FLAG_NO_MAPCHANGE);
}
/* там где раунд заканчивается, если нет добавить */
public void Event_End(Event event, const char[] name, bool dontBroadcast)
{
g_bVariable = false;
}
/* в тело плагина */
public Action _Timer(Handle timer)
{
g_hTimer = null;
g_bVariable = true;
return Plugin_Stop;
}
/* с заменой */
public Action OnPlayerRunCmd(int iClient, int &iButtons, int &iImpulse) // float vel[3], float fAngles[3], int &iWeapon)
{
if (g_bVariable && IsClientInGame(iClient) && IsPlayerAlive(iClient) && g_bUseBhop[iClient] && iButtons & IN_JUMP && !(GetEntityMoveType(iClient) & MOVETYPE_LADDER) && !(GetEntityFlags(iClient) & FL_ONGROUND))
{
iButtons &= ~IN_JUMP;
}
return Plugin_Continue;
}
При компиляции укажи цены (можно в sp файле, можно в cfg) могу ещё кинуть и cfg. А так если не помогло то незнаю. Ты кинь хотя бы логи.
я уже успел разобраться. Но все же, благодарю, что отозвался:-)При компиляции укажи цены (можно в sp файле, можно в cfg) могу ещё кинуть и cfg. А так если не помогло то незнаю. Ты кинь хотя бы логи.
Ошибка осталась. Даже с ценами.я уже успел разобраться. Но все же, благодарю, что отозвался:-)
L 04/13/2022 - 21:40:42: SourceMod error session started
L 04/13/2022 - 21:40:42: Info (map "mg_zeizeiii_2easy") (file "C:\games\servers\css_v90\cstrike\addons\sourcemod\logs\errors_20220413.log")
L 04/13/2022 - 21:40:42: [SM] Unable to load plugin "shop_ball.smx": Could not find required plugin "shop"
L 04/13/2022 - 21:40:43: [SM] Unable to load plugin "shop_HighOrLow.smx": Could not find required plugin "shop"
L 04/13/2022 - 21:40:43: [SM] Unable to load plugin "shop_parachute.smx": Could not find required plugin "shop"
L 04/13/2022 - 21:40:43: [SM] Unable to load plugin "shop_weapon_colors.smx": Could not find required plugin "shop"
L 04/13/2022 - 21:41:18: SourceMod error session started
L 04/13/2022 - 21:41:18: Info (map "mg_zeizeiii_2easy") (file "C:\games\servers\css_v90\cstrike\addons\sourcemod\logs\errors_20220413.log")
L 04/13/2022 - 21:41:18: [shop.smx] DB_ErrorCheck: no such table: shop_players
L 04/13/2022 - 21:41:18: [shop.smx] DB_UgradeState_1: no such table: shop_items
L 04/13/2022 - 22:11:21: SourceMod error session started
L 04/13/2022 - 22:11:21: Info (map "mg_zeizeiii_2easy") (file "C:\games\servers\css_v90\cstrike\addons\sourcemod\logs\errors_20220413.log")
L 04/13/2022 - 22:11:21: Failed to auto generate config for shop_HighOrLow.smx, make sure the directory has write permission.
L 04/13/2022 - 22:12:12: SourceMod error session started
L 04/13/2022 - 22:12:12: Info (map "mg_zeizeiii_2easy") (file "C:\games\servers\css_v90\cstrike\addons\sourcemod\logs\errors_20220413.log")
L 04/13/2022 - 22:12:12: Failed to auto generate config for shop_HighOrLow.smx, make sure the directory has write permission.
L 04/13/2022 - 22:13:15: SourceMod error session started
L 04/13/2022 - 22:13:15: Info (map "mg_zeizeiii_2easy") (file "C:\games\servers\css_v90\cstrike\addons\sourcemod\logs\errors_20220413.log")
L 04/13/2022 - 22:13:15: Failed to auto generate config for shop_HighOrLow.smx, make sure the directory has write permission.
L 04/13/2022 - 22:47:25: SourceMod error session started
L 04/13/2022 - 22:47:25: Info (map "mg_zeizeiii_2easy") (file "C:\games\servers\css_v90\cstrike\addons\sourcemod\logs\errors_20220413.log")
L 04/13/2022 - 22:47:25: Failed to auto generate config for shop_HighOrLow.smx, make sure the directory has write permission.
L 04/13/2022 - 22:49:08: SourceMod error session started
L 04/13/2022 - 22:49:08: Info (map "mg_zeizeiii_2easy") (file "C:\games\servers\css_v90\cstrike\addons\sourcemod\logs\errors_20220413.log")
L 04/13/2022 - 22:49:08: Failed to auto generate config for shop_HighOrLow.smx, make sure the directory has write permission.
плагин компилируешь хоть?почему нету кфг? как установить цену, в .sp ставлю не помогает
ошибку выдает при компиляцииплагин компилируешь хоть?
плагин компилируешь хоть?
ну если не читать ошибки, то ясен пень непонятно что делать)
сам исходник редактируй, cfg нетуНе могу найти кфг под этот плагин где он находится?
cfg/sourcemod/shop_bhop.cfgНе могу найти кфг под этот плагин где он находится?
// This file was auto-generated by SourceMod (v1.11.0.6919)
// ConVars for plugin "shop\shop_bhop.smx"
// Цена покупки.
// -
// Default: "450"
// Minimum: "0.000000"
sm_shop_bhop_price "500000"
// Цена продажи.
// -
// Default: "200"
// Minimum: "0.000000"
sm_shop_bhop_sell_price "200"
// Время действия покупки в секундах.
// -
// Default: "86400"
// Minimum: "0.000000"
sm_shop_bhop_time "0"
в исходнике .spпоставил плагин, он работает, в шопе есть, да и так просто если купить, то тоже есть, но при это не создаётся кфг(из за этого я не могу изменить цену). не подскажете, как это решить?