Didn't think I would run into more problems but here we go:
I want to make an ability which enables a unit to path through buildings for the duration.
The other thing I have trouble with:
Imagine a hero unit, with a learn-ability and several skills. One ability the hero can learn is a toggle-able behavior, pretty simple. That ability has three ranks. So far so good. I want him to be able to learn a different "ability" though, which improves the toggle-able ability passively. I know that upgrades can modify behaviors. How can I connect the learn ability with upgrades? Validators? Might be messy - anyone having a better idea?
Edit: The pathing ability is only for a single unit to cast it on itself, so triggers that target all units of that type are allowed. I am thinking about duplicating the unit and disabling the buildings pathing checkbox on it and just make the ability a morph-ability.
The important part is that the unit can move through buildings. It doesn't need to be able to path through units. It should in no case be able to path over cliffs or doodads.
Make the second "passive" ability apply permanent buffs containing the "improvements", and use the Validators (Disabled) field on said buffs to deactivate them whenever the unit doesn't have the toggle on. Won't work well with damage responses and the like, in that case you'll have to fully replace the buffs.
As for the structure collision, I don't know what "buildings pathing" flag you mean, but if that works definitely use the morph. SoulFilcher once tried this by messing with Footprints, which iirc ended up wrecking resource collection and/or unit pathing, and I don't remember if it even worked in the end.
One thing you can try, which will still require a morph, is to set an additional collision plane in Movement: Collide + for all units and then un-ticking the Ground and Forcefield planes for your morphed phasing unit. At least I think that's how they allow Roaches to move under Forcefields.
Well, okay, so Validators - like I thought, I think that will work, might just become a bit messy, I hoped there was a cleaner solution.
As for the collision ability - it seems like it's not that easy. I messed around a bit and nothing really seems to work. Even if I remove ALL collision flags the unit refuses to automatically path through buildings (it will still behave like they are in the way). If you spam-click you can even walk up cliffs then >_<
Any idea how to make that ability? I just want my unit to be able to path through buildings for about 1 second. So a small teleport would work too, the problem is that doodads and cliffs HAVE to stay unpassable.
Imagine trees giving 1x1 spots but the unit has a bigger radius, so can't get through that spot. It should still be unable with that ability, but it should just walk through buildings.
Have you tried giving the unit the Burrowed mover which the Roach uses?
I think the problem is the Pathing Footprint on the structures. With it units will seemingly always pathe around the structure, without it they will mindlessly run into it if they still collide (army vs Forcefield).
I don't think this can be done properly, as footprints are severely lacking.
So, why exactly do the phaseable objects have to be structures? Do you need pathing footprints on them? If you remove that it should work, but that's definitely not an option for mazing TD maps and the like.
Cat and Mouse style game. Big scary Titan is 2x2, builders are 1x1. Walls (aka buildings) can be used to create 1x1 spots. There are natural 1x1 spots created by trees.
You have to be unable to get through the 1x1 spots which the trees provide, but you have to somehow get through the artifical 1x1 spots the buildings create, e.g. by ignoring the building.
I cannot change much about the units still into the game as it is not my map, but I usually add units to the game.
This is definitely a problem. If it was wc3, I would say use different pathing layers for each entity, E.g. Water pathing for buildings. However, since sc2 only has 4 that I am aware of: Air, (cant be used since you cant block it afaik) Pathable, Cliff, buildable. It might have more, but I was unable to locate any information on it last time I checked.
One solution, although it would totally break path finding, would be to use a repulsion aura on each building, excluding builders + titans with bypass buff. Unfortunately, this is both inefficient, and would make all units think they can walk through the building, which would just block them when they get close.
You could have an aura on the Titan when bypass is active, which applies supply-depot lower based effect to the buildings in range. Would allow other units to bypass too however.
That would only take a Persistent, the two Morph abilities, and an Issue Order effect for each of them. Morphing the structure is a pain with upgrades though (ever played Vampirism in WC3, where there were like 5-10 upgrades for walls on each tech tier? You'd have to copy all those effects for the morph version)
In the scenario you describe you should try removing the pathing footprint (or have the main map maker do it for you), as stupidly headbutting the wall doesn't sound like much of a problem. Then morph the attacking unit to emulate a burrowed Roach as described above.
Removing the pathing footprint doesn't work, headbutting the wall is exactly what we want, but builders with the gather ability can walk through buildings that don't have a footprint when they gather.
2) Have the booster ability levels add a Behavior type ability that is not toggleable and on by default. This adds buffs used by Unit Compare Behavior Count validators that Switch effects in your primary ability tree use to determine what to use. Else use Catalog triggers.
3) Without footprints the Supress Collision flag on buffs does that.
Rollback Post to RevisionRollBack
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
What should that be an answer to? Do you mean the "cat" has access to 1x1 units too, so "mouse" players could then block these out while still being able to escape?
It doesn't matter that much, I made a different ability now - this is just too much trouble for what it's worth. The solution I would take if I had access to the map would be to make morph abilities on all buildings and make a behavior with a periodic effect that issues all nearby buildings to morph when the unit comes close.
But like I said, I don't have access to the map.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Didn't think I would run into more problems but here we go:
I want to make an ability which enables a unit to path through buildings for the duration.
The other thing I have trouble with: Imagine a hero unit, with a learn-ability and several skills. One ability the hero can learn is a toggle-able behavior, pretty simple. That ability has three ranks. So far so good. I want him to be able to learn a different "ability" though, which improves the toggle-able ability passively. I know that upgrades can modify behaviors. How can I connect the learn ability with upgrades? Validators? Might be messy - anyone having a better idea?
Edit: The pathing ability is only for a single unit to cast it on itself, so triggers that target all units of that type are allowed. I am thinking about duplicating the unit and disabling the buildings pathing checkbox on it and just make the ability a morph-ability.
The important part is that the unit can move through buildings. It doesn't need to be able to path through units. It should in no case be able to path over cliffs or doodads.
Make the second "passive" ability apply permanent buffs containing the "improvements", and use the Validators (Disabled) field on said buffs to deactivate them whenever the unit doesn't have the toggle on. Won't work well with damage responses and the like, in that case you'll have to fully replace the buffs.
As for the structure collision, I don't know what "buildings pathing" flag you mean, but if that works definitely use the morph. SoulFilcher once tried this by messing with Footprints, which iirc ended up wrecking resource collection and/or unit pathing, and I don't remember if it even worked in the end.
One thing you can try, which will still require a morph, is to set an additional collision plane in Movement: Collide + for all units and then un-ticking the Ground and Forcefield planes for your morphed phasing unit. At least I think that's how they allow Roaches to move under Forcefields.
Well, okay, so Validators - like I thought, I think that will work, might just become a bit messy, I hoped there was a cleaner solution.
As for the collision ability - it seems like it's not that easy. I messed around a bit and nothing really seems to work. Even if I remove ALL collision flags the unit refuses to automatically path through buildings (it will still behave like they are in the way). If you spam-click you can even walk up cliffs then >_<
Any idea how to make that ability? I just want my unit to be able to path through buildings for about 1 second. So a small teleport would work too, the problem is that doodads and cliffs HAVE to stay unpassable. Imagine trees giving 1x1 spots but the unit has a bigger radius, so can't get through that spot. It should still be unable with that ability, but it should just walk through buildings.
Have you tried giving the unit the Burrowed mover which the Roach uses?
I think the problem is the Pathing Footprint on the structures. With it units will seemingly always pathe around the structure, without it they will mindlessly run into it if they still collide (army vs Forcefield).
I don't think this can be done properly, as footprints are severely lacking.
So, why exactly do the phaseable objects have to be structures? Do you need pathing footprints on them? If you remove that it should work, but that's definitely not an option for mazing TD maps and the like.
Cat and Mouse style game. Big scary Titan is 2x2, builders are 1x1. Walls (aka buildings) can be used to create 1x1 spots. There are natural 1x1 spots created by trees.
You have to be unable to get through the 1x1 spots which the trees provide, but you have to somehow get through the artifical 1x1 spots the buildings create, e.g. by ignoring the building.
I cannot change much about the units still into the game as it is not my map, but I usually add units to the game.
What if the ability morphs the building into something else? E.g. a unit?
What would I need to do so that after a certain duration it regains it's old state?
This is definitely a problem. If it was wc3, I would say use different pathing layers for each entity, E.g. Water pathing for buildings. However, since sc2 only has 4 that I am aware of: Air, (cant be used since you cant block it afaik) Pathable, Cliff, buildable. It might have more, but I was unable to locate any information on it last time I checked.
One solution, although it would totally break path finding, would be to use a repulsion aura on each building, excluding builders + titans with bypass buff. Unfortunately, this is both inefficient, and would make all units think they can walk through the building, which would just block them when they get close.
You could have an aura on the Titan when bypass is active, which applies supply-depot lower based effect to the buildings in range. Would allow other units to bypass too however.
I cant think of an ideal solution unfortunately.
@Scythe1250: Go
That would only take a Persistent, the two Morph abilities, and an Issue Order effect for each of them. Morphing the structure is a pain with upgrades though (ever played Vampirism in WC3, where there were like 5-10 upgrades for walls on each tech tier? You'd have to copy all those effects for the morph version)
In the scenario you describe you should try removing the pathing footprint (or have the main map maker do it for you), as stupidly headbutting the wall doesn't sound like much of a problem. Then morph the attacking unit to emulate a burrowed Roach as described above.
Removing the pathing footprint doesn't work, headbutting the wall is exactly what we want, but builders with the gather ability can walk through buildings that don't have a footprint when they gather.
@Scythe1250: Go
1) I would go for a hungerling like morph.
2) Have the booster ability levels add a Behavior type ability that is not toggleable and on by default. This adds buffs used by Unit Compare Behavior Count validators that Switch effects in your primary ability tree use to determine what to use. Else use Catalog triggers.
3) Without footprints the Supress Collision flag on buffs does that.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
@Scythe1250: Go
Odd, when I tested it workers couldn't go through Forcefields. Besides, why should the walls block the very unit that built them?
Because the goal is to create 1x1 spaces, not to block something off entirely.
@Scythe1250: Go
What should that be an answer to? Do you mean the "cat" has access to 1x1 units too, so "mouse" players could then block these out while still being able to escape?
It doesn't matter that much, I made a different ability now - this is just too much trouble for what it's worth. The solution I would take if I had access to the map would be to make morph abilities on all buildings and make a behavior with a periodic effect that issues all nearby buildings to morph when the unit comes close.
But like I said, I don't have access to the map.