Hey I've been working on a map of mine for a long time and I'm at one of the last obstacles to finally getting solid core mechanics to it finished.
In my map there are weapons that target dummy units to give the impression of targeting points. I've decided using actual attacks and not abilites is the way to go for a number of reasons, the primary's being A: from what I've seen abilities can't be set up to function with turrets and will fire regardless of turret facing and B: it will be much easier to implement fire rates.
So I've created my dummy target, designated psionic as my target attribute and given it to the weapon and unit. It all works fine, when the target belongs to an enemy, but seeing as I may be planning up to 12 players this will obviously lead to weapons mixing up targets. The only plausable option I can see is having each target belong to the player targeting it, so I want the weapon to auto aquire psionic units that belong to the player.
I've messed around with the target filters and scan filters a bunch and they don't seem to allow the wep to auto target friendlies. I'm thinking theres a way to do it though putting a behavior on the target or attacker, but I'm not sure what options to set?
Hey thanks that worked, for the most part, but its come with a problem. My units need to attack while on the move. With this new attack ability they will aquire the target while standing still, and will continue to target/attack it while moving, but if the dummy target leaves the scan range then comes back in they will not retarget it until the unit is not moving again.. Basically they are only aquiring targets while not moving. This didn't happen using the default attack abil, they would target and retarget moving or still.
I have continuous scan on, excluded self, and every single thing else I could from the filter on the target abil and the weapon. I'm kind of wondering if it's continuous scan is coded only to check for enemies, or does it just run any attack class abils, or maybe only the default attack abil. Any idea what the problem might be?
attacking on the move~ while walking? if thats what your looking for see the diamond backs ability to do this. copy that for your unit. the issue you might run into is if you have your units fire on friends/ally and the like you might be making an army that kills itself, lol. marine shot marine in the head for standing to close, hahaha. if your vs 8 other people wouldnt they be enemy? or you making them ally's and then want your units to shoot them? Edit: or do you want to make the unit you attack apart of your army, such as you aquire that unit that you attacked? just trying to understand where your comming from...
Lol, if you read earlier posts you'd see there are no "armies" in my map.
You control one unit and it will always aim/shot at the point you target, but can also be moving while doing this. I'm using invisible dummy targets to get the unit to target points, if any dummy target can be targeted by more than one player their weapons will mess up when they get close to each other and target the wrong points.
I've already made a unit from scratch that can attack and move at the same time, it's just when I change the default attack abil to the custom attack that only targets the players units that I get this stupid problem where the unit will not retarget if it is moving. If he locks on while at a dead stop then starts moving, he will attack and move no problem till you move your target out of range, then he will not attack till you come to a stop again.
Obvious work around is triggers telling the units to constantly attack the right target, but this would create a fair amount of drain on the game and I'm hoping to avoid that.
Just choose the weapon that you want and make sure that the field Weapon: Allowed Movement is set to Moving.
You also need to make sure Weapon: Options + has the flags Only Fire At Attack Target and Only Fire While Attacking is unchecked (if it isn't already).
Don't forget to add in an angle for Stats: Arc as well; i.e put 360 if you want your unit to be able to fire on the move while attacking units in any direction if your unit doesn't have a turret for its weapon.
@Drunkenseagull:
I've already made a unit from scratch that can attack and move at the same time, it's just when I change the default attack abil to the custom attack that only targets the players units that I get this stupid problem where the unit will not retarget if it is moving. If he locks on while at a dead stop then starts moving, he will attack and move no problem till you move your target out of range, then he will not attack till you come to a stop again.
you need to change the scan for targets range. such as if your weapon range is at 6 and your still within the range of the scan thats 14 then you will still have weapon lock on target. change the 14 to 6 and it should release the target for another one thats within 6. but if you target 1 unit and stay within 6 of that target then you will not reaquire a new target till you manualy change targets or move out of range of 6.
its like how a siege tank in siege mode can move turret for targets while its not moving it self. still picking up the enemy signature.
Hey thanks for the suggestions guys but I've had all these fields filled in exactly like this and still getting the problem. Again the unit works totally fine when using the regular attack ability and having the dummy target belong to an enemy, its only when the dummy belongs to the player and using the custom attack ability that he wil not retarget when the dummy leaves range.
The only scan field I can see on the weapon is Minimum Scan Range, I've tried every number in here from 0 to 100, well almost, and still nothing ><. FYI I'm just moving the same dummy target every 0.05 seconds, not making a new one each time.
At this point I'm thinking it might be easier to just have everyone's target belong to one player that is enemy to all, and somehow make each of them targetable by only 1 player.. Any ideas on how to do this?
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Hey I've been working on a map of mine for a long time and I'm at one of the last obstacles to finally getting solid core mechanics to it finished.
In my map there are weapons that target dummy units to give the impression of targeting points. I've decided using actual attacks and not abilites is the way to go for a number of reasons, the primary's being A: from what I've seen abilities can't be set up to function with turrets and will fire regardless of turret facing and B: it will be much easier to implement fire rates.
So I've created my dummy target, designated psionic as my target attribute and given it to the weapon and unit. It all works fine, when the target belongs to an enemy, but seeing as I may be planning up to 12 players this will obviously lead to weapons mixing up targets. The only plausable option I can see is having each target belong to the player targeting it, so I want the weapon to auto aquire psionic units that belong to the player.
I've messed around with the target filters and scan filters a bunch and they don't seem to allow the wep to auto target friendlies. I'm thinking theres a way to do it though putting a behavior on the target or attacker, but I'm not sure what options to set?
Thanks
The Attack ability is what you want, that has additional filters for the auto aquire.
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
Crap, so obvious! Why didn't I think to look there when I had the same issue! Been using an excessive Issue order efect to attack the dummy unit ;/
Hey thanks that worked, for the most part, but its come with a problem. My units need to attack while on the move. With this new attack ability they will aquire the target while standing still, and will continue to target/attack it while moving, but if the dummy target leaves the scan range then comes back in they will not retarget it until the unit is not moving again.. Basically they are only aquiring targets while not moving. This didn't happen using the default attack abil, they would target and retarget moving or still.
I have continuous scan on, excluded self, and every single thing else I could from the filter on the target abil and the weapon. I'm kind of wondering if it's continuous scan is coded only to check for enemies, or does it just run any attack class abils, or maybe only the default attack abil. Any idea what the problem might be?
Lol yeah, exactly the thing I'm trying to avoid >.<, or a trigger doing the same
Bump, really need a solution to this, or at least a work around that will not use too much resource, I know it's an odd problem.
@Drunkenseagull:
attacking on the move~ while walking? if thats what your looking for see the diamond backs ability to do this. copy that for your unit. the issue you might run into is if you have your units fire on friends/ally and the like you might be making an army that kills itself, lol. marine shot marine in the head for standing to close, hahaha. if your vs 8 other people wouldnt they be enemy? or you making them ally's and then want your units to shoot them? Edit: or do you want to make the unit you attack apart of your army, such as you aquire that unit that you attacked? just trying to understand where your comming from...
Lol, if you read earlier posts you'd see there are no "armies" in my map.
You control one unit and it will always aim/shot at the point you target, but can also be moving while doing this. I'm using invisible dummy targets to get the unit to target points, if any dummy target can be targeted by more than one player their weapons will mess up when they get close to each other and target the wrong points.
I've already made a unit from scratch that can attack and move at the same time, it's just when I change the default attack abil to the custom attack that only targets the players units that I get this stupid problem where the unit will not retarget if it is moving. If he locks on while at a dead stop then starts moving, he will attack and move no problem till you move your target out of range, then he will not attack till you come to a stop again.
Obvious work around is triggers telling the units to constantly attack the right target, but this would create a fair amount of drain on the game and I'm hoping to avoid that.
@Drunkenseagull: Go
Weapon Flags.
Fire While Moving is one flag, theres another you need to tick. Been ages since I've checked.
You can easily do this through data.
Just choose the weapon that you want and make sure that the field Weapon: Allowed Movement is set to Moving. You also need to make sure Weapon: Options + has the flags Only Fire At Attack Target and Only Fire While Attacking is unchecked (if it isn't already).
Don't forget to add in an angle for Stats: Arc as well; i.e put 360 if you want your unit to be able to fire on the move while attacking units in any direction if your unit doesn't have a turret for its weapon.
@Drunkenseagull:
I've already made a unit from scratch that can attack and move at the same time, it's just when I change the default attack abil to the custom attack that only targets the players units that I get this stupid problem where the unit will not retarget if it is moving. If he locks on while at a dead stop then starts moving, he will attack and move no problem till you move your target out of range, then he will not attack till you come to a stop again.
you need to change the scan for targets range. such as if your weapon range is at 6 and your still within the range of the scan thats 14 then you will still have weapon lock on target. change the 14 to 6 and it should release the target for another one thats within 6. but if you target 1 unit and stay within 6 of that target then you will not reaquire a new target till you manualy change targets or move out of range of 6.
its like how a siege tank in siege mode can move turret for targets while its not moving it self. still picking up the enemy signature.
@Nardival: Go
@sgtnoobkilla: Go
Hey thanks for the suggestions guys but I've had all these fields filled in exactly like this and still getting the problem. Again the unit works totally fine when using the regular attack ability and having the dummy target belong to an enemy, its only when the dummy belongs to the player and using the custom attack ability that he wil not retarget when the dummy leaves range.
@tdhsst: Go
The only scan field I can see on the weapon is Minimum Scan Range, I've tried every number in here from 0 to 100, well almost, and still nothing ><. FYI I'm just moving the same dummy target every 0.05 seconds, not making a new one each time.
At this point I'm thinking it might be easier to just have everyone's target belong to one player that is enemy to all, and somehow make each of them targetable by only 1 player.. Any ideas on how to do this?