anyone can make a mod to make army organize into groups and auto attack?

Thank-you. I got burned out with modding working on a humongous mod for civ v(something like 5,000 files--Not all me had been a community project), so I'm trying to keep it simple for a while.



One problem was I had it checking health only if a unit was in range, I changed that so it'll check before.

I have an idea, when the unit lost too much health, they run out of a certain distance towards nearest city then stop. If no enemy near , they just wait until health is full . Then keep going
 
I've changed/added a few things, s you can see if this works any better. I still have to work out a method if you want them to actively track down enemy units, but you can try this for now. I tested by placing units around/near city states and declaring war, then basically hitting next turn until they conquered the city.
 

Attachments

  • AttackTest.zip
    30.8 KB · Views: 84
Also, for now, until I work in a better method, non ranged units will only attack if their total strength is greater than enemy(and not too wounded)
my army find enemy range is a little small, how can I change it larger?
 
sorry, I've had hectic schedule this past week, haven't been able to work on any mods. Hopefully should be slowing down a little now. How is the current part working, any problems/adjustments I would need to know about?

actually, when I use "guard " ,unit do nothing most of time.
I set "elseif (iDist < (iSight + 3 ))" very high, they still stay there.
 
Last edited:
Top Bottom