Announcement

Collapse
No announcement yet.

[SUPPORT] Advanced Turn Based Tile Toolkit

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

    Hi I was following Tracey White's UI Tutorial and ran into some problems at the five minute mark.
    I am using a melee Pawn that I renamed Player_2 instead of Tracy's BallPawn. The timer works on the side but does not display on the widget.
    Is there something I'm missing?

    https://www.youtube.com/watch?v=Mi0S...btiSQY&index=6

    Click image for larger version

Name:	1.png
Views:	1
Size:	515.7 KB
ID:	1092548
    Click image for larger version

Name:	2.png
Views:	1
Size:	440.1 KB
ID:	1092549

    Comment


      Right now I'm also trying to create a level select mechanic. Is there a good way to do it with the Advanced Turn Based Tile Toolkit?

      Comment


        Hi Knut
        I purchased the toolkit for my class project, and to be honest, this is the most awesome thing I've ever bought in the marketplace. Your tutorials are descriptive too. I have some questions regarding to my project using the toolkit. I want the character to have 4 attacking moves (active/passive moves, like in Pokemon) instead of just one move (punching/shooting), will that be possible to implement? And also, can I change the game to player vs player (probably on 1 computer) instead of player vs AI?
        Thank you

        Comment


          Hi all,

          Suddenly, Unit Parent doesn't not compile anymore.
          When I try to compile the blueprint, I suffer an engine crash. This is what I see in the error log:

          <ErrorMessage>Assertion failed: ((UObject*)ContainerPtr)->IsA((UClass*)GetOuter()) [File:\BuildFarm\buildmachine_++depot+UE4-Releases+4.9\Engine\Source\Runtime\CoreUObject\Public\UObject\UnrealType.h] [Line: 308]
          'Pawn_Anim_BP_Ranged_C_156' is of class 'Pawn_Anim_BP_Ranged_C' however property 'StructProperty_1890' belongs to class 'TRASHCLASS_Pawn_Anim_BP_Parent_179'
          </ErrorMessage>

          Is somebody there already found and solved above error?
          My project is stuck because of this

          PS. it happens both with 4.8 and 4.9 UE version. I have added some new pawns but I can't understand why it happen. I guess if the Pawn_Anim_BP_Parent is somehow corrupted.
          Last edited by Wisdom-HELLy; 11-04-2015, 05:41 AM.
          Fantasy Turn-Based Tactical Game
          STEAM: https://store.steampowered.com/app/9...Arcane_Legacy/
          IG: https://www.instagram.com/arcanelegacyofficial/
          FB: https://www.facebook.com/ArcaneLegacy/
          WEB: http://www.arcanelegacy.com

          Comment


            I decided to try a different tactic and I am an not understanding the edge array I think. When I initialize a platform I set an array of all the tile indexes of the platform. That works perfectly with my macro. Then I deactivate all of the platforms by hiding them and setting all all of the side of the edge area for each tile under it to 0. Then When I active a tile I set all of the edges of the tiles under the platform to 1. This does not seem to have the desired effect. In fact the entire grid is able to be walked on like this. Suggestions on what I am doing wrong?

            Comment


              Just a quick message. Sorry for taking a while to get back to you guys. I've had some really busy days. I'll get to answering all of you tonight after work.
              Advanced Turn Based Tile Toolkit (Marketplace - Support)

              Dungeon Crawler Toolkit (Marketplace - Support)

              Discord

              Comment


                I'm wondering one thing about the AI. I want the enemy AI to be able to ignore player-units during the path-finding/decision-making process but I can't seem to find a way to implement that properly. Let's say that all units have a boolean called ignoreDuringPathfinding, and if it is true the AI should pretend like the unit doesn't exist.

                Comment


                  I've been trying to get an AI controlled Unit to search and attack Units with faction = Enemy
                  Like a friendly NPC, but even with find tiles in ranges with target faction = Enemy, it still finds units with faction = player
                  Is there something in the AI Bps that disallows AI attacking Enemy factions?

                  Comment


                    Ok, I finally have some time to answer. Lets do this

                    Originally posted by deflip007 View Post
                    Hi I was following Tracey White's UI Tutorial and ran into some problems at the five minute mark.
                    I am using a melee Pawn that I renamed Player_2 instead of Tracy's BallPawn. The timer works on the side but does not display on the widget.
                    Is there something I'm missing?
                    The main problem here is that your melee unit is not actually the player pawn. I believe Get Player Pawn refers to whatever pawn is possessed by a particular player at a particular time. For ATBTT this will get the grid camera and not the current pawn, as the current pawn is not actually possessed. Instead of getting the current player pawn get a reference to ATBTT_Game_Mode and get the current pawn from there. Hopefully that should solve your problem.

                    Originally posted by deflip007 View Post
                    Right now I'm also trying to create a level select mechanic. Is there a good way to do it with the Advanced Turn Based Tile Toolkit?
                    I haven't really looked into switching levels, though I know several people have done so with the toolkit already. This is one of those places where I reveal my ignorance of much of UE4. My knowlede is fairly specialized. I can see no reason why switching between maps would be different in ATBTT than in any other UE4 project, though, so any general tutorials you can find on the subject should do the trick. I apologize for not being able to help beyond this.

                    Originally posted by anhquan0412 View Post
                    Hi Knut
                    I purchased the toolkit for my class project, and to be honest, this is the most awesome thing I've ever bought in the marketplace. Your tutorials are descriptive too. I have some questions regarding to my project using the toolkit. I want the character to have 4 attacking moves (active/passive moves, like in Pokemon) instead of just one move (punching/shooting), will that be possible to implement? And also, can I change the game to player vs player (probably on 1 computer) instead of player vs AI?
                    Thank you
                    Very glad to hear that! Various different attacks is absolutely possible to add, and a few users have done so already. It depends a bit on what you're after, though. Generally attacks are resolved through the bluprints in Unit_Parent; mainly in the Attack Victim and Receive Damage parts of the event graph. There are many different ways to add attacks. In pokemon you would choose different attacks through a menu. If you have such a menu you can modify a variable in the current pawn when you select an attack (maybe an enum that holds various attack names). Then when you run the attack victim code you would add a switch that would resolve the attack differently based on the value of this variable. If you only want basic stuff like elemental damage with resistances this can be baked into receive damage.

                    Originally posted by Wisdom-HELLy View Post
                    Hi all,

                    Suddenly, Unit Parent doesn't not compile anymore.
                    When I try to compile the blueprint, I suffer an engine crash. This is what I see in the error log:

                    <ErrorMessage>Assertion failed: ((UObject*)ContainerPtr)->IsA((UClass*)GetOuter()) [File:\BuildFarm\buildmachine_++depot+UE4-Releases+4.9\Engine\Source\Runtime\CoreUObject\Public\UObject\UnrealType.h] [Line: 308]
                    'Pawn_Anim_BP_Ranged_C_156' is of class 'Pawn_Anim_BP_Ranged_C' however property 'StructProperty_1890' belongs to class 'TRASHCLASS_Pawn_Anim_BP_Parent_179'
                    </ErrorMessage>

                    Is somebody there already found and solved above error?
                    My project is stuck because of this

                    PS. it happens both with 4.8 and 4.9 UE version. I have added some new pawns but I can't understand why it happen. I guess if the Pawn_Anim_BP_Parent is somehow corrupted.
                    ****, I thought I had solved this bug The last time this happened it was due to a problem with the animation blueprints. It seems it is still like this from the error message. When you say 4.9 UE do you also mean the very latest version of my toolkit or just UE4? I need to try and narrow this stuff down... I'm not able to replicate it at the moment. Are you using a vanilla version? Terribly sorry for the inconvenience.

                    Originally posted by Anzak View Post
                    I decided to try a different tactic and I am an not understanding the edge array I think. When I initialize a platform I set an array of all the tile indexes of the platform. That works perfectly with my macro. Then I deactivate all of the platforms by hiding them and setting all all of the side of the edge area for each tile under it to 0. Then When I active a tile I set all of the edges of the tiles under the platform to 1. This does not seem to have the desired effect. In fact the entire grid is able to be walked on like this. Suggestions on what I am doing wrong?
                    I’m not sure I understand completely what you mean. Let me try to rephrase and see if I understand. You get all the indexes under a platform as per your custom function. That means that you find the bounds of a platform, find what locations it is overlapping and convert those to indexes, right? Then when you hide the platform you make the edges of all those indexes 0. This should render them unwalkable. Then you show the platform and make all the edges 1 again making them walkable? I must not be understanding you correctly. Perhaps you can show me what you mean? Here is an excel mockup of my current understanding. Here is a small grid of 28 tiles with the indexes of the tiles in the middle of each tile and their edge costs in the edge array surrounding these indexes.

                    Click image for larger version

Name:	su1SXdP.png
Views:	1
Size:	53.9 KB
ID:	1092691

                    If you want to understand how the edge costs are used in pathfinding I’ll give you a quick description. Say if you are a unit on tile 8 that wants to get to tile 8 in the second grid pictured above. To find out if it is possible to move between these the pathfinding first checks the eastern edge of tile 7. If this is 0 it gives up. If it is greater than 0 it checks the western edge of tile 8. If this is 0 again it gives up. If it is 1 it declares it as walkable. If it is greater than 1 it checks if the remaining movement points of the unit are greater than this cost. If so it is considered walkable. In other words the pathfinding checks both the edge of the tile it is leaving and the edge of the tile it is entering to see if they are impassable. It only checks the edge it is entering for difficult terrain.

                    I hope I have not just made you more confused. Please elaborate on what you are trying to achieve and I will help as best I can.

                    Originally posted by AxelRantila View Post
                    I'm wondering one thing about the AI. I want the enemy AI to be able to ignore player-units during the path-finding/decision-making process but I can't seem to find a way to implement that properly. Let's say that all units have a boolean called ignoreDuringPathfinding, and if it is true the AI should pretend like the unit doesn't exist.
                    I need to know what you mean by ignore. Do you want the pathfinding to treat the tiles as empty so that the AI can pass right through them or do you want the AI not to be able to move through these tiles, but simply not be aware of (not attack) the player units on them? For the first you would need to change the pathfinding. For the second you will simply need to modify the AI controller. I could give you some more specific suggestions, but I would like to be sure of what you mean first so I can answer your question correctly.

                    Originally posted by Bankworthy View Post
                    I've been trying to get an AI controlled Unit to search and attack Units with faction = Enemy
                    Like a friendly NPC, but even with find tiles in ranges with target faction = Enemy, it still finds units with faction = player
                    Is there something in the AI Bps that disallows AI attacking Enemy factions?
                    Yeah, the problem here is that while Find Tiles In Range can be set to search for a specific faction, pathfinding always searches for player units. I have changed this in the coming update so that both functions finds all units of all factions and afterwards chooses what to do with this information. If you change this part of the Search and Add Tile function:

                    Click image for larger version

Name:	tE8J3yA.png
Views:	1
Size:	169.3 KB
ID:	1092692

                    To this:

                    Click image for larger version

Name:	fCCrcxN.png
Views:	1
Size:	161.6 KB
ID:	1092693

                    The AI should start killing one another. The next step would be to have them select the potential targets from the Reachable Pawns Array (from pathfinding) and Pawns in Sight Array (from Find Tiles in Range) based on some other metric than whichever unit has the lowest health.

                    Here is the modified Make Choice Array function in ATBTT_AI_Controller of the WIP update. It is modified so that it throws out all potential targets that are not player units. Modifications to this function could be made to allow for enemy units that target their own for healing, go berserk and attack each other etc.

                    Click image for larger version

Name:	mFwbdD2.png
Views:	1
Size:	232.3 KB
ID:	1092694

                    I hope that is enough to get you started. What is your desired end result, by the way?
                    Advanced Turn Based Tile Toolkit (Marketplace - Support)

                    Dungeon Crawler Toolkit (Marketplace - Support)

                    Discord

                    Comment


                      Ok if I am understanding this correctly then it needs to be 0 on both tiles of an edge to make it unwalkable. What I am doing is making all of the highlighted tiles edges 1. Everything around it should be 0. But if it needs to be 0 on both sides that explains since the outer edge is 1 on the area that I have made walkable.

                      Comment


                        I thought I was understanding what you said but it looks like I am wrong.

                        Click image for larger version

Name:	Edge1.PNG
Views:	1
Size:	103.2 KB
ID:	1092702
                        Click image for larger version

Name:	Edge2.PNG
Views:	1
Size:	120.5 KB
ID:	1092703
                        Click image for larger version

Name:	Edge3.PNG
Views:	1
Size:	635.5 KB
ID:	1092704

                        Tile area array is all of the tiles under the platform. There is an array for each edge top, bottom, right, and left. When a platform is initialized I do nothing though when it is spawned I have a process check what it should be and hides all but the starting one. When it hides them it goes through the Tile area array and sets the edges for all tiles all edges to 0. When I unhide which I do for the first platform at the start of the game I set all edges for all tiles in the Tile area array to 1. Then I loop through each of the 4 edges and set the 3 edges for that side to 0 for each tile on the edge. Each platform is 4x4 tiles.

                        Comment


                          As a thought for a debugging feature would be a way to turn on a decal that shows the edge values like the image you put up. Just a thought as I try to noodle through this.

                          Comment


                            I am wondering if this is an artifact of using children of all the base classes. In this case you can see I am using Tile Game Mode which is a child of BP Grid Manager Game Mode. I am also using Tile Grid Manager which is a child of BP Grid Manager. However I am using the Ref to BP Grid Manager to get to the edge array. The part that is troubling to me is that it seems ok with using the grid size x and grid size y from the same ref and that works correctly so it should not be a case where I have not accessed the correct variable. I did try setting all of the tile edges to 0 for all tiles on begin play in the Tile Grid Manager and that does work but activating a tile does not change it's values back to 1. Anyway eyes are crossing I am calling it a night will try some more things tomorrow.

                            Comment


                              Originally posted by Monokkel View Post
                              ****, I thought I had solved this bug The last time this happened it was due to a problem with the animation blueprints. It seems it is still like this from the error message. When you say 4.9 UE do you also mean the very latest version of my toolkit or just UE4? I need to try and narrow this stuff down... I'm not able to replicate it at the moment. Are you using a vanilla version? Terribly sorry for the inconvenience.
                              Nope, I don't use your latest version. I only get what I need from your updates because I have greatly changed the toolkit for our game purpose.
                              I use the 1.4 version.

                              Should I download your latest version and copy/paste only the Animation Blueprints to solve my problem?
                              Fantasy Turn-Based Tactical Game
                              STEAM: https://store.steampowered.com/app/9...Arcane_Legacy/
                              IG: https://www.instagram.com/arcanelegacyofficial/
                              FB: https://www.facebook.com/ArcaneLegacy/
                              WEB: http://www.arcanelegacy.com

                              Comment


                                Originally posted by Monokkel View Post
                                I need to know what you mean by ignore. Do you want the pathfinding to treat the tiles as empty so that the AI can pass right through them or do you want the AI not to be able to move through these tiles, but simply not be aware of (not attack) the player units on them? For the first you would need to change the pathfinding. For the second you will simply need to modify the AI controller. I could give you some more specific suggestions, but I would like to be sure of what you mean first so I can answer your question correctly.
                                The later is what I want to accomplish in my game. If a condition is true (in my case the return value of a function in Unit parent (that seriously needs to be renamed to something better)) for player units, the AI should not to attack the player unit in question. I tried to change it myself but I couldn't figure how to do it in the AI controller.

                                Comment

                                Working...
                                X