tModLoader Need help with npc code

Kafei

Skeletron Prime
Hello everyone! I was wondering if anyone could give me the information that i need to create my mod.
Does anyone have the code for an npc that spawns at the start of the game but spawns only in a certain structure
and doesn't move into a player built house (e.g. The old man at the dungeon).
 
Well in the NPC.cs class of the source code. The old man has a value call "this.townNPC = true;". You could try setting that value to false and from the name I assume that he won't move into NPC house.
 
Thanks -[FF]-Frost! I was looking around for the source code for vanilla town npc's, do you know where i could find them?
 
Never mind. I found the guide on the tmodloader wiki on how to decompile terraria.Thanks anyway!
Man... there's a bunch of stuff on here that i didn't see...
 
Back
Top Bottom