Raised This Month: $ Target: $400
 0% 

remove hostage + bombsite


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
kp_uparrow
Penalized Member
Join Date: Jun 2006
Location: 192.168.0.1
Old 08-12-2007 , 20:46   remove hostage + bombsite
Reply With Quote #1

how can i remove hostages and bombsites?

i have looked at no objectives + no round timer, i want the round timer and i want the round to end @ 0:00, but this plugin checks every entity spawn which is not the way i want it to

so i just want to find hostage entity and bomb site entity and remove them

can i do this?

Code:
new const g_objective_ents[][] = {     "func_bomb_target",     "info_bomb_target",     "hostage_entity",     "monster_scientist",     "func_hostage_rescue",     "info_hostage_rescue",     "info_vip_start",     "func_vip_safetyzone",     "func_escapezone" } ..... new items for (i = 0; i < sizeof g_objective_ents; ++i) { //++i or i++?  items = find_ent_by_class(-1, g_objective_ents[i])     while(items)     {         remove_entity(items)         items = find_ent_by_class(items, g_objective_ents[i])     } }
__________________
I USED A SECOND ACCOUNT TO DO MORE KARMA UPS AND DOWNS UNTIL GREENTRYST CAUGHT ME
kp_uparrow is offline
VEN
Veteran Member
Join Date: Jan 2005
Old 08-13-2007 , 00:48   Re: remove hostage + bombsite
Reply With Quote #2

Simple hostage remove should be potential to crash. You can try to request CHostage::Remove(void) implementation for Ham Sandwich module.
VEN is offline
thats the way it is
Junior Member
Join Date: Jan 2007
Old 08-13-2007 , 08:46   Re: remove hostage + bombsite
Reply With Quote #3

i think thare is a plugin for this to set the hostage life with that u can set the hostage life to 0 so thay die on the begin of the map
thats the way it is is offline
kp_uparrow
Penalized Member
Join Date: Jun 2006
Location: 192.168.0.1
Old 08-13-2007 , 16:14   Re: remove hostage + bombsite
Reply With Quote #4

i can just move the hostages away

but would that script work and it has to be executed every round right?
__________________
I USED A SECOND ACCOUNT TO DO MORE KARMA UPS AND DOWNS UNTIL GREENTRYST CAUGHT ME
kp_uparrow is offline
hmrsmpsn
Senior Member
Join Date: Nov 2005
Location: sWeDeN YEEAAAH!!!
Old 08-13-2007 , 17:11   Re: remove hostage + bombsite
Reply With Quote #5

i noticed after trying to remove hostages that renaming the entity works

so you give each hostage entity a new classname like old_hostage

and then you remove all old_hostage.

doesnt crash or nothin
__________________



new Float:second = 1.0
new Float:minute = 60*second
new Float:hour = 60*minute
new Float:day = 24*hour
new Float:year = 365*day
set_task(10.0*years,"clean_my_room")
hmrsmpsn is offline
_Master_
Senior Member
Join Date: Dec 2006
Old 08-14-2007 , 02:11   Re: remove hostage + bombsite
Reply With Quote #6

I would test that with bots on server if I were you... just to be safe...
_Master_ is offline
Pro Patria Finland
Senior Member
Join Date: Apr 2006
Location: BaronPub.com
Old 08-14-2007 , 03:33   Re: remove hostage + bombsite
Reply With Quote #7

Quote:
Originally Posted by kp_uparrow View Post
i can just move the hostages away

but would that script work and it has to be executed every round right?
I remember reading some plugin source, where hostages are simply moved to some origin that is not on the map. That should work, and yes it should be executed every round (atleast I think it should).
__________________
I am not a number. I am Gordon Freeman!
Pro Patria Finland is offline
hmrsmpsn
Senior Member
Join Date: Nov 2005
Location: sWeDeN YEEAAAH!!!
Old 08-14-2007 , 07:15   Re: remove hostage + bombsite
Reply With Quote #8

i tested that with bots and it works fine
i suggest you test it too
__________________



new Float:second = 1.0
new Float:minute = 60*second
new Float:hour = 60*minute
new Float:day = 24*hour
new Float:year = 365*day
set_task(10.0*years,"clean_my_room")
hmrsmpsn is offline
[X]-RayCat
Senior Member
Join Date: Sep 2006
Old 08-14-2007 , 08:01   Re: remove hostage + bombsite
Reply With Quote #9

Kill hostages with trigger_hurt or move them under the floor.
[X]-RayCat is offline
hmrsmpsn
Senior Member
Join Date: Nov 2005
Location: sWeDeN YEEAAAH!!!
Old 08-14-2007 , 17:18   Re: remove hostage + bombsite
Reply With Quote #10

ugh well as you said my server got unstable :/ (it wasnt before)
so i changed it and moved the hostages instead engfunc(engfunc_setorigin,ent,{4096.0,4096.0, 4096.0})
__________________



new Float:second = 1.0
new Float:minute = 60*second
new Float:hour = 60*minute
new Float:day = 24*hour
new Float:year = 365*day
set_task(10.0*years,"clean_my_room")
hmrsmpsn is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 14:33.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode