When I use the command it invokes the command on the NPC that the with (npcs[index]) command is on, not the NPC of the specified index.
For example, say that I had two NPCs, one with an index of 0, and the other with an index of 1, and I put in a command like this into NPC 0.
NPC Code:
if (playerenters) {
with (npcs[1]) {
destroy;
}
}
Then if I enter the level, it's the NPC with the index of 0 that gets destroyed, not the one with the index of 1.
Does with (npcs[index]) only work online, or am I just using it wrong?