list of all pcs in pcs.txt

Get Help on scripting in POL with configurations, config setups, script trouble shooting, etc.
Post Reply
Gnafu
Grandmaster Poster
Posts: 136
Joined: Thu Feb 02, 2006 7:29 am

list of all pcs in pcs.txt

Post by Gnafu »

i want to list all the pcs in the datafile and check if there are some of them without account (caused by errors, etc. ).

how can i do?

just a

Code: Select all

var datafile:= OpenDataFile( "pcs" );
if (!datafile)
    Sendsysmessage(who," "+datafile);
    Print(datafile);
    Print("Il datafile non esiste!");
    Sendsysmessage(who,"Il datafile non esiste!");
    return;
endif;   


foreach key in datafile

    Sendsysmessage(who," "+key);
  
endforeach
MuadDib
Former Developer
Posts: 1091
Joined: Sun Feb 12, 2006 9:50 pm

Post by MuadDib »

IF they have no account? No need mate. If a character (player, in pcs.txt) has no account, or the account it is linked to happens to "dissappear" somehow, POL will not load. All characters must have an account linked to them for POL to load.
Gnafu
Grandmaster Poster
Posts: 136
Joined: Thu Feb 02, 2006 7:29 am

Post by Gnafu »

perfect,

thanks
:D
Post Reply