Raised This Month: $ Target: $400
 0% 

do any 1 have guide how to make plugins ?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Damir
Member
Join Date: Jul 2006
Old 02-28-2007 , 16:37   do any 1 have guide how to make plugins ?
Reply With Quote #1

do any 1 have guide how to make plugins ?
sorry bad english...
Damir is offline
Martin1
BANNED
Join Date: May 2006
Old 02-28-2007 , 18:27   Re: do any 1 have guide how to make plugins ?
Reply With Quote #2

scripting isnīt something like riding a bike, its more of a way of thinking, you need to start learning functions, start reading other plugins and such. Look at scripting help and so on
Martin1 is offline
FormulaZero
BANNED
Join Date: Feb 2007
Location: Sector 7G
Old 02-28-2007 , 18:45   Re: do any 1 have guide how to make plugins ?
Reply With Quote #3

Yes, here if you can read and understand this you can script, use the search plugin for ideas and such, at the bottom of some plugin theres something that says: Get Source. This, downloads the code for the plugin you have selected; go to AMXX-Studio and open the file, this will give you the code to that certain plugin. Theres characters like: <, ;, " ", (id) in plugins, You can't rip codes either you'll be banned. If you can read this and understand, you can call yourself a Starting Scripter:
PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <fun>

#define PLUGIN "Regain Armor"
#define VERSION "0.5"
#define AUTHOR "FormulaZero"

new p_ArmorBack
new p_HealthBack

public plugin_init() 
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
register_clcmd("say /armor","armorback",_,"Gives the client their armor back.")
    
register_clcmd("say /health","healthback",_,"Gives the client their health back.")
    
register_event("Damage","armorback","be")
    
register_event("Damage","healthback","be")
    
    new 
Cvar[] = "amx_armorback"
    
register_cvar(Cvar,"50")
    
p_ArmorBack get_cvar_pointer(Cvar)
}

public 
armorback(id)
{
    if(!
is_user_alive(id))
        return
    
    if(
get_user_armor(id) < 1)
        
set_user_armor(id,clamp(get_pcvar_num(p_ArmorBack),0,100))

SOURCE: By me.
FormulaZero is offline
schnitzelmaker
Senior Member
Join Date: Apr 2006
Location: HERE
Old 03-01-2007 , 03:35   Re: do any 1 have guide how to make plugins ?
Reply With Quote #4

http://wiki.amxmodx.org/index.php/Pawn_Tutorial

The best is learning the basics and look inside little plugins how they work.

To understand which function what do, is this helpfull:http://www.amxmodx.org/funcwiki.php
__________________
schnitzelmaker is offline
FormulaZero
BANNED
Join Date: Feb 2007
Location: Sector 7G
Old 03-01-2007 , 06:36   Re: do any 1 have guide how to make plugins ?
Reply With Quote #5

allways in plugins you need to add:
#includes, #defines are optional but #include is allways needed.
EXAMPLE: If you were making a plugin about TFC Weapon you would:
PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <tfcx> 
<--
PHP Code:
#include <fun> 
might need to be added depending on what you add to your plugin. PM me if you need some help on things ;)
FormulaZero 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 00:37.


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