Half-Life и Adrenaline Gamer форум http://aghl.ru/forum/ |
|
set ammo endless? http://aghl.ru/forum/viewtopic.php?f=12&t=2549 |
Страница 2 из 3 |
Автор: | Lev [ 21 сен 2016, 21:55 ] |
Заголовок сообщения: | Re: set ammo endless? |
Same as hooking touch, just set 1 for "post" parameter. |
Автор: | abdobiskra [ 06 окт 2017, 15:55 ] |
Заголовок сообщения: | Re: set ammo endless? |
1) i try hooking touch using post parm but the entity does not disappear 2) I try to hide them but disappear and never appear ... so in this case i have to rediscover him but I want her to be in the default setting of the game Код: #include <amxmodx> |
Автор: | Lev [ 06 окт 2017, 22:31 ] |
Заголовок сообщения: | Re: set ammo endless? |
Код: if (!(pev(Entity, pev_effects) & EF_NODRAW) && hl_get_user_bpammo(Id, HLW_RPG) == 5)You should be it reversed way: set to 1 before touch, then player will be able to pickup, after touch (in post) add needed ammo back. |
Автор: | abdobiskra [ 06 окт 2017, 22:57 ] |
Заголовок сообщения: | Re: set ammo endless? |
Did not I really understand that? If you mean like what i do in this code, then exactly what I want is not going to happen because the player's ammunition in this case will remain the same (1). Код: hl_set_user_bpammo(Id, HLW_RPG, 1) |
Автор: | Lev [ 06 окт 2017, 23:56 ] |
Заголовок сообщения: | Re: set ammo endless? |
Код: public ItemTouchFwd( Entity, Id ) |
Автор: | abdobiskra [ 07 окт 2017, 01:24 ] |
Заголовок сообщения: | Re: set ammo endless? |
The idea is understandable But the app does not think I understood how to do it |
Автор: | Lev [ 07 окт 2017, 02:38 ] |
Заголовок сообщения: | Re: set ammo endless? |
Код: && g_RemmberAmmo[Id]You should check this in post. Код: g_RemmberAmmo[Id] -= 1More logical will be to move -=1 under the all ifs. Код: hl_set_user_bpammo(Id, HLW_RPG, g_RemmberAmmo[Id]+1)You added 1 more than needed. Do you actually see your messages on the client? |
Автор: | abdobiskra [ 07 окт 2017, 13:04 ] |
Заголовок сообщения: | Re: set ammo endless? |
The first load of the ammunition gives me a different result but when I get pregnant again gives me a correct result but the same value remains at the load several times in a row which is 3 and i cant see post print msg (debug) Код: public client_putinserver(id) { |
Автор: | Lev [ 07 окт 2017, 17:41 ] |
Заголовок сообщения: | Re: set ammo endless? |
Код: public client_putinserver(id) |
Автор: | abdobiskra [ 07 окт 2017, 18:26 ] |
Заголовок сообщения: | Re: set ammo endless? |
Lev Maybe she is well and she checked with me But the server will explode |
Страница 2 из 3 | Часовой пояс: UTC + 5 часов [ Летнее время ] |
Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |