From f6dbe81dbe0052404b0f0a172118ae06dffbeab4 Mon Sep 17 00:00:00 2001 From: toasterpanic Date: Tue, 2 Jun 2026 16:52:55 -0400 Subject: [PATCH] Bug fixes and remove all the printing --- README.md | 5 ++++- lua/autorun/client/zcnpci_menu.lua | 2 ++ lua/entities/npc_ragdoll_target.lua | 2 +- lua/zcnpci.lua | 4 ---- lua/zcnpci/modules/falling_legs.lua | 2 -- 5 files changed, 7 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index adbf122..2704086 100644 --- a/README.md +++ b/README.md @@ -34,13 +34,16 @@ It is, however, not compatbile with: MUST BE DONE BEFORE RELEASE: +- Spinal injuries - NPCs should not unfake when moved around -- Actual specific reactions to being on fire / falling / lots of pain +- Fire / falling / pain reaction (more rapid flailing) +- NPCs should not unfake if being grabbed Stuff to do: - Facial expressions - Generally improve stumbling (foot stepping) +- Stop NPCs from dropping their guns (that's not a good thing to do) Post release ideas: diff --git a/lua/autorun/client/zcnpci_menu.lua b/lua/autorun/client/zcnpci_menu.lua index 32e904e..acdf8cd 100644 --- a/lua/autorun/client/zcnpci_menu.lua +++ b/lua/autorun/client/zcnpci_menu.lua @@ -16,6 +16,8 @@ local function PopulateCustomNPCSBXToolMenu(pnl) pnl:Help("ZCNPCi has support for both modded NPCs, as well as base-game humanoid NPCs that Z-City never added. There is no guarantee that modded NPCs will work, but ones with similar skeletal structure to other base-game humanoid NPCs will generally work better.") + pnl:Help("As long as the NPC has a compatible skeleton, support will be provided for modded NPCs on a best-effort basis.") + pnl:CheckBox("Allow base-game extended NPCs", "zcnpci_allow_extended_base_npcs") pnl:ControlHelp("Enable or disables applying custom health system to most other base-game humanoid NPCs, such as Kleiner.") diff --git a/lua/entities/npc_ragdoll_target.lua b/lua/entities/npc_ragdoll_target.lua index a0cd7d8..6a060ed 100644 --- a/lua/entities/npc_ragdoll_target.lua +++ b/lua/entities/npc_ragdoll_target.lua @@ -76,7 +76,7 @@ function ENT:Think() if !ragdoll.organism then return true end - local should_stop_targeting = !zcnpci_no_unconscious_targeting:GetBool() or ( + local should_stop_targeting = !stop_targeting_when_unconscious:GetBool() or ( (ragdoll.organism.consciousness <= 0.4) or (ragdoll.organism.critical) ) diff --git a/lua/zcnpci.lua b/lua/zcnpci.lua index c0f2094..3d5371f 100644 --- a/lua/zcnpci.lua +++ b/lua/zcnpci.lua @@ -133,9 +133,6 @@ hook.Add("CreateEntityRagdoll", "zcnpci", function(ent, ragdoll) local velocity = ragdoll:GetPhysicsObject():GetVelocity() - print(velocity) - print(max_clamp) - -- For some reason, citizen types such as rebels, medics, refugees, etc. use a keyvalue. -- That keyvalue does not transfer over to the ragdoll, despite it looking like the NPC, -- and you have to manually save it to the ragdoll to be able to make it work. @@ -163,7 +160,6 @@ hook.Add("HomigradDamage", "zcnpci", function(ent, dmginfo) if dmginfo:IsDamageType(DMG_BULLET + DMG_BUCKSHOT + DMG_BLAST + DMG_CLUB + DMG_SLASH + DMG_GENERIC) then -- Reset ragdoll get up timer -- don't want someone getting up mid-curbstomp ent.StartDie = CurTime() - print("I'M HIT FOR "..dmginfo:GetDamage()) end return diff --git a/lua/zcnpci/modules/falling_legs.lua b/lua/zcnpci/modules/falling_legs.lua index 6a5ed53..e6fa720 100644 --- a/lua/zcnpci/modules/falling_legs.lua +++ b/lua/zcnpci/modules/falling_legs.lua @@ -236,7 +236,6 @@ function MODULE:Think() local phys = target:GetPhysicsObject() if target.FakeUp then - print("fucking it") local parent = self.FakeParent if !IsValid(parent) then return end @@ -329,7 +328,6 @@ function MODULE:PhysicsSimulate(phys, dt) local animation_progress = (CurTime() - self.FakeUpStart) / (self.FakeUpEnd - self.FakeUpStart) for i, name in pairs(fakeup_bone_names) do - print(name) local object = target:GetPhysicsObjectNum(target:TranslateBoneToPhysBone(target:LookupBone(name))) local parent_bone = parent:LookupBone(name)