• 0

    posted a message on actor status set and get

    Actors only deal with stuff that cannot change the outcome of the game in any way, like graphics and audio.

    Use Behaviors/Effects/Abilities/etc to change the gameplay. You could for example make a weapon add a stacking behavior every time the unit uses it's weapon. When the behavior reaches a certain number, the unit is out of ammo. Remove the behavior stack to reload his weapon.

    Posted in: Triggers
  • 0

    posted a message on Check ability requirement through triggers

    Bump

    Posted in: Triggers
  • 0

    posted a message on Attack beam vanish!

    @Sherlia: Go

    You can't change these things in the sc2 editor as far as I know. There are a number of things that are built into a model, and this seem to be one of them. Export the model and open it in a 3d model editor if you want to dig deeper into this.

    Posted in: Data
  • 0

    posted a message on Attack beam vanish!

    @Sherlia: Go

    Sure.

    I set the Engineering Bay model to Sensor Tower and had it's opacity set to 0 at Actor Creation. I increased it's scale a little to match the shape of the Vespene Tank.

    Then created the model addition actor Vespene Tank Model which is attached to the Engineering Bay. This actor should not inherit opacity, model scale or scale, in order for these values to be independent from the Sensor Tower

    Posted in: Data
  • 0

    posted a message on Attack beam vanish!

    You could try to attach a model that has roughly the same shape as your custom model, and then set the attachment's opacity to 0.

    Posted in: Data
  • 0

    posted a message on Change color of Fog of War

    @Tudentau: Go

    Yeah, the fog of war data seemed very lacking.

    How do you tint all fog of war by the way?

    Edit: Oh, I didn't realize the see through fog of war color was controlled by the black mask color

    Posted in: Data
  • 0

    posted a message on Selection halos

    There are a lot of selection actors that you can check out by searching for "select" among the actors in the data editor. I haven't experimented with them, but I imagine you can create one in an event for the model you want to use it for.

    There are also various selection events among the default events that are created for any generic unit actor that you might want to look into.

    Posted in: Triggers
  • 0

    posted a message on Check ability requirement through triggers

    Thanks, but that won't help me unfortunately.

    I'm talking about abilities that are grayed out just because their requirements (in the data editor) are not met.

    A few examples are how

    • you can't build Photon Cannons without Forge
    • you can't build Marauders without an attached Tech Lab

    How can you check whether the buttons are grayed out, without checking for the requirements themselves? (As this would require a lot of work to cover all the different abilities with their various requirements)

    Posted in: Triggers
  • 0

    posted a message on Change color of Fog of War

    When you move away from an area you have explored, the fog of war covers up the area you were just in. Is it possible to change the color of this fog?

    Posted in: Data
  • 0

    posted a message on Check ability requirement through triggers

    Bump

    Posted in: Triggers
  • 0

    posted a message on Determine abilities target type

    @Simbob: Go

    The code I posted is just example code. Triggering ability must be replaced with your ability variable.

    Set Variable
        Variable: scope //A string variable
        Value: Catalog Entry Scope //This is the catalog function you must use to retrieve an ability's scope
            Catalog: Abilities //Here you select the data type of the entry you want to retrieve the scope from.
            Entry: Convert Game Link To String //The entry must be written in string form, so we convert the ability to a string. An ability is a game link.
                Value: Ability Of Ability Command //Here you can specify the ability directly if you have it in a variable, or you can get the ability by using the function 'Ability Of Ability Command'.
                    Ability Command: Triggering Ability
    
    Debug - Display (Text(scope)) as debug output using Type 1, and Do display it in the game window //it's a good idea to debug you code before you use it. Check what scope is and then write the code for the switch afterwards.
    

    I don't know if the comments will do any good. Basically, the function Catalog Entry Scope takes an ability/unit/other object and gives you the type of that object as you see it in the data editor after you press Ctrl + D.

    Be sure to add all the ability types you need in the switch. I just added the two I use the most as an example.

    Edit: By the way, this method will not differentiate between unit target and point target abilities, since that is defined in the effect run by the ability. If you need this functionality you could use catalog functions to dig deeper into the ability and find it's target in the effects used by it. Although, this is not a task to take lightly. With the various ability types and effect types, the code is bound to get very complex, really fast. Only do it if you have no other way.

    Posted in: Triggers
  • 0

    posted a message on Check ability requirement through triggers

    Bump

    Posted in: Triggers
  • 0

    posted a message on Determine abilities target type

    @Simbob: Go

    Check the ability's scope, and use a switch to differentiate between the different target types.

    Set Variable
        Variable: scope
        Value: Catalog Entry Scope
            Catalog: Abilities
            Entry: Convert Game Link To String
                Value: Ability Of Ability Command
                    Ability Command: Triggering Ability
    
    General - Switch (Actions) depending on scope
        Cases
            General - If ("CAbilEffectInstant")
                Actions
            General - If ("CAbilEffectTarget")
                Actions
            Default
    
    Posted in: Triggers
  • 0

    posted a message on Check ability requirement through triggers

    @SouLCarveRR: Go

    It's for a system that needs to know if an ability, out of a pool of many different possibilities, is available for use.

    I won't go into details, since it is quite elaborate. Let's just say being able to tell if an ability meets it's requirements or not would help immensely

    Posted in: Triggers
  • 0

    posted a message on Ability Targets

    @PatchOne: Go

    The only effect which controls what targets an ability can have, is the immediate effect run by this ability. To keep the ability unit targetable while still having it damage at a point, simply create a chain like this:

    Ability -> Set Effect (Target: Unit) -> Damage Effect (Target: Point)

    The damage effect will target the point of the target unit's position

    Edit: However, from my testing; a damage effect with Target Unit can still deal damage to an area.

    Posted in: Data
  • To post a comment, please or register a new account.