viewing paste block item in maps | Athena

Posted on the | Last edited on
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34
-   script  sample  -1,{
OnInit:
// map list
setarray .map$,
    "prtg_cas01",
    "prtg_cas02",
    "prtg_cas03",
    "prtg_cas04";
    
// item list
setarray .item,4001,4002,4003,4004;
 
.map_size = getarraysize( .map$ );
.item_size = getarraysize( .item );
.map_list$ = "|";
for( .@i = 0; .@i < .item_size; .@i++ ){
    setmapflag .map$[.@i],mf_loadevent;
    .map_list$ = .map_list$ + .map$[.@i] + "|";
}
end;
 
OnPCLoadMapEvent:
if( compare( .map_list$,"|"+strcharinfo(3)+"|" )
    while( .@i < .item_size ){
        if( countitem( .item[.@i] ) ){
            mes "You cant bring "+getitemname( .item[.@i] );
            close2;
            warp "SavePoint",0,0;
            end;
        }
        .@i++;
    }
end;
}
Viewed 1350 times, submitted by Emistry.