Project Zomboid

Project Zomboid

Take No Prisoners (Hostile NPC's with PZNS framework)
oZumbiAnalitico  [developer] 25 Oct, 2023 @ 2:39pm
Creating Enemy Addon
Assuming you already know how to create and upload mod on steam (You can ask if not).
1. Go to the Take No Prisoners steam workshop mod folder.
2. Copy the file template_enemy.lua or any enemy file from TakeNoPrisoners_CONTENT folder and put it on client folder of your mod with a custom name.
3. Mutatis mutandis.
4. Use these functions ...

TNP_spawners.add_field_spawner(fieldSpawner,3)
TNP_spawners.add_building_spawner(buildingSpawner,3)

(debug)
TNP_spawners.add_context_field_spawners("myEnemy - Field",fieldSpawner)
TNP_spawners.add_context_building_spawners("myEnemy - Building",buildingSpawner)

... to register the spawners of your addon, so the TakeNoPrisoners mod will spawn automatically your custom hostile npc.

your addon must obviously require TakeNoPrisoners mod and the PZNS_framework mod.
< >
Showing 1-4 of 4 comments
ANKARA MESSI 26 Jan, 2024 @ 5:35pm 
so, im trying to create enemies based on the vanilla stories, so the functions for the outfits and such are already in the game, but i cant find them
oZumbiAnalitico  [developer] 4 Feb, 2024 @ 7:37pm 
@duende pablo
Hi, I solving some irl issues so I will not respond promptly, visit the github page for the PZNS Framework, there you can search for the function, I don't remember the function name right now, but must be defined on PZNS_UtilsNPCs.lua file.

You can use the files inside my mod folder TakeNoPrisoners_CONTENT as templates, there you will find the spawners for each enemy type of the mod, and then "mutatis mutandis".
< >
Showing 1-4 of 4 comments
Per page: 1530 50