Staredit Network > Forums > SC1 UMS Mapmaking Assistance > Topic: Stopping a Critter from Wandering
Stopping a Critter from Wandering
Nov 12 2008, 3:24 am
By: SelfPossessed  

Nov 12 2008, 3:24 am SelfPossessed Post #1



I need a cure for ADHD to stop the critters.

Basically, I have a spell that summons critters (up to 11) for the enemy (don't ask why, I still need to test how effective this is). I need the critters to stay still but still attack-able. Note that there will be other spells that can move these critters.

Solution 1 (trying to avoid this):
- Have a separate location for each critter that keeps track of them. Order them constantly to move to that location.
- This is absolute hell when trying to code spells that can move them as I have to move their locs with them. In the worst cast scenario, I will do this.

Solution 2:
- Keep moving the critters to a location outside the map.
- I need to learn how to do this (don't know how).
- It might cause attacks to miss them, which would be bad.

Help would be appreciated. Thanks.



None.

Nov 12 2008, 3:36 am Morphling Post #2



I'm not sure, but I think if computer players own them they will not move.



None.

Nov 12 2008, 3:37 am SelfPossessed Post #3



I gave the critters to the computer, but they keep moving. :(



None.

Nov 12 2008, 3:39 am Morphling Post #4



When i tried it, it worked. Maybe it was because i preplaced them. Maybe try preplacing them and move them when needed.



None.

Nov 12 2008, 3:42 am SelfPossessed Post #5



That's interesting. Hrmm.

Still, I need them to be created via triggers as you need to be able to kill and recreate them. :(



None.

Nov 12 2008, 3:43 am Ultraviolet Post #6



I just had an idea. Cycle through them with 1 location, by giving them to p9 after you cycle. Like this:

Conditions:
Enemy (whichever player this is) brings at least 1 critter to anywhere

Actions:
Move location labeled Critter (or whatever) on critter owned by enemy at anywhere.
Order critter at Critter to move to Critter
Give 1 critter at Critter to Player 9
Preserve

Then:

Conditions:
Enemy brings at most 0 critter to anywhere

Actions:
Give all critters owned by P9 at anywhere to Enemy
Preserve





Nov 12 2008, 3:49 am SelfPossessed Post #7



The cycling will cause attacks to miss.

At this rate, it looks like I'm going to have to use 11 individual locations to keep track of critters. It's just so...tedious trigger wise. It makes the least complex of my spells the most complex in coding. :(



None.

Nov 12 2008, 4:01 am Ultraviolet Post #8



Do melee attacks need to be able to hit them? If not, you could make a dt prison around them upon creation.




Nov 12 2008, 4:02 am SelfPossessed Post #9



Yes, melee and ranged attacks must be able to hit them.



None.

Nov 12 2008, 4:05 am Ultraviolet Post #10



Could create a DT wall in such a way that melee could still hit them, but they couldn't get out. You'd make a cross shape, basically

X = critter O = DT

_O
OXO
_O





Nov 12 2008, 4:09 am Kaias Post #11



Extend the dimensions and create a location there, then put the dimensions of the map back.
Just move unit action the critters to the location outside the map. I think you can still attack them.



None.

Nov 12 2008, 4:13 am Ultraviolet Post #12



Quote from Kaias
Extend the dimensions and create a location there, then put the dimensions of the map back.
Just move unit action the critters to the location outside the map. I think you can still attack them.

You can attack them, but the attack misses approximately 50% of the time.




Nov 12 2008, 4:18 am SelfPossessed Post #13



@ Morphling

I figured it out. Basically, critters on creation for a computer don't move. But once you attack them, they move once, then being their wandering AI. I need them attack-able, but to stand still while being attacked.

@ NerdyTerdy

I don't want a DT wall. That would screw with a ton of stuff on the map. That and gridding a DT wall would be near impossible. I'd need to use a coordinate grid to be accurate; mobile grids will screw up as I have air units.

@ Kaias

I'm hoping that moving a critter outside the map instead of to an un-placable area will cause attacks to NOT miss them. If this is the case...

Could you clarify this process? I tried making a 500x500 dimension location, then setting it back to 64x64 on the test map. I then moved the critter there, but it moved to a strange spot. I'm doing something wrong...



None.

Nov 12 2008, 4:20 am Ultraviolet Post #14



Kaias' process will still cause the issues with only being able to hit the unit 50% of the time.




Nov 12 2008, 4:21 am Falkoner Post #15



Quote
Could you clarify this process? I tried making a 500x500 dimension location, then setting it back to 64x64 on the test map. I then moved the critter there, but it moved to a strange spot. I'm doing something wrong...

Just double click the location, and edit its coordinates so it is outside the map. And it will hit less than 50% of the time, unless you use a death count to slow the rate at which it is moved.

At that point, you might as well do the cycling, it won't cause attacks to miss, it will just cause the attacking units to lose their target temporarily.



None.

Nov 12 2008, 4:28 am SelfPossessed Post #16



Losing the target equates to missing if the cycling is done fast enough.

Looks like I'll just have to do it the long and hard way; keep track of each individual critter (oh dear lord it's long as hell to trigger). It's that or I have to revamp the entire critter concept. Like, have the critters continuously follow your air unit pet. Which...might work, but severely limits its applications.



None.

Nov 12 2008, 4:29 am Falkoner Post #17



If you just throw a death count timer in there, you can limit the ordering to like every half a second, and that would make it happen less.



None.

Nov 12 2008, 4:31 am Kaias Post #18



You could try telling them to patrol to a very small offset.



None.

Nov 12 2008, 4:33 am SelfPossessed Post #19



@ Kaias

Just tried it. They still run after getting hit.



None.

Nov 12 2008, 5:33 am Madroc Post #20



Quote from name:NerdyTerdy
I just had an idea. Cycle through them with 1 location, by giving them to p9 after you cycle. Like this:

Conditions:
Enemy (whichever player this is) brings at least 1 critter to anywhere

Actions:
Move location labeled Critter (or whatever) on critter owned by enemy at anywhere.
Order critter at Critter to move to Critter
Give 1 critter at Critter to Player 9
Preserve

Then:

Conditions:
Enemy brings at most 0 critter to anywhere

Actions:
Give all critters owned by P9 at anywhere to Enemy
Preserve
What's wrong with this? It seems perfect.



None.

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[01:53 am]
Ultraviolet -- :lol:
[06:51 pm]
Vrael -- It is, and I could definitely use a company with a commitment to flexibility, quality, and customer satisfaction to provide effective solutions to dampness and humidity in my urban environment.
[06:50 pm]
NudeRaider -- Vrael
Vrael shouted: Idk, I was looking more for a dehumidifer company which maybe stands out as a beacon of relief amidst damp and unpredictable climates of bustling metropolises. Not sure Amazon qualifies
sounds like moisture control is often a pressing concern in your city
[06:50 pm]
Vrael -- Maybe here on the StarEdit Network I could look through the Forums for some Introductions to people who care about the Topics of Dehumidifiers and Carpet Cleaning?
[06:49 pm]
Vrael -- Perhaps even here I on the StarEdit Network I could look for some Introductions.
[06:48 pm]
Vrael -- On this Topic, I could definitely use some Introductions.
[06:48 pm]
Vrael -- Perhaps that utilizes cutting-edge technology and eco-friendly cleaning products?
[06:47 pm]
Vrael -- Do you know anyone with a deep understanding of the unique characteristics of your carpets, ensuring they receive the specialized care they deserve?
[06:45 pm]
NudeRaider -- Vrael
Vrael shouted: I've also recently becoming interested in Carpet Cleaning, but I'd like to find someone with a reputation for unparalleled quality and attention to detail.
beats me, but I'd make sure to pick the epitome of excellence and nothing less.
[06:41 pm]
Vrael -- It seems like I may need Introductions to multiple companies for the Topics that I care deeply about, even as early as Today, 6:03 am.
Please log in to shout.


Members Online: Roy