Announcement

Collapse
No announcement yet.

Spawning Ai

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Spawning Ai

    AnyOne Got Any Idea How I Can Create A Blueprint That Will About 10Ai In The Map But The Keep Increasing The NUmber so when It Spawns Again It Woll Spawn 11 Then 12 Many Thanks

    #2
    For Loop with an Int variable for the Max Iterations or Loops. Example, NumToSpawn. Plug that NumToSpawn variable into the Max connection for the For Loop. On the Complete, increment the NumToSpawn +1. Next time it runs the loop, it will be a higher number.

    Comment


      #3
      I Cant Find A Loop That Says Max Connection On It Please Help

      Comment


        #4
        For Loops take a number for how many times they should loop. Make sure its just a For Loop not a For Each Loop

        Comment


          #5
          Originally posted by GamingAsh View Post
          I Cant Find A Loop That Says Max Connection On It Please Help
          It's just a "For Loop", whatever the last input is that is close to a maximum number of times or iterations. I forget what it actually says on the node itself. When you type "for loop" on the context-sensitive helper, select the For Loop and it comes with two Integer connections. The bottom one is what I was referring to.

          Comment


            #6
            ok thanks mate il try that

            Comment


              #7
              Click image for larger version

Name:	Untitled.png
Views:	1
Size:	254.5 KB
ID:	1082587 does this look right

              Comment


                #8
                this is ony spawning 1 and then does nothing

                Comment


                  #9
                  Works Now Thanks Just Got To Work Out How To Make it count players

                  Comment


                    #10
                    Well, first of all you have to give the NumtoSpawn variable a higher number than 0 to start with. Second, take out that ++ node (it will not work unless you "power it up", need to have the Exec connections hooked up to something), hook the NumtoSpawn directly to the Last Index (thank you) connection. On the Complete, drag out a line and Set NumtoSpawn. Drag a line out from the left connection and hook an Integer + Integer node to it. Plug the NumtoSpawn into one connection on the Integer + Integer node and put a 1 in the other.
                    Last edited by Yggdrasil; 07-27-2015, 01:08 PM.

                    Comment


                      #11
                      The count of players is in the NumtoSpawn. If you give it 10, you will have 11 NPCs spawned in. If you give NumtoSpawn the number 17, you will have 18 NPCs spawned in. With the First Index on the For Loop set to 0, it will count from 0 to whatever NumtoSpawn is set to, so in effect you will have NumtoSpawn+1 NPCs spawned into the level.

                      Comment


                        #12
                        Click image for larger version

Name:	hh.png
Views:	1
Size:	267.1 KB
ID:	1082623 is this right

                        Comment


                          #13
                          this isnt working this way i just spawns five every time

                          Comment


                            #14
                            it works but 5 is it max it wont spawn any more than five at a time

                            Comment


                              #15
                              if its not to much can someone take some photos of how i would count how many players are in game thanks

                              Comment

                              Working...
                              X