9/21/2023 0 Comments Advance wars by web image issues![]() ![]() so you can easily traslate what your state machine decides to the available user commands, like mouse clicks or keyboard shortcuts. for example you've already defined for tanks how to move to the point a player assigns them using a click. for example based on the position of the units you can use A* to determine minimum time needed to gather your soldiers around opponents base.Īnd for the last step you have to translate those high concept orders to game level commands. in this stage state machine can also use algorithm to generate new data to help itself decide. it's usual to use an state-machine to determine for each dataset which action is better. so there is a list of data, and a list of possible high level actions. so based on the information you just give an order, it can be moving units to some specific point or constructng a building or what ever you think you have to do at the moment. just think as a general, you have some information, and for any action you order, your soldiors know how they should obey. Next step is to decide about high concept of what your AI should do in the next turn. for example it's not really important if your opponent has many units far away from you, the only important ones are the ones near. then you have to extract useful information from that data. remember if you want your AI to act normal you can't give it any information on the map, if the player can't see what the AI is doing, AI shouldn't be able to know what's happening in player's base. So to apply this approch to your AI problem, first we have gather all the input we can, in an strategy game it can be number units their position and their type. for example if it's running how should I run to maintain my balance, or if I fall what should I do to stand up. and the last stage was to describe how the should we do the action state machine chose. should it run toward the ball? or is the robot already in possession of the ball and should kick it? or should he pass it to another player? and so on. then we had to choose which action should player do. server describes field using relative positions to the player so we have to transform all the input to undestand world position of object seen. in our team (and other teams in league) there was 3 stages of thinking: first to understand what server told us about the game field. the game is just like real soccer with some humanoid robots moving inside the field but the problem is you only have control over joints of robot body, so you have at first try not to lose your balance while moving! I think this problem is just as hard as implementing AI for an strategy game. It's not always finding algorithm like A* that decide what AI should do, usually for games with too many possiblities they use some state-machine that controls the actions and those search algorithm are used both to describe how choosed action should be done and to extrant usable information from all the game data.įor example i've been in robocup soccer simulatoin 3d team. If you are only asking about the path finding problem you can use your answer in this question, but for the whole idea of how to implement an AI read the rest of my answer. But as of yet I do not see how I can put it all together. ![]() I have found several good sources on A*, DFS, BFS, evaluation / cost functions etc. upto a number of cycles deep.įinally it has found the best move and now it's the players turn. Then the board flips over to the player role (min/max) and the computer searches the best player move, and flips back etc. With a cost function one can determine the best moves. With this you can build a search tree for each item, resulting in a large tree for all items. ![]() There is some path-finding needed to to engage into combat, harvest, or move to an object, so that in the next move such actions are possible. Has anyone tried to develop, or know of an algorithm such as used in a typical turn based game like Advance Wars, where the number of objects and the number of moves per object may be too large to search through up to a reasonable depth like one would do in a game with a smaller search base like chess? ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |