Announcement

Collapse
No announcement yet.

Array not working

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

    Array not working

    Hi
    Can anyone tell me why my array is empty? I get only one fail message on screen. The array should have 20 objects in it.
    Attached Files

    #2
    I connected the completed to the return node.. doh! So the array fills up now. But all the objects are invalid.

    Comment


      #3
      Test1Ref is an invalid class, or you are nullifying the elements outside of those screenshots.
      Marketplace Assets

      Advanced Mobile Input: Marketplace Page | Support Thread ――― Easy Input Remapping: Marketplace Page | Support Thread
      Multiplayer Blueprint Chat System: Marketplace Page | Support Thread ――― Closing Credits System: Marketplace Page | Support Thread
      Minesweeper Template: Marketplace Page | Support Thread ――― Maze Creator: Marketplace Page | Support Thread

      Comment


        #4
        Thanks for the reply! Is there something i need to check withing the Test1Ref class itself? Its a child of a actor class that contains a bunch of variables using a struct. When i created the reference i choose it from the list. So the class exists. The function is getting called from the Widget. theres no other thing happening to it inbetween. Can it be im calling a game instance from a Widget? Can that cause problems?
        Last edited by P19923; 03-17-2017, 04:17 PM.

        Comment


          #5
          Ah ah

          I found out.

          You're leaving your function at each loop!

          Just make it so the Game Instance function returns the temporary array after the loop has "Completed" and not at each loop.

          EDIT: I was starring at both images and was like "I know there is something wrong here, I just need to find out what". And all of a sudden, yeah \o/
          [Released] Multiplayer Combat Editor
          A-RPG Sacred Swords
          Auto-Chess Live Development
          Youtube Tutorials

          Comment


            #6
            Thank you!

            Comment

            Working...
            X