Raised This Month: $ Target: $400
 0% 

cfg in plugin


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
flye
BANNED
Join Date: May 2007
Old 05-18-2007 , 00:13   cfg in plugin
Reply With Quote #1

i want to learn how to use a cfg in a plugin like
"omg.cfg" will be loded with cvars that i can change.

how do i do this?
flye is offline
_Master_
Senior Member
Join Date: Dec 2006
Old 05-18-2007 , 04:41   Re: cfg in plugin
Reply With Quote #2

PHP Code:
public plugin_cfg(){
    new 
cfgdir[512]

    
get_configsdir(cfgdir511)
    
add(cfgdir511"/omg.cfg")

    if(
file_exists(cfgdir)) server_cmd("exec %s"cfgdir)
    
    
//
    //    ADD EXTRA CONFIG CODE HERE
    //

Config file should be placed in moddir/addons/amxmodx/configs/
_Master_ 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 10:41.


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