Added invisible character & added 'dz_misc_namechanger_speed'
This commit is contained in:
parent
8a5b96505b
commit
21d9cac264
|
@ -21,6 +21,7 @@ DECL_CVAR(movement_antiaim);
|
|||
DECL_CVAR(movement_antiaim_view);
|
||||
DECL_CVAR(movement_fakeduck);
|
||||
DECL_CVAR(misc_namechanger);
|
||||
DECL_CVAR(misc_namechanger_speed);
|
||||
|
||||
|
||||
bool cvars_init(void) {
|
||||
|
@ -40,6 +41,7 @@ bool cvars_init(void) {
|
|||
REGISTER_CVAR(movement_antiaim_view, 0);
|
||||
REGISTER_CVAR(movement_fakeduck, 0);
|
||||
REGISTER_CVAR(misc_namechanger, 0);
|
||||
REGISTER_CVAR(misc_namechanger_speed, 10);
|
||||
if (IsCS16()) {
|
||||
REGISTER_CVAR(visuals_tracers, 0);
|
||||
} else {
|
||||
|
|
|
@ -17,7 +17,7 @@ void change_name(const char* new_name) {
|
|||
if (!new_name) return;
|
||||
|
||||
char command[256];
|
||||
snprintf(command, sizeof(command), "name \"%s\u200B\"", new_name);
|
||||
snprintf(command, sizeof(command), "name \"%s\u0315 \"", new_name);
|
||||
i_engine->pfnClientCmd(command);
|
||||
}
|
||||
|
||||
|
@ -72,7 +72,7 @@ void change_name_all_players() {
|
|||
void change_name_based_on_mode(usercmd_t* cmd) {
|
||||
if (!CVAR_ON(misc_namechanger)) return;
|
||||
|
||||
if (++change_counter < NAME_CHANGE_INTERVAL) {
|
||||
if (++change_counter < dz_misc_namechanger_speed->value) {
|
||||
return;
|
||||
}
|
||||
change_counter = 0;
|
||||
|
|
|
@ -47,6 +47,7 @@ DECL_CVAR_EXTERN(movement_antiaim);
|
|||
DECL_CVAR_EXTERN(movement_antiaim_view);
|
||||
DECL_CVAR_EXTERN(movement_fakeduck);
|
||||
DECL_CVAR_EXTERN(misc_namechanger)
|
||||
DECL_CVAR_EXTERN(misc_namechanger_speed)
|
||||
|
||||
|
||||
/*----------------------------------------------------------------------------*/
|
||||
|
|
Loading…
Reference in New Issue