#ifndef CL_PLAYER_H #define CL_PLAYER_H .entity pusher; .float pushltime; .float istypefrag; .float CopyBody_nextthink; .void() CopyBody_think; void CopyBody_Think(); void CopyBody(float keepvelocity); void player_setupanimsformodel(); void player_anim(); void PlayerCorpseDamage(entity inflictor, entity attacker, float damage, int deathtype, vector hitloc, vector force); // g__str: // If 0, default is used. // If <0, 0 is used. // Otherwise, g_str (default value) is used. // For consistency, negative values there are mapped to zero too. #define GAMETYPE_DEFAULTED_SETTING(str) \ ((gametype_setting_tmp = cvar(strcat("g_", GetGametype(), "_" #str))), \ (gametype_setting_tmp < 0) ? 0 \ : (gametype_setting_tmp == 0 || autocvar_g_respawn_delay_forced) ? max(0, autocvar_g_##str) \ : gametype_setting_tmp) void calculate_player_respawn_time(); void ClientKill_Now_TeamChange(); void MoveToTeam(entity client, float team_colour, float type); void PlayerDamage(entity inflictor, entity attacker, float damage, int deathtype, vector hitloc, vector force); /** to be used by `prvm_edictset server playernumber muted 1` */ .float muted; int Say(entity source, float teamsay, entity privatesay, string msgin, float floodcontrol); // player sounds, voice messages // TODO implemented fall and falling #define ALLPLAYERSOUNDS(X) \ X(death) \ X(drown) \ X(fall) \ X(falling) \ X(gasp) \ X(jump) \ X(pain100) \ X(pain25) \ X(pain50) \ X(pain75) #define ALLVOICEMSGS(X) \ X(attack) \ X(attackinfive) \ X(coverme) \ X(defend) \ X(freelance) \ X(incoming) \ X(meet) \ X(needhelp) \ X(seenflag) \ X(taunt) \ X(teamshoot) // reserved sound names for the future (some models lack sounds for them): // _VOICEMSG(flagcarriertakingdamage) // _VOICEMSG(getflag) // reserved sound names for the future (ALL models lack sounds for them): // _VOICEMSG(affirmative) // _VOICEMSG(attacking) // _VOICEMSG(defending) // _VOICEMSG(roaming) // _VOICEMSG(onmyway) // _VOICEMSG(droppedflag) // _VOICEMSG(negative) // _VOICEMSG(seenenemy) #define X(m) .string playersound_##m; ALLPLAYERSOUNDS(X) ALLVOICEMSGS(X) #undef X bool GetPlayerSoundSampleField_notFound; float GetVoiceMessageVoiceType(string type); .string GetVoiceMessageSampleField(string type); .string GetPlayerSoundSampleField(string type); void PrecacheGlobalSound(string samplestring); void PrecachePlayerSounds(string f); void ClearPlayerSounds(entity this); float LoadPlayerSounds(string f, bool strict); void UpdatePlayerSounds(entity this); void FakeGlobalSound(string sample, float chan, float voicetype); void GlobalSound(string sample, float chan, float voicetype); void PlayerSound(.string samplefield, float chan, float voicetype); void VoiceMessage(string type, string msg); #endif