DrVrej / VJ-Base

An addon for Garry's mod that contains bunch of bases to make many different types of addons.

Home Page:http://steamcommunity.com/sharedfiles/filedetails/?id=131759821

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Allow to disable changing targetname of entity in Initialize() to self.PrintName

URAKOLOUY5 opened this issue · comments

I'm making somekind of support for my SNPCS for scripted_sequence entity and think this is will be better if there was a self.OverrideTargetName condition for this line in base npcs:

self:SetName((self.PrintName == "" and list.Get("NPC")[self:GetClass()].Name) or self.PrintName)

so:

if self.OverrideTargetName then
self:SetName((self.PrintName == "" and list.Get("NPC")[self:GetClass()].Name) or self.PrintName)
end

I know I can revert name back to K/V of targetname, but this idea is better.

commented

Thanks for reporting this issue! It has been fixed in e8a0fa2 and will be included in the next update!