how to make smarter zombies

helpmeplease

New Member
Reaction score
7
hey. im making a zombie map and i want them to kill all civilians and hero's.. but at the moment they just stand there. a few in the front rows move but the rest stay back.. i want them to roam around killing aimlessly. any suggestions plz?
 
A trigger like this might help out somewhat:

Trigger:
  • Random Move
    • Events
      • Time - Every 5.00 seconds of game time
    • Conditions
    • Actions
      • Set TempGroup = (Units of type Zombie)
      • Unit Group - Pick every unit in TempGroup and do (Actions)
        • Loop - Actions
          • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Current order of (Picked unit)) Equal to (==) (Order(none))
            • Then - Actions
              • Set TempPoint = (Random point in (Playable map area))
              • Unit - Order (Picked unit) to Attack-Move To TempPoint
              • Custom script: call RemoveLocation(udg_TempPoint)
            • Else - Actions
      • Custom script: call DestroyGroup(udg_TempGroup)
 
Assuming the zombies are of Neutral Hostile and civilians are Neutral Passive, have Neutral Hostile unally Neutral Passive.

Give zombie units Wander (Makes them move by themselves).

If that won't work, set a variable to a random point in playable map area, set a variable to every zombie in playable map area, pick every unit in variable group and order picked unit to attack-move to variable point, then destroy variable point.

[Edit] Ghan beat me to it with an actual trigger, damn
 
A trigger like this might help out somewhat:

Trigger:
  • Random Move
    • Events
      • Time - Every 5.00 seconds of game time
    • Conditions
    • Actions
      • Set TempGroup = (Units of type Zombie)
      • Unit Group - Pick every unit in TempGroup and do (Actions)
        • Loop - Actions
          • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Current order of (Picked unit)) Equal to (==) (Order(none))
            • Then - Actions
              • Set TempPoint = (Random point in (Playable map area))
              • Unit - Order (Picked unit) to Attack-Move To TempPoint
              • Custom script: call RemoveLocation(udg_TempPoint)
            • Else - Actions
      • Custom script: call DestroyGroup(udg_TempGroup)


wats the variable for tempPointplz?
 
Another thing you can do to make the zombies "smarter"/more exciting is to make an ability that gives them max movement speed for a few seconds, and trigger it so that they cast it when an enemy unit comes within it's aquisition range
 
> wats the variable for tempPointplz?

It's a Point variable.
 
thanks everyone. :D

> wats the variable for tempPointplz?

It's a Point variable.



ummm... i made the zombies neutral hostile and the civilains passive. but now the zombies walk around aimlessly... only attacking someone if its me... advice? i want the zombies to focus more on civilians than me..
 
Take off wander.


Make a trigger that orders the zombie to attack-move to a random point in your area every 12 seconds, so it looks like wander
 
How many players max are you planning on having? If you plan on having a maximum of 10 players, then it might be easier to set Zombies to Player 12 and Civilians to Player 11, then use this trigger:

Trigger:
  • Alliances
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Set inGamePlayers = (All players matching ((((Matching player) controller) Equal to User) and (((Matching player) slot status) Equal to Is playing)))
      • Player Group - Make inGamePlayers treat Player Group - Player 11 (Dark Green) as an Ally with shared vision
      • Player Group - Make inGamePlayers treat Player Group - Player 12 (Brown) as an Enemy
      • Player Group - Make Player Group - Player 11 (Dark Green) treat inGamePlayers as an Ally with shared vision
      • Player Group - Make Player Group - Player 11 (Dark Green) treat Player Group - Player 12 (Brown) as an Enemy
      • Player Group - Make Player Group - Player 12 (Brown) treat Player Group - Player 11 (Dark Green) as an Enemy
      • Player Group - Make Player Group - Player 12 (Brown) treat inGamePlayers as an Enemy


This will make all Zombies (Player 12) treat Civilians (Player 11) and all players (Player Group variable inGamePlayers) as enemies, while everyone treats them as enemies. Also, it'll ally Civilians and players. However, if you use that, make sure to set the settings like they are here:







Avaleirrra's idea of making them attack-move to random points in your region/playable map area every 12 seconds is a good one. In any case, to make them attack civilians, the best way I know is to use the trigger I have here and the command 'attack-move'.
 
Another thing you can do to make the zombies "smarter"/more exciting is to make an ability that gives them max movement speed for a few seconds, and trigger it so that they cast it when an enemy unit comes within it's aquisition range

This is good.
 
You could order them to Attack 'random unit from unit group (Units Matching Condition: (Owner of Matching) Unit is an ally of Player (Zombie Controller) equal to false)'
Note: Done freehand, tell me if too hard to understand
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • The Helper The Helper:
    News portal has been retired. Main page of site goes to Headline News forum now
  • The Helper The Helper:
    I am working on getting access to the old news portal under a different URL for those that would rather use that for news before we get a different news view.
  • Ghan Ghan:
    Easily done
    +1
  • The Helper The Helper:
    https://www.thehelper.net/pages/news/ is a link to the old news portal - i will integrate it into the interface somewhere when i figure it out
  • Ghan Ghan:
    Need to try something
  • Ghan Ghan:
    Hopefully this won't cause problems.
  • Ghan Ghan:
    Hmm
  • Ghan Ghan:
    I have converted the Headline News forum to an Article type forum. It will now show the top 20 threads with more detail of each thread.
  • Ghan Ghan:
    See how we like that.
  • The Helper The Helper:
    I do not see a way to go past the 1st page of posts on the forum though
  • The Helper The Helper:
    It is OK though for the main page to open up on the forum in the view it was before. As long as the portal has its own URL so it can be viewed that way I do want to try it as a regular forum view for a while
  • Ghan Ghan:
    Yeah I'm not sure what the deal is with the pagination.
  • Ghan Ghan:
    It SHOULD be there so I think it might just be an artifact of having an older style.
  • Ghan Ghan:
    I switched it to a "Standard" article forum. This will show the thread list like normal, but the threads themselves will have the first post set up above the rest of the "comments"
  • The Helper The Helper:
    I don't really get that article forum but I think it is because I have never really seen it used on a multi post thread
  • Ghan Ghan:
    RpNation makes more use of it right now as an example: https://www.rpnation.com/news/
  • The Helper The Helper:
  • The Helper The Helper:
    What do you think Tom?
  • tom_mai78101 tom_mai78101:
    I will have to get used to this.
  • tom_mai78101 tom_mai78101:
    The latest news feed looks good
  • The Helper The Helper:
    I would like to see it again like Ghan had it the first time with pagination though - without the pagination that view will not work but with pagination it just might...
  • The Helper The Helper:
    This drink recipe I have had more than a few times back in the day! Mind Eraser https://www.thehelper.net/threads/cocktail-mind-eraser.194720/

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top