25.05.2011, 02:48
pawn Код:
public OnCommandReceived(playerid,cmdtext[]) {
print("doh");
new file[256];
for(new i = 0; i < MaxTeles; i++) {
print("doh1");
format(file,sizeof(file),FileID,i);
if(!dini_Exists(file)) continue;
if(strcmp(dini_Get(file, "Command"),cmdtext,true) == 0) {
new Float:pos[2+1],name[30];
pos[0] = dini_Float(file, "X");
pos[1] = dini_Float(file, "Y");
pos[2] = dini_Float(file, "Z");
name = dini_Get(file, "Name");
return SendFormattedMessage(playerid,-1,"You have teleported to %s.",name);
}
}
}
pawn Код:
COMMAND:tpse(playerid) {
print("dohhh");
if(GetPVarInt(playerid,"LoggedIn") == 0 && !IsPlayerAdmin(playerid)) {
return DialogLogin(playerid);
} else {
return DialogMenu(playerid);
}
return 1;
}
pawn Код:
#define FILTERSCRIPT
#include <a_samp>
#include <dini>
#include <zcmd>