mirror of
https://github.com/shavitush/bhoptimer.git
synced 2025-12-07 10:28:26 +00:00
add dumb shavit_misc_resettargetname_main and shavit_misc_resettargetname_bonus
This commit is contained in:
parent
c873f218a6
commit
d112d3dbd0
@ -7,7 +7,7 @@
|
||||
}
|
||||
"bhop_downtown"
|
||||
{
|
||||
"shavit_misc_resettargetname" "0"
|
||||
"shavit_misc_resettargetname_main" "fil_fw"
|
||||
}
|
||||
"bhop_microwave"
|
||||
{
|
||||
@ -15,11 +15,17 @@
|
||||
}
|
||||
"bhop_overthinker"
|
||||
{
|
||||
"shavit_misc_resettargetname" "0"
|
||||
"shavit_misc_resettargetname_main" "noobinside"
|
||||
"shavit_misc_resettargetname_bonus" "filter_bonus"
|
||||
}
|
||||
"bhop_overthinker_go"
|
||||
{
|
||||
"shavit_misc_resettargetname" "0"
|
||||
"shavit_misc_resettargetname_main" "noobinside"
|
||||
"shavit_misc_resettargetname_bonus" "filter_bonus"
|
||||
}
|
||||
"bhop_shutdown"
|
||||
{
|
||||
"shavit_misc_resettargetname_main" "asdf"
|
||||
}
|
||||
"bhop_tranquility"
|
||||
{
|
||||
|
||||
@ -122,6 +122,8 @@ Convar gCV_RemoveRagdolls = null;
|
||||
Convar gCV_ClanTag = null;
|
||||
Convar gCV_DropAll = null;
|
||||
Convar gCV_ResetTargetname = null;
|
||||
Convar gCV_ResetTargetnameMain = null;
|
||||
Convar gCV_ResetTargetnameBonus = null;
|
||||
Convar gCV_RestoreStates = null;
|
||||
Convar gCV_JointeamHook = null;
|
||||
Convar gCV_SpectatorList = null;
|
||||
@ -320,6 +322,8 @@ public void OnPluginStart()
|
||||
gCV_ClanTag = new Convar("shavit_misc_clantag", "{tr}{styletag} :: {time}", "Custom clantag for players.\n0 - Disabled\n{styletag} - style tag.\n{style} - style name.\n{time} - formatted time.\n{tr} - first letter of track.\n{rank} - player rank.\n{cr} - player's chatrank from shavit-chat, trimmed, with no colors", 0);
|
||||
gCV_DropAll = new Convar("shavit_misc_dropall", "1", "Allow all weapons to be dropped?\n0 - Disabled\n1 - Enabled", 0, true, 0.0, true, 1.0);
|
||||
gCV_ResetTargetname = new Convar("shavit_misc_resettargetname", "1", "Reset the player's targetname and eventqueue upon timer start?\n0 - Disabled\n1 - Enabled", 0, true, 0.0, true, 1.0);
|
||||
gCV_ResetTargetnameMain = new Convar("shavit_misc_resettargetname_main", "", "What targetname to use when resetting the player. You don't need to touch this");
|
||||
gCV_ResetTargetnameBonus = new Convar("shavit_misc_resettargetname_bonus", "", "What targetname to use when resetting the player (on bonus tracks). You don't need to touch this");
|
||||
gCV_RestoreStates = new Convar("shavit_misc_restorestates", "1", "Save the players' timer/position etc.. when they die/change teams,\nand load the data when they spawn?\n0 - Disabled\n1 - Enabled", 0, true, 0.0, true, 1.0);
|
||||
gCV_JointeamHook = new Convar("shavit_misc_jointeamhook", "1", "Hook `jointeam`?\n0 - Disabled\n1 - Enabled, players can instantly change teams.", 0, true, 0.0, true, 1.0);
|
||||
gCV_SpectatorList = new Convar("shavit_misc_speclist", "1", "Who to show in !specs?\n0 - everyone\n1 - all admins (admin_speclisthide override to bypass)\n2 - players you can target", 0, true, 0.0, true, 2.0);
|
||||
@ -3165,7 +3169,18 @@ public Action Shavit_OnStart(int client)
|
||||
|
||||
if(gCV_ResetTargetname.BoolValue)
|
||||
{
|
||||
DispatchKeyValue(client, "targetname", "");
|
||||
char targetname[64];
|
||||
|
||||
if (Shavit_GetClientTrack(client) == Track_Main)
|
||||
{
|
||||
gCV_ResetTargetnameMain.GetString(targetname, sizeof(targetname));
|
||||
}
|
||||
else
|
||||
{
|
||||
gCV_ResetTargetnameBonus.GetString(targetname, sizeof(targetname));
|
||||
}
|
||||
|
||||
DispatchKeyValue(client, "targetname", targetname);
|
||||
SetEntPropString(client, Prop_Data, "m_iClassname", "player");
|
||||
|
||||
// Used to clear some (mainly basevelocity) events that can be used to boost out of the start zone.
|
||||
|
||||
Loading…
Reference in New Issue
Block a user