Raised This Month: $ Target: $400
 0% 

Read users.ini and list on motd. *Need Help*


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 04-25-2011 , 08:33   Read users.ini and list on motd. *Need Help*
Reply With Quote #1

Hi.

Like a title say i want a create such plugin like admin/vip list on motd.
It is first time when i try to load .ini file

I was try to make this.
Lets look my code now
PHP Code:
 
#include <amxmodx>
#include <amxmisc>
#define PLUGIN  "Users list on motd"
#define VERSION "1.0"
#define AUTHOR  "Dare-Devil - This man need somehelp :)"
public plugin_precache()
{
 
register_plugin(PLUGINVERSIONAUTHOR)
 static 
configsdir[32]
 
get_configsdir(configsdir31)
 static 
file[64]
 
formatex(file63"%s/users.ini"configsdir)
 new 
line 0length 0
 
static users[64], flags[32]
 while(
read_file(fileline++, text127length)) 
 {
  if((
text[0] == ';') || !length)
   continue
 
// And what is a next ( ? )
}
public 
plugin_init()
{
 
register_clcmd("say /adminlist""show_admin_or_vip_list")
}
public 
show_admin_or_vip_list(id)
{
 
format_motd_admin(g_sBuffer)
 
show_motd(idg_sBuffer"Admin or Vip List")
 
 return 
PLUGIN_CONTINUE
}
format_motd_admin(sBuffer[MAX_BUFFER_LENGTH 1])
{
 new 
izList[8], izBody[8]
 new 
iLen 0
 
new ladminname[16], ladminflag[16],
 
format(ladminnames15"%L"LANG_SERVER"LANG_ADMINNAME")
 
format(lladminflag15"%L"LANG_SERVER"LANG_ADMINFLAG")
 
// And somehelp here please :) 
Like you see i dont know now how to continue, I would be very grateful if someone help me.
.Dare Devil. is offline
 


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 19:52.


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