Territory Claimer

territory or land control npc

You attack the npc(probably throne later), and when its hp reaches 0, you become the new owner.

Then on a hud map i'm making it change the color of the level area, based on the guild,nation or person that owns it. Then possibly work an economy system around it.

(edit)-Working, i guess the problem was my gserver not reloading the level with the new script.

[code]
// NPC made by HanduponyoHip
timeout = 0.05;
timereverywhere;
// realized this next part isn't actually needed.
//if (playerenters&&this.leader) {
// this.value = 30;
// setstring server.val2,#v(this.value);
// timeout = 0.05;
//}
if (playerenters&&!isleader){
setplayerprop #c,#s(server.val2);
this.value = int(#c);
setplayerprop #c,;
showimg 2,@Owner #s(server.kingdom2),18,36;
changeimgzoom 2,.5;
changeimgcolors 2,233,12,23,.7;
timeout = 0.05;
}

if (washit&&this.value<=0){
this.value=30;
}
if (washit&&!this.value==0){
this.value–;
}
if (shotbyplayer&&!this.value==0){
this.value–;
}

if (timeout){
setstring server.val2,#v(this.value);
message #s(server.val2);
showimg 2,@Owner #s(server.kingdom2),18,36;
changeimgzoom 2,.5;
changeimgcolors 2,233,12,23,.7;
if(this.value==1){
setstring server.kingdom2,;
deletestring server.kingdom2,;
setstring server.kingdom2,#a;
this.val=30;
}
timeout = 0.05;
}

if (timeout&&!isleader){
setstring server.val2,#v(this.value);
message #s(server.val2);
showimg 2,@Owner #s(server.kingdom2),18,36;
changeimgzoom 2,.5;
changeimgcolors 2,233,12,23,.7;
if(this.value==1){
setstring server.kingdom2,;
deletestring server.kingdom2,;
setstring server.kingdom2,#a;
this.val=30;
}
timeout = 0.05;
}

//if (playerchats&&strequals(#a,#s(server.kingdom2))){
// showimg 580,@Hi Owner!,playerx,playery-3;
// changeimgzoom 580,.5;
// changeimgcolors 580,233,12,23,.7;
// sleep 2;
// hideimg 580;
//}

timeout = 0.05;[/code]