HL2DM: new_[exile]_pet_vet_map
I have this map that has strider spawn in and respawn after death. The trouble i am having is that after death of the strider, the model stays on the map, so after a while they are a bunch on the ground, Is there a script/plugin that will make them dead body's go away after their death ?. Stay cool all and have a great day/night. I have a plugin that makes the npcs i use go away - viewtopic.php?f=37&t=2378 but does not seem to remove the strider that is built in the map.
HL2DM: Strider resolver
- daren adler
- Senior Member
- Posts: 348
- Joined: Sat May 18, 2019 7:42 pm
-
- Senior Member
- Posts: 310
- Joined: Sun May 17, 2020 7:56 am
- Location: Finland
- Contact:
Re: HL2DM: Strider resolver
Try this one (Untested)
Syntax: Select all
from entities.entity import Entity
from events import Event
@Event('entity_killed')
def entity_killed(args):
try:
entity = Entity(args['entindex_killed'])
except ValueError:
return
classname = entity.classname
if not classname == 'npc_strider':
return
entity.remove()
- daren adler
- Senior Member
- Posts: 348
- Joined: Sat May 18, 2019 7:42 pm
Re: HL2DM: Strider resolver
some reason it did not work, but shows no errors. thank you for trying my friend. here is the vmf it that helps. https://www.dropbox.com/scl/fi/7nmz9czy ... 3f8e1&dl=0
i knnow i am using this in my sourcepython named little silent hill viewtopic.php?f=37&t=2350 it uses
But it does not remove the strider for some reason. I updated my source-python also and no luck.
i knnow i am using this in my sourcepython named little silent hill viewtopic.php?f=37&t=2350 it uses
Code: Select all
def dissolve(self):
"""Removes the ragdoll of the NPC."""
dissolver = Entity.find_or_create('env_entity_dissolver')
dissolver.dissolve_type = 0
dissolver.dissolve(self.target_name)
But it does not remove the strider for some reason. I updated my source-python also and no luck.
-
- Senior Member
- Posts: 310
- Joined: Sun May 17, 2020 7:56 am
- Location: Finland
- Contact:
Re: HL2DM: Strider resolver
Try this one instead:
Syntax: Select all
from listeners.tick import Repeat
from filters.entities import EntityIter
strider = EntityIter('npc_strider')
delay = 1.0
def load():
check_dead_strider.start(delay)
def unload():
check_dead_strider.stop()
@Repeat
def check_dead_strider():
for entity in strider:
if entity.health < 1:
entity.remove()
Who is online
Users browsing this forum: No registered users and 2 guests