mirror of
https://github.com/rehlds/reapi.git
synced 2024-12-27 23:25:30 +03:00
Add native rg_check_win_conditions (#144)
* Add native rg_check_win_conditions
This commit is contained in:
parent
1a4d3877ef
commit
c1844753ca
@ -837,6 +837,13 @@ native rg_get_iteminfo(const ent, ItemInfo:type, any:...);
|
||||
*/
|
||||
native bool:rg_hint_message(const index, const message[], Float:duration = 6.0, bool:bDisplayIfPlayerDead = false, bool:bOverride = false);
|
||||
|
||||
/*
|
||||
* Instantly check win conditions.
|
||||
*
|
||||
* @noreturn
|
||||
*/
|
||||
native rg_check_win_conditions();
|
||||
|
||||
/*
|
||||
* Instantly initialize player counts.
|
||||
*
|
||||
|
@ -2151,6 +2151,21 @@ cell AMX_NATIVE_CALL rg_hint_message(AMX *amx, cell *params)
|
||||
return pPlayer->CSPlayer()->HintMessageEx(message, args[arg_duration], args[arg_displayIfPlayerDead], args[arg_override]) ? TRUE : FALSE;
|
||||
}
|
||||
|
||||
/*
|
||||
* Instantly check win conditions.
|
||||
*
|
||||
* @noreturn
|
||||
*
|
||||
* native rg_check_win_conditions();
|
||||
*/
|
||||
cell AMX_NATIVE_CALL rg_check_win_conditions(AMX *amx, cell *params)
|
||||
{
|
||||
CHECK_GAMERULES();
|
||||
|
||||
CSGameRules()->CheckWinConditions();
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
/*
|
||||
* Instantly initialize player counts.
|
||||
*
|
||||
@ -2258,6 +2273,7 @@ AMX_NATIVE_INFO Misc_Natives_RG[] =
|
||||
|
||||
{ "rg_hint_message", rg_hint_message },
|
||||
|
||||
{ "rg_check_win_conditions", rg_check_win_conditions },
|
||||
{ "rg_initialize_player_counts", rg_initialize_player_counts },
|
||||
|
||||
{ nullptr, nullptr }
|
||||
|
Loading…
Reference in New Issue
Block a user