snowflake1963 1 Posted May 6, 2014 Hello All I would like to add new NPCs without having to replace any current ones. I am wondering if it is possible to do so and how to do it. Thank you in advance for any help that is given. mfg Snowflake Quote Share this post Link to post Share on other sites
0 Mhalicot 392 Posted May 7, 2014 What do you mean? is it like cloning NPC? Quote Share this post Link to post Share on other sites
0 jaBote 438 Posted May 7, 2014 You mean making NPCs from scratch? Sure, simply make a new file (preferably .txt for ease of editing, but the extension doesn't matter at all since you could have it .c or even without extension if you want) wherever you like within the npc/ folder (you can even make a new folder inside it!) and add your NPC there. In fact, it's not even needed to put your script inside npc/, but that helps your tidyness. For loading it, you could use the @loadnpc <path> script command or the loading structure that is called at bootup. I reccommend seeing examples directly in some files like npc/scripts.conf, which is better than giving an explanation and will let you know exactly what it asks for a location. You can also read this part, extracted from doc/script_commands.txt to let you know a bit more: Script loading structure ------------------------ Scripts are loaded by the map server as referenced in the 'conf/map-server.conf' configuration file, but in the default configuration, it doesn't load any script files itself. Instead, it loads the file 'npc/scripts_main.conf' which itself contains references to other files. The actual scripts are loaded from txt files, which are linked up like this: npc: <path to a filename> Any line like this, invoked, ultimately, by 'map-server.conf' will load up the script contained in this file, which will make the script available. No file will get loaded twice, to prevent possible errors. Another configuration file option of relevance is: delnpc: <path to a filename> This will unload a specified script filename from memory, which, while seemingly useless, may sometimes be required. Hope I helped on it. Else please restate your question since I may have misunderstood. Quote Share this post Link to post Share on other sites
0 snowflake1963 1 Posted May 8, 2014 @Mhalicot I do mean new npcs, because whenever i add an npc by using an existing npc id kro decides to use that npc somewhere so i want add the new npcs with their own ids. @jaBote I know how to load an npc in a script but thank you Like i said to Mhalicot when ever i use an npc like for example the tw_tower, kro does updates and adds the npc as a result of kro updates my npcs look like the tw_tower. i want to add without replacing an already kro npc. mfg Snowflake Quote Share this post Link to post Share on other sites
0 jaBote 438 Posted May 8, 2014 So, to make sure, you want to add your new NPC sprites? Quote Share this post Link to post Share on other sites
0 ぽろり 1 Posted May 8, 2014 you could use a far way ID from kRO's current last ID # for example : JT_4_TOWER_15 = 10002, JT_COMMERCIALRICE_1 = 10105 or why not add your lub files in your custom grf Quote Share this post Link to post Share on other sites
Hello All
I would like to add new NPCs without having to replace any current ones.
I am wondering if it is possible to do so and how to do it.
Thank you in advance for any help that is given.
mfg
Snowflake
Share this post
Link to post
Share on other sites