Quote:
Originally posted by neomaximus2k
A very good try dude, but however a few things
1) why use P5, why nut use a string or variable or some other means to make it purly non p2p
2) was gonna say not to use functions but then again lol USE THEM
|
Quite simply because P5 was the first string which stays stored and can make the NPC contain the value which occurs to me. Of course if you wuold know one which can be changed and makes no visible difference feel free to change it, or something.
Quote:
Originally posted by mikepg
you can add a for loop
in the npc textfile do something like:
NPC Code:
if (created) {
showcharacter;
changeclothes();
}
function changeclothes() {
for (this.i=0; this.i<playerscount; this.i++ {
if (players[this.i].x=x && players[this.i].y=y) {
setcharprop #C2(-1),#C2(this.i);
return;
}
}
destroy;
}
for the setcharprop section, do all of the variables, not just C2, with what is in the '()'s left the same.
That should work, provided you are the only person standing there for the clothes part....as for the message...you'd have to be saying it when you fire the weapon, and add it in the function as well, or you'd have to make a big huge menu that wouldnt be worth the trouble.
|
#C2(-1) is not necesarry for setcharprop, simply because setcharprop is always applied to the NPC which runs it.