ProjectsWhat's NewDownloadsCommunitySupportCompany
Forum Index » S.T.A.L.K.E.R.: Shadow of Chernobyl Forum » Mod discussion
Blowing up helicopters

Posted by/on
Question/AnswerMake Newest Up Sort by Descending
  16:48:15  17 September 2013
profilee-mailreply Message URLTo the Top
ddraig
Senior Resident
 

 
On forum: 06/19/2012
 

Message edited by:
ddraig
09/17/2013 16:50:09
Messages: 158
Blowing up helicopters

Would anyone know the easiest way of blowing up a helicopter, preferably using custom logic?

Basically I've got a scripted encounter where a helicopter patrols an area, and it's set up to loop around every now and then, and not "restart" if an emission is in progress. What I want to make happen is for an emission to "destroy" the helicopter, or at the very least make it so it's forced to "land" somewhere (going through the "on fire" animation) if it's already in the air.

The basic idea is to set up something in xr_effects so when an emission is in full swing it will "blow" up the helicopter. How would I go about creating a function to do this?
  23:49:58  17 September 2013
profilee-mailreply Message URLTo the Top
Vintar
a bit of this and a lot of that
(Resident)

 

 
On forum: 08/08/2008
Messages: 6349
from bind_heli.script, possibly is even included in xr_effects already but I don't have the vanilla version to check.

function heli_start_flame( obj )
	obj:get_helicopter():StartFlame()

	db.storage[obj:id()].flame_start_snd:play( obj )
end

function heli_die( obj )
	local heli = obj:get_helicopter()
	local st   = db.storage[obj:id()]

	heli:Die()

	db.del_heli( obj )

	st.last_alt       = heli:GetRealAltitude()
	st.alt_check_time = time_global() + 1000
end

  09:05:00  19 September 2013
profilee-mailreply Message URLTo the Top
insanelazarez
Yeah, Good Luck With That...
(Resident)

 

 
On forum: 01/31/2009
Messages: 1071
Something like this...



---QUOTATION---


[heli_move@end]
path_move = your_heli_path_walk
path_look = your_heli_path_look
default_velocity = 9
combat_ignore = true
engine_sound = true
mute = true
invulnerable = true
on_info = {+condition_name_given_by_your_blowout} nil %=heli_die%


---END QUOTATION---

  16:41:52  19 September 2013
profilee-mailreply Message URLTo the Top
ddraig
Senior Resident
 

 
On forum: 06/19/2012
Messages: 158
Thanks! I'll give it a shot with both heli_flame and heli_die and see which one looks better.
 
Each word should be at least 3 characters long.
Search:    
Search conditions:    - spaces as AND    - spaces as OR   
 
Forum Index » S.T.A.L.K.E.R.: Shadow of Chernobyl Forum » Mod discussion
 

All short dates are in Month-Day-Year format.


 

Copyright © 1995-2019 GSC Game World. All rights reserved.
This site is best viewed in Internet Explorer 4.xx and up and Javascript enabled. Webmaster.
Opera Software products are not supported.
If any problem concerning the site functioning under Opera Software appears apply
to Opera Software technical support service.