What's the best method to detect if a unit is dead or not?
GetUnitState(GetTriggerUnit(), UNIT_STATE_LIFE) > 0
GetWidgetLife(GetTriggerUnit()) > 0
IsUnitType(GetTriggerUnit(), UNIT_TYPE_DEAD)
I've also heard that 0.405 is better than 0, is this true?
Is there a limit to the amount of text tags that can be displayed at once? I have text tags being created whenever a unit is damaged to show the amount of damage they take, but it will sometimes disappear or not appear at all.
http://pastebin.com/R3YT4PEr
I'm trying to use a static method as a trigger inside a struct. For some reason I can't use the struct's values inside of it.
Is there anyway to bypass this?
ASYST
Version 1.0.2
Requirements:
- Jass NewGen
- AIDS
- Damage
- TimerUtils
- GetPlayerColored
Updates:
- Version 1.0.2: Added a boolean for floating text and added floating text for assists.
- Version 1.0.1: Added floating text (+#) and a function for the gold formula...
I have an upgrade that increases the level of an ability of another unit. This upgrade seemed to do nothing, but if I researched another upgrade (such as more hp/damage) afterwards, it worked perfectly. Does anyone know what the problem is?
When I convert my real to integer, it doesn't convert correctly. The value of the real is 315.00, and the value of the integer ends up being 314. I found a way to bypass this by using R2S and S2I in conjunction, but there has to be a simpler way. Can anyone help?
I've currently been working on an assist system for my map, but I'm fairly certain it can be improved. Does anyone see anything that would help its performance?
// Created by AoW_Hun7312
library ASYST initializer Init requires AIDS, Damage, TimerUtils
globals
// Configurable...
I've recently started getting into structs, and I have a few questions.
1. What's the best way to create types during initialization? I plan on using it for the entire duration of the map.
2. What does this error mean and how do I fix it: "is not of a type that allows . syntax".
I recently purchased Starcraft 2, and ended up finishing the campaign and fooling around with the new editor. It was far too cumbersome for me, so I'm using the World Editor again. A map I'm currently working on is in desperate need of a terrainer, as I'm completely terrible at it.
The map is a...
Well, I'm messing around with the Game Interface right now, and I can't find out how to hide some of the text that appears when you hover over the hero attributes. I can modify it, but if I delete the whole line to hide that bit of it, it will still show up. I can replace it with a space, but...
I was reading up on memory leaks using the tutorials here, and ran into a few questions.
1. Do I have to null local player variables? What else has to be nulled?
2. Do I have to create a "fake" boolexpr in this function, or am I fine using null?
call TriggerRegisterPlayerUnitEvent(t...
For some reason my function "countTaggers" won't work correctly. When I debug the Tagger amount, it's always 0, even when I'm player 11 or 12, but the Runner count does increase.
library Initialization initializer Init
globals
constant integer RUNNER_ID = 'n000'
constant...
What is "value" in SetPlayerAlliance() used for?
native SetPlayerAlliance takes player sourcePlayer, player otherPlayer, alliancetype whichAllianceSetting, boolean value returns nothing
EDIT: I'm trying to set two forces to be enemies/allies. Am I using this function correctly...
What am I doing wrong on line 34? "if (runnerLower == -1)". I think something else in this trigger may be wrong too.
library Initialization initializer Init
globals
force forceRunners = CreateForce()
force forceTaggers = CreateForce()
integer runnerCount =...
I'm using I2S to display the integer "runnerCount". For some reason, it won't work if I don't retrieve the value through a function. It also won't work if use I2S(getRunnerCount()).
Library
library Initialization initializer Init
globals
force forceRunners
force...