Raised This Month: $ Target: $400
 0% 

Gravity Plugin Help Please!


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 01-13-2009 , 14:53   Re: Gravity Plugin Help Please!
Reply With Quote #1

Code:
#include <amxmodx> #include <amxmisc> #include <fakemeta> new bool:g_give_gravity; new bool:g_alive[33]; new g_max_clients; public plugin_init() {     register_event("ResetHUD", "EventResetHud", "be");     register_event("DeathMsg", "EventDeathMsg", "a");         register_logevent("EventRoundStart", 2, "1=Round_Start");         register_forward(FM_PlayerPreThink, "FwdPlayerPreThink");         g_max_clients = get_maxplayers(); } public client_disconnect(client) {     g_alive[client] = false; } public EventResetHud(client) {     g_alive[client] = bool:is_user_alive(client); } public EventDeathMsg() {     g_alive[read_data(2)] = false; } public EventRoundStart() {     g_give_gravity = true;         remove_task(112233);     set_task(5.0, "TaskRemoveGravity", 112233); } public FwdPlayerPreThink(client) {     if( g_give_gravity && g_alive[client] )     {         set_pev(client, pev_gravity, 0.4);     } } public TaskRemoveGravity() {     g_give_gravity = false;         for( new client = 1; client <= g_max_clients; client++ )     {         if( g_alive[client] )         {             set_pev(client, pev_gravity, 0.1);         }     } }
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:52.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode