MohFill Fix 2.0 (must have for AA server owners)

Started by Elgan {sfx}, May 08, 2006, 11:58:14 PM

Previous topic - Next topic

Rookie One

That's very interesting. Unfortunately I don't really have any means of testing different than localhost, some bugs may go unnoticed. I'll try and debug the ClientConnect function, maybe I'll trace the thing down.

   

   And besides, don't set logfile to 1, but to 2 or 3. 1 will set the log to be buffered and written out only at game exit, which means it won't be written if the game crashes.

   

   Runt, that's a weird thing. Will look into it.

   

   I suppose there are a lot of bugs lurking in all the stricmp code, the order of the arguments makes a HUGE difference.
here's my stuff - inequation.org | here's where I work - thefarm51.com

Elgan {sfx}

those who said with my fgameded.so, the admin mod didnt work. did u by any chance notice if it said didnt find admin.cfg etc

   

   did u place the admin.ini in main or in the mohaa dir?

   

   try both

   

   

   
       admincount=0;
       FILE *fp = fopen( "mainadmins.ini", "rt" );
       if ( !fp ) {
           gi.Printf("Could not open.admins.cfg");
           return;
       }
   
   

Rookie One

Whoa, that's a bug, it searches for admins.ini but prints it can't find admins.cfg. :P

   

   <EDIT>Elg!!! It just occured to me:

   
FILE *fp = fopen( "mainipfilter.cfg", "rt" );

   Linux uses the forward slash instead of backwards! This might be it! :) I'll have a new fgameded.so tomorrow. :)

   I also figured that using the Quake 3 implementation of stricmp might not be the wisest idea. Also, glibc has a function that works exactly the same - strcasecmp. Made an #ifdef to #define the appropriate function instead. :)</EDIT>
here's my stuff - inequation.org | here's where I work - thefarm51.com

Elgan {sfx}

i already said define stricmp strcasecmp. and i meant the / as well as the ini, i was doing a nerw dll to test since i posted this, yes, was hours ago, but fucking webcams.lol

Elgan {sfx}

75-mohfix 2.0 (linux).rar

   

   can some ppl please try this ? it works FINE on my local, connected. no crash map, admin stuff loads. However on remote prostock server , the server crashes when someone tried to join. strange.

DanJ

I'm sorry guys I couldn't get the server to log :( I have been trying all day.

   However i will give that a try.

DanJ

Crashes whilst trying to connect.

   

   /home/MOHAA4/chatfilter.cfg

   /home/MOHAA4/ipfilter.cfg

   /home/MOHAA4/namefilter.cfg

   /home/MOHAA4/fgameded.so

   /home/MOHAA4/fgamededmohaa.so

   /home/MOHAA4/mohaa_Indexed

   /home/MOHAA4/main/admins.ini

   

   Inside admin.ini

   
// Rights:
   //
   // 1 = Protected name, can view status
   // admin_status
   //
   // any admin level can use admin_status.
   //
   // 2 = Can Change Maps.
   // admin_map <map>
   //
   // 4 = Can restart map.
   // admin_restart
   //
   // 8 = Can change game type.
   // admin_gametype <gametype #>
   //
   // 16 = Can change fraglimit and time limit.
   // admin_timelimit <timelimit #>
   // admin_fraglimit <fraglimit #>
   //
   // 32 = Can kick players on server.
   // admin_clientkick <client id #>
   // admin_kick <name>
   //
   // 64 = Can use "bad" cmds on server. This is mainly for scriptures. noclip, dog etc.
   // no cmds:
   //
   // 128 = Can ban players on the server.
   // admin_addname <name>
   // admin_addip <ip>
   // admin_listnames
   // admin_iplist
   //
   // 256 = Can un ban players on the server.
   // admin_listnames
   // admin_iplist
   // admin_removename <name>
   // admin_removeip <ip>
   //
   // 512 = Can add and remove, view chat filter.
   // admin_chatfilteradd < word >
   // admin_chatfilterremove < word >
   // admin_chatfilterlist
   //
   // 1024 = Can use Admin Pro
   // admin_cmd <cmd string>
   //
   // 2048 = Can list admins
   // listadmins
   //
   // 4096 = Can do anything. Same as normal rcon. (super admin)
   // admin_rcon
   //
   // All together total added is 16383
   //
   // You can add rights together.
   // eg1.  map(2) + restart(4) = 6
   // eg2.  Protected name(1) + Map(2) +  restart(4) = 7
   // just like dmflags
   //
   // Admins must setu the cvar "admin_auth" in their game. This cvar should contain the password
   // apointed them in the admin.ini admins list.
   //
   // eg, in my config for my game, i put setu "admin_auth" "password"
   //
   //   You must enter these commands into console.
   //
   // Contact/Help
   // ------------
   // If you have any questions, feel free to contact me at:
   // Forums: Www.mods-r-is.net
   // E-mail:
   //------------------------------------------------------------
   //
   //name          password          Level
   //--1------------|-------------2-----------------|--------3-----
   //name=examplename     password=example       rights=7 (example, wont be seen as an admin because of the // in front of the line)
   
   name=SCS_Rocket-Devil      password=password         rights=4096

   

   Also what is admins.cfg? I havn't got that.

   Oh also went on Www.mods-r-is.net doesnt work lol, think there is a type in that admin.ini

Elgan {sfx}

lol ty, nice noticed. ini looks fine.

   

   

   it should be admins.ini i made a typo in error report i know. god, i also realised the linux doesnt like  and  paths etc load, must be somethign in the connection crashing it.  strange because it works so fine on my pc.  ;

   

   

   still crash on connect rookie, also i noticed that the imports struct has a free() function, not used it tho. Tried it either.

   

   

   Dont knwo whats up with crash on connect, have to go through and check  it ii guess, it dont happen for me its so weird, This fact tho, that it only happens on remote may mean its a problem when looking though checking players.

   

   i was about to go through it when i decided to give SH a bash. was looking at SH, the exports seem to be fine. tho the imports struct needs mroe and therefore is wrong. SO when i do things it crashes or causes problems. I tried logging the size to wor it out but i dont really know how to get the individual functions. SO ill talk with wombat see if he has any time to help me. SH might work then.

   

   The admin.cpp i used in the build above is here: 75-copy of admin.txt

op-x

great job elgan

   

   admins & cmds work gr8 except for the admin pro commands

   

   i just type in console

   admin_cmd "3 say blah" or any admin_cmd command and nothing happens

   i have to use rcon admin_cmd to make it work

   is that how its supposed to be, by also logging in with rconpassword to use admin pro?

   

   thx:)

Elgan {sfx}

hm, i guess admin_cmd for admin pro is broken, i didnt test that one. hehe, ty for the ehadsup

Floyd

Today, I logged onto my server using the setu admin_auth password, ( I am the only one set up with a password right now in the admin.cfg, no other clan members are in there, just me ) I also logged in with the server private slot password. One of my members that was in a private slot, also had admin powers.It showed up in his console after I joined the server. He was able to get status, restart the map, and accessed the chatfilterlist. He was in slot 0, and I was in slot 1. This is what I have at the bottom of my admin.cfg.

   

   //------------------------------------------------------------

   //

   //name          password          Level

   //--1------------|-------------2-----------------|--------3-----

   //name=examplename     password=example       rights=7 (example, wont be seen as an admin because of the // in front of the line)

   

     name=[1stssf] Floyd.CNC    password=xxxxxxxxx               rights=16343

   

   

   Thats it, only me. No other members are set up for it yet.

Rookie One

Why have I got the feeling some stricmps need to be reversed.
here's my stuff - inequation.org | here's where I work - thefarm51.com

DanJ


stay2theleft

Has anybody found out why some window servers crash with 2.0 update :(

Elgan {sfx}

ill fix em soon. i promise! haha, i didnt even look yet, eek,