RSSy MYGO.pl Opublikowano Listopad 26, 2018 o 10:53 RSSy Udostępnij Opublikowano Listopad 26, 2018 o 10:53 Credits for : twistedeuphoria ( MultiJump Plugin )https://forums.alliedmods.net/showthread.php?t=10159 Plug-in : SoccerJam VIP Plugin Author : Alex Boxer + twistedeuphoria Version : 1.0 Hi everyone im new here :D I "created" a plugin for soccerjam mod - SoccerJam VIP Plugin But i have one bug for this plugin, when i press G for speed boost in soccerjam. When speed boost is done, vip speed return to normal 260 speed.. :D Who can fix it for me plss ? i will add him to credits. Thank you so much. Spoiler #include <amxmodx> #include <amxmisc> #include <fun> #include <hamsandwich> #include <engine> #define VIP ADMIN_LEVEL_B #define PLUGIN "Speed | Gravity" #define VERSION "1.0" #define AUTHOR "Alex Boxer + twistedeuphoria" // -- || Variabil's || -- // new Speed[33], Gravity[33]; new jumpnum[33] = 0 new bool:dojump[33] = false // -- || Cvar's public plugin_init() { register_plugin(PLUGIN, VERSION, "AUTHOR"); //Cvar's register_cvar("amx_maxjumps","1"); register_cvar("amx_mjadminonly","1"); register_event("CurWeapon", "CurrWeapon", "be", "1=1"); RegisterHam( Ham_Spawn, "player", "Spawn", true); // Add your code here... } public Spawn( id ) { if(get_user_flags(id) & VIP) { Speed[id] = true; Gravity[id] = true; CurrWeapon(id); } else { Speed[id] = false; Gravity[id] = false; CurrWeapon(id); } } public CurrWeapon ( id ) { if(Speed[id]) { set_user_maxspeed(id, 280.0); } else { set_user_maxspeed(id, 280.0); } if(Gravity[id]) { set_user_gravity(id, 0.75); } else { set_user_gravity(id, 0.75); } } public client_putinserver(id) { jumpnum[id] = 0 dojump[id] = false } public client_disconnect(id) { jumpnum[id] = 0 dojump[id] = false } public client_PreThink(id) { if(!is_user_alive(id)) return PLUGIN_CONTINUE if(get_cvar_num("amx_mjadminonly") && (!access(id,VIP))) return PLUGIN_CONTINUE new nbut = get_user_button(id) new obut = get_user_oldbutton(id) if((nbut & IN_JUMP) && !(get_entity_flags(id) & FL_ONGROUND) && !(obut & IN_JUMP)) { if(jumpnum[id] < get_cvar_num("amx_maxjumps")) { dojump[id] = true jumpnum[id]++ return PLUGIN_CONTINUE } } if((nbut & IN_JUMP) && (get_entity_flags(id) & FL_ONGROUND)) { jumpnum[id] = 0 return PLUGIN_CONTINUE } return PLUGIN_CONTINUE } public client_PostThink(id) { if(!is_user_alive(id)) return PLUGIN_CONTINUE if(get_cvar_num("amx_mjadminonly") && (!access(id,VIP))) return PLUGIN_CONTINUE if(dojump[id] == true) { new Float:velocity[3] entity_get_vector(id,EV_VEC_velocity,velocity ) velocity[2] = random_float(265.0,285.0) entity_set_vector(id,EV_VEC_velocity,velocity ) dojump[id] = false return PLUGIN_CONTINUE } return PLUGIN_CONTINUE } Attached Files vipsoccerjam.amxx (2.3 KB) Get Plugin or Get Source (vipsoccerjam.sma - 2.3 KB) Wyświetl pełny artykuł Odnośnik do komentarza Udostępnij na innych stronach Więcej opcji udostępniania...
Rekomendowane odpowiedzi
Jeśli chcesz dodać odpowiedź, zaloguj się lub zarejestruj nowe konto
Jedynie zarejestrowani użytkownicy mogą komentować zawartość tej strony.
Zarejestruj nowe konto
Załóż nowe konto. To bardzo proste!
Zarejestruj sięZaloguj się
Posiadasz już konto? Zaloguj się poniżej.
Zaloguj się