Raised This Month: $ Target: $400
 0% 

All pev's


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
bwgrubbs1
Senior Member
Join Date: Sep 2006
Old 06-21-2007 , 01:59   Re: All pev's
Reply With Quote #3

actually looking to change someones velocity... when touching an entity...

I have this...

Code:
public client_PreThink(id) {     if(!is_user_alive(id))         return PLUGIN_CONTINUE;     new flags = entity_get_int(id, EV_INT_flags);     if(haslowgrav[id])     {         if(flags & FL_ONGROUND)         {             set_pev(id,pev_gravity,1.0);             haslowgrav[id] = false;             return PLUGIN_CONTINUE;         }     }     if(hasboost[id])     {         if(flags & FL_ONGROUND)         {             set_pev(id,pev_velocity,{1.0, 1.0, 1.0});             hasboost[id] = false;             return PLUGIN_CONTINUE;         }     }     return PLUGIN_CONTINUE; } public fwdTouch(ent, id) {     new Float:velocity[] = {0.0, 128.0, 0.0};     static szClassname[33];     pev(ent, pev_classname, szClassname, 32);     //...     //...     //what I am trying to do with this entity, is...     //when you touch it it will boost you forwards...     //as if you got thrown forward REALLY FAST.     //and when you land on ground you go back to normal.     else if(equali(szClassname, "booster"))     {         set_pev(id,pev_velocity,velocity);         hasboost[id] = true;         return PLUGIN_HANDLED_MAIN;     }     return PLUGIN_HANDLED_MAIN; }

As of now when i touch my entity it just does nothing.
bwgrubbs1 is offline
 



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 21:24.


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