http://forums.alliedmods.net/showpost.php?p=1145843&postcount=4">http://forums.alliedmods.net/showpost.p ... ostcount=4</a> wäre schon mal die funktion bei SM
edit: hab damit gerade mal etwas rumgespielt, und
CHL2_Player sollte
CBasePlayer sein, damit funktioniert es jedenfalls.
so siehts bei mir aus
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
|
public Action:SetAmmo(Handle:timer, any:client)
{
new offset = FindSendPropInfo("CBasePlayer", "m_iAmmo");
for (new i = 0; i <= 10; i++)
{
SetEntData(client, offset+(i*4), GetConVarInt(r_size));
}
CloseHandle(timer);
}
|
(vorher muss natürlich noch
client und
r_size definiert werden)
nu muss man noch eine action rausfinden bei diesem das auffüllen getriggert wird. player_spawn und nach weapon buy würde glaube ich sinn machen.