I tried to modify it by changing the 3rd job IDs to trans job IDs. Does anyone know what has to be the problem with this?
Here's the code:
// War of Emperium for Transcendent Only
// Created by Jezu of rAthena.org
// v1.0 - First Release
// Please do visit us on rAthena.org/board
- script TransWoE -1,{
OnInit:
set .maps$[0],"gefg_cas04";
set .maps$[1],"gefg_cas01";
//setup flags for lookup later (.m_<map>)
set .@i, getarraysize(.@maps$) - 1;
while(.@i >= 0) {
setmapflag getd(.maps$[.@i]), mf_loadevent;
setd(".m_" + .maps$[.@i], 1);
set .@i, .@i - 1;
}
end;
OnPCLoadMapEvent:
if(getd(".m_" + strcharinfo(3))) { //checks if .m_<map> is set
if(Class >= 4008 && Class <= 4011 || Class >= 4012 && Class <= 4022) {
announce "Transcendent Jobs are not allowed here!",bc_self|bc_yellow;
warp "SavePoint",0,0;
end;
}
}
}
//Mapflags
gefg_cas04 mapflag loadevent
gefg_cas01 mapflag loadevent
The above code is not working. It doesn't warp me back to the save point and also doesn't announce. Please help!