spawni
10-17-2014, 09:59
hello,
i want to create a session restore plugin for my own server and need some help. I want to restore the position, angle, kills, etc. of players after they do a retry. How can i realize my idea?
the structure of my array should look like that
1. szSteamid player x
1.1 flPosition
1.2 flAngle
1.3 iKills
..
2. szSteamid player x
2.1 flPosition
2.2 flAngle
2.3 iKills
..
etc.
My first thoughts:
- global handle xxx which will be used as adt array
- enum with subitems like position, angle, ..
- pluginstart: xxx = CreateArray(???);
- onmapstart: cleararray(xxx)
- onadmincheck: go through the array and check whether the array contains his steamid (if yes then restore his stats etc.)
- 1sec timer: save client data like position?
thx 4 help
i want to create a session restore plugin for my own server and need some help. I want to restore the position, angle, kills, etc. of players after they do a retry. How can i realize my idea?
the structure of my array should look like that
1. szSteamid player x
1.1 flPosition
1.2 flAngle
1.3 iKills
..
2. szSteamid player x
2.1 flPosition
2.2 flAngle
2.3 iKills
..
etc.
My first thoughts:
- global handle xxx which will be used as adt array
- enum with subitems like position, angle, ..
- pluginstart: xxx = CreateArray(???);
- onmapstart: cleararray(xxx)
- onadmincheck: go through the array and check whether the array contains his steamid (if yes then restore his stats etc.)
- 1sec timer: save client data like position?
thx 4 help