Raised This Month: $32 Target: $400
 8% 

[INC] ESF UTIL


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
tuty
Veteran Member
Join Date: Jul 2008
Location: UK
Old 03-28-2009 , 11:53   [INC] ESF UTIL
Reply With Quote #1


ESF UTIL

I made a update for http://forums.alliedmods.net/showthr...ght=esf_stocks
I added more stocks yay !!
More info about stocks, inside of INC file ~


This include contain :

- ESF Weapon ID's
- And some usefull stocks


The stocks are:

esf_get_ki( index );
esf_set_ki( index, 1000 );
esf_get_powerlevel( index );
esf_set_powerlevel( index, 940000 );
esf_get_acpl( index );
esf_set_acpl( index, 940000 );
esf_get_maxhealth( index );
esf_set_maxhealth( index, 1000 );
esf_get_player_class( index );
esf_set_speed( index, speed );
esf_get_speed( index );
esf_set_swoopspeed( index, speed );
esf_get_swoopspeed( index );
esf_get_fly( index );
esf_get_turbo( index );
esf_get_powerup( index );
esf_get_swooping( index );
esf_get_attack_charge( index );
esf_get_advancedmelee( index );
esf_get_block( index );
esf_get_throw( index );
esf_get_user_deaths( index );
esf_get_team( index );



The weapons ID's are:

ESFW_NONE

ESFW_MELEE
ESFW_SWORD
ESFW_KIBLAST
ESFW_GENERICBEAM
ESFW_GALLITGUN
ESFW_KAMEHAMEHA
ESFW_DESTRUCTODISC
ESFW_SOLARFLARE
ESFW_EYELASER
ESFW_FRIEZADISC
ESFW_SPECIALBEAMCANNON
ESFW_SPIRITBOMB
ESFW_BIGBANG
ESFW_FINGERLASER
ESFW_FINALFLASH
ESFW_MASENKO
ESFW_DEATHBALL
ESFW_BURNINGATTACK
ESFW_SCATTERBEAM
ESFW_CANDY
ESFW_SCATTERSHOT
ESFW_POWERBEAM
ESFW_MOUTHBLAST
ESFW_FINISHINGBUSTER
ESFW_SENSU
ESFW_DRAGONBALL
ESFW_BODYPART
ESFW_SHIELDATTACK
ESFW_REGENERATION
ESFW_RENZOKU
ESFW_KAMETORPEDO
ESFW_TELEKINESIS
ESFW_FLAMETHROWER




Added ESF Weapon Names in /* */:

PHP Code:
/*
"weapon_melee"            
"weapon_sword"            
"weapon_kiblast"        
"weapon_genericbeam"         
"weapon_gallitgun"        
"weapon_kamehameha"        
"weapon_destructodisc"        
"weapon_solarflare"        
"weapon_eyelaser"    
"weapon_friezadisc"        
"weapon_specialbeamcannon"    
"weapon_spiritbomb"        
"weapon_bigbang"        
"weapon_fingerlaser"        
"weapon_finalflash"        
"weapon_masenko"        
"weapon_deathball"        
"weapon_burningattack"        
"weapon_scatterbeam"            
"weapon_candy"            
"weapon_scattershot"        
"weapon_powerbeam"        
"weapon_mouthblast"        
"weapon_finishingbuster"    
"weapon_sensu"            
"weapon_dragonball"        
"weapon_bodypart"    
"weapon_shieldattack"        
"weapon_regeneration"        
"weapon_renzoku"        
"weapon_kametorpedo"        
"weapon_telekinesis"        
"weapon_flamethrower"
*/ 

Attached Files
File Type: inc esf_util.inc (11.5 KB, 457 views)
__________________

Last edited by tuty; 04-14-2009 at 08:17.
tuty is offline
Send a message via ICQ to tuty Send a message via AIM to tuty
tuty
Veteran Member
Join Date: Jul 2008
Location: UK
Old 03-29-2009 , 02:21   Re: [INC] ESF UTIL
Reply With Quote #2

nobody nothing?
__________________
tuty is offline
Send a message via ICQ to tuty Send a message via AIM to tuty
ot_207
Veteran Member
Join Date: Jan 2008
Location: Romania The Love Country
Old 03-29-2009 , 08:05   Re: [INC] ESF UTIL
Reply With Quote #3

Quote:
Originally Posted by tuty View Post
nobody nothing?
I'm not familliar with ESF but I hope that your effort will be apreciated! .
And be patient, someone will soon see this .
__________________
My approved plug-ins | Good for newbies! | Problems?

Back, will come around when I have time.
ot_207 is offline
anakin_cstrike
Veteran Member
Join Date: Nov 2007
Location: Romania
Old 03-29-2009 , 11:07   Re: [INC] ESF UTIL
Reply With Quote #4

Code:
/*************************************** |                        | |   Set KI to a player                   | |   Note: if you set KI over 1000,      | |   the KI box will have a bigger width | |   How to use: esf_set_ki( id , 250 )  | |                    | ****************************************/ stock esf_set_ki( index, value ) {     set_pev( id, pev_fuser4, float( value ) ); } /******************************************* |                            | |     Set PowerLevel to a player            | |     How to use:                     | |     esf_set_powerlevel( id , 60.000.000 ) | |                          | ********************************************/ stock esf_set_powerlevel( index, thp ) {     set_pdata_int( index, 460, thp ); } /**************************************** |                         | |   Return PowerLevel from a player     | |   How to use: esf_get_powerlevel( id ) | |                     | *****************************************/ stock esf_get_powerlevel( index ) {     return get_pdata_int( index, 460 ); } /***************************************** |                          | |   Return ActualPowerLevel from a player | |   How to use: esf_get_acpl( id )        | |                      | ******************************************/ stock esf_get_acpl( index ) {     return get_pdata_int( index, 463 ); } /*********************************************** |                                | |   Get the player model                | |   How to use: esf_get_model( id, model, len )    | |                            | ************************************************/ stock esf_get_model( index, model[], len ) {     engfunc( EngFunc_InfoKeyValue, engfunc( EngFunc_GetInfoKeyBuffer, index ), "model", model, len ); }
Use a macro for all of these.
__________________

anakin_cstrike is offline
ot_207
Veteran Member
Join Date: Jan 2008
Location: Romania The Love Country
Old 03-29-2009 , 11:24   Re: [INC] ESF UTIL
Reply With Quote #5

Good suggestion anakin.

PHP Code:
stock esf_set_kiindexvalue )
{
    
set_pevidpev_fuser4floatvalue ) );

Here is an example on how to do a macro:
PHP Code:
#define esf_set_ki(%1,%2) set_pev( %1, pev_fuser4, float( %2 ) ) 
__________________
My approved plug-ins | Good for newbies! | Problems?

Back, will come around when I have time.
ot_207 is offline
tuty
Veteran Member
Join Date: Jul 2008
Location: UK
Old 03-29-2009 , 12:06   Re: [INC] ESF UTIL
Reply With Quote #6

ok.. thanks for suggestions
__________________
tuty is offline
Send a message via ICQ to tuty Send a message via AIM to tuty
anakin_cstrike
Veteran Member
Join Date: Nov 2007
Location: Romania
Old 03-29-2009 , 13:08   Re: [INC] ESF UTIL
Reply With Quote #7

Just avoid to use return where you can, it's useless here.
__________________

anakin_cstrike is offline
tuty
Veteran Member
Join Date: Jul 2008
Location: UK
Old 03-31-2009 , 11:57   Re: [INC] ESF UTIL
Reply With Quote #8

UPDATED! Added more stocks
__________________
tuty is offline
Send a message via ICQ to tuty Send a message via AIM to tuty
Spunky
Senior Member
Join Date: May 2008
Location: Orlando, Fl.
Old 04-07-2009 , 23:57   Re: [INC] ESF UTIL
Reply With Quote #9

Maybe add esf_get_team()? Would be useful.
Spunky is offline
Send a message via AIM to Spunky
hleV
Veteran Member
Join Date: Mar 2007
Location: Lithuania
Old 04-08-2009 , 06:55   Re: [INC] ESF UTIL
Reply With Quote #10

About ESF class. Why you use code from ECX? Why not just..:
Code:
enum {         CLASS_NONE,           CLASS_BUU,         CLASS_GOKU,         CLASS_GOHAN,         CLASS_KRILLIN,         CLASS_FRIEZA,         CLASS_PICCOLO,         CLASS_TRUNKS,         CLASS_VEGETA,         CLASS_CELL };   #define esf_get_player_class(%1) return pev(%1, pev_playerclass);   /* // Usage // If/else new iClass = esf_get_player_class(iClient);   if (iClass == CLASS_NONE) {         // Player is spectator/unassigned } else if (iClass == CLASS_VEGETA) {         // Player is Vegeta }   // Switch switch (esf_get_player_class(iClient)) {         case CLASS_NONE: return;         case CLASS_GOKU, CLASS_GOHAN, CLASS_TRUNKS, CLASS_VEGETA:         {                 // Player is a saiyan         }           default:         {                 // Player is not a saiyan         } }
__________________
hleV is offline
Reply


Thread Tools
Display Modes

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 15:50.


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