Featured Replies
Сейчас на странице 0
- Нет пользователей, просматривающих эту страницу
A better way to browse. Learn more.
A full-screen app on your home screen with push notifications, badges and more.
Используя этот сайт, вы соглашаетесь Условия использования.
Hi guys ,
I'm not an epic modder but i still did my own isnipe without copy paste xD with perk changer , fov changer , custom killstreaks ...
A few days ago i decided to make a new feature , custom stuff for people connected X time . For that i need to store some XUID , and the number of connections in a file and after hours of searching i'm blocked there : my problem is that i need to search in the file , and with the function on ZeRoY's cod script ref (http://www.zeroy.com/script/), i'm kinda lost . i've wrote this :
onplayerconnect(); { //normal stuff here self thread filestuff(); } filestuff() { if (self ishost()) { // i stock in filenum beause those function such as openfile fgetarg etc are working with file // number ( why ? idk either . -.-) filenum = openfile("playerlist.txt","read"); //open the file where is stored all guid //and number of connections . guid , connections. continue = true; while (continue) { id = fgetarg(filenum, 1);// search in GUID list until it match if (self.guid == id) { continue = false; // id matched with guid , no need to search anymore co = fgetarg(filenum,2); co++; fclose(filenum);//close file to open it in write mode filenum = openfile("playerlist.txt","write");// open in write mode fprintfields(filenum, id,co);//print new value } } } }1.but i think it wont work since i dunno how to go to the next line in the file and how to delete previous value of co
2. i've just seen that i've one more error in my script : i need to do this for every player probably with for each players in level.players or something like that ,and keep the .txt only on the server side to prevent cheats .
3. it's a server , not private match , so i dont know really how i can make my function because if(self ishost() ) wont work if i'm not here . i need to do some test with the function to see if it works only on server side by default or all client side .
4. Tryed to just see if those commands work , mod wont load because i need developper access ? WTF ?
i need help seriously guys