Function Request: Detect if you've killed an enemy unit

Function Request: Detect if you've killed an enemy unit

Discuss Lua based Spring scripts (LuaUI widgets, mission scripts, gaia scripts, mod-rules scripts, scripted keybindings, etc...)

Moderator: Moderators

Post Reply
User avatar
REVENGE
Posts: 2382
Joined: 24 Aug 2006, 06:13

Function Request: Detect if you've killed an enemy unit

Post by REVENGE »

Currently, Spring.GetUnitIsDead and widget:UnitDestroyed only return info for you or your allies' units. I request that either these two functions return values for enemy units killed while in your los, or have some alternative function that allows you to know that you killed an enemy unit. It's fine if los is a required condition for info to be returned.
User avatar
Hoi
Posts: 2917
Joined: 13 May 2008, 16:51

Re: Function Request: Detect if you've killed an enemy unit

Post by Hoi »

Why not for everything? so you could make something like the ota info bar (when you press space)
dizekat
Posts: 438
Joined: 07 Dec 2007, 12:10

Re: Function Request: Detect if you've killed an enemy unit

Post by dizekat »

Hoi wrote:Why not for everything? so you could make something like the ota info bar (when you press space)
Coz there will be a widget that displays special well visible marks where you killed some stuff outside LOS, for instance. A form of maphack. (Not very useful though)
You're not supposed to know what happens outside LOS, and widgets, the way it is designed, are not supposed to have any more knowledge than player gets.
User avatar
Hoi
Posts: 2917
Joined: 13 May 2008, 16:51

Re: Function Request: Detect if you've killed an enemy unit

Post by Hoi »

I'll need a gadget then
User avatar
REVENGE
Posts: 2382
Joined: 24 Aug 2006, 06:13

Re: Function Request: Detect if you've killed an enemy unit

Post by REVENGE »

Hoi wrote:Why not for everything? so you could make something like the ota info bar (when you press space)
So what, you can track how many kills your team has? There's a function for that, and of course, someone has already made a widget that displays your kills and those of other teams.
User avatar
Hoi
Posts: 2917
Joined: 13 May 2008, 16:51

Re: Function Request: Detect if you've killed an enemy unit

Post by Hoi »

Cool, link?
User avatar
REVENGE
Posts: 2382
Joined: 24 Aug 2006, 06:13

Re: Function Request: Detect if you've killed an enemy unit

Post by REVENGE »

First and foremost:
90% of currently implement functions are documented here, in the wiki.

Secondly, you want this function:

Code: Select all

Spring.GetTeamUnitStats
 ( number teamID ) ->
   nil | number killed,
         number died,
         number capturedBy,
         number capturedFrom,
         number received,
         number sent
Thirdly, the widget I'm talking about is part of the IceUI system, somewhere on jobjol. I don't use it because it slows my Spring down.
User avatar
NOiZE
Balanced Annihilation Developer
Posts: 3984
Joined: 28 Apr 2005, 19:29

Re: Function Request: Detect if you've killed an enemy unit

Post by NOiZE »

i would love a kill counter a la OTA, someone plz make it =)
User avatar
CarRepairer
Cursed Zero-K Developer
Posts: 3359
Joined: 07 Nov 2007, 21:48

Re: Function Request: Detect if you've killed an enemy unit

Post by CarRepairer »

Satirik's IceUI fork shows a column for kills and losses for each player on your team. Is that not it?
Post Reply

Return to “Lua Scripts”