Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » Another SSGM Question
Re: Another SSGM Question [message #271879 is a reply to message #271871] Mon, 09 July 2007 01:58 Go to previous messageGo to previous message
Whitedragon is currently offline  Whitedragon
Messages: 832
Registered: February 2003
Location: California
Karma:
Colonel
You could make Is_Mod work for any text file:

bool Is_Mod(const char *File, const char *Name) {
     fstream file(File, ios::in);
     string tmp;
     while(file >> tmp) { 
         if(strcmp(Name, tmp.c_str()) == 0) {
               return true;
         }
     }
     return false;
}


if (Is_Mod(file,nick)) {



joe937465 wrote on Mon, 09 July 2007 03:56



ChatCommandRegistrant<GDISoldierChatCommand> GDIEngieCommandReg("!GDISoldier",CHATTYPE_ALL,0,GAMEMODE_ALL);




That should be a 1.


Black-Cell.net
Network Administrator (2003 - )

DragonServ, Renegade's first IRC interface bot
Creator and lead coder (2002 - )

Dragonade, Renegade's first server side modification
Lead coder (2005 - )
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Reborn
Next Topic: coding
Goto Forum:
  


Current Time: Fri Nov 29 00:45:32 MST 2024

Total time taken to generate the page: 0.00912 seconds