Matrix Games Forums

Forums  Register  Login  Photo Gallery  Member List  Search  Calendars  FAQ 

My Profile  Inbox  Address Book  My Subscription  My Forums  Log Out

Unit destroyed by

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [New Releases from Matrix Games] >> Command: Modern Operations series >> Mods and Scenarios >> Lua Legion >> Unit destroyed by Page: [1]
Login
Message << Older Topic   Newer Topic >>
Unit destroyed by - 12/18/2021 11:21:22 PM   
nogravity

 

Posts: 51
Joined: 6/15/2012
Status: offline
Is it possible to find out the side that destroyed an unit in Lua functions? Currently, the Command trigger get fired when an unit is damaged or destroyed but I cannot find a way to tell which side destroy or damage the unit. Is there a way?
Post #: 1
RE: Unit destroyed by - 12/20/2021 4:35:13 AM   
musurca

 

Posts: 128
Joined: 7/16/2020
Status: offline
This was just recently discussed here: http://www.matrixgames.com/forums/fb.asp?m=5101348

Short version: with many caveats, calling ScenEdit_UnitY() from a script after a damaged/destroyed trigger will USUALLY give you the weapon that destroyed it as a Unit. You can get the side from that Unit's wrapper.

(in reply to nogravity)
Post #: 2
Page:   [1]
All Forums >> [New Releases from Matrix Games] >> Command: Modern Operations series >> Mods and Scenarios >> Lua Legion >> Unit destroyed by Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts


Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI

0.656