Download

Local 1 player vs (2 player or AI) Turn Based Game System - Questions

Hello,

I’m currently working on a dynamic turn-based game system. I would like to be able to adapt it for games like golf, darts, bowling et,

While I am not new to UE4, I am still learning and cannot figure out how to implement the Current Player, Total Players, Remaining Balls/Darts/Et…, Points, Game Over, et variables…

- Should I be storing the main variables in the GameState/Player State/Player UI??
- Will a boolean work for possession? How can I switch between AI and Player possession? 

I have tried following the turn-based RPG tutorials but they really don’t work for this type of project.
The UE4 Turn Based infopage contains 0 examples unfortunately. [Turn Based | Unreal Engine Documentation]

If anyone can please help, it would make my day!

Thank you

I think, you need to read yourself first through some Multiplayer Tutorials…
The Unreal replication system, including all the different Actor and Mode Types, can be frustrating confusing…

I started with the Unreal Network Compendium, by Exi
You can find it here: Cedric ‘Exi’ Neukirchen´s Network Compendium

And a bigger Networking Tutorial on Udemy.

Since we are into an Advance Wars like Game with more Realtime Elements, we stucked there long time, too.

Thank you for the quick response but I am not trying to make a online multiplayer game at this time.
It’s just Single Player vs a local Second player (human or AI). Replication shouldn’t be necessary,

I’m just surprised there are no tutorials on turn based gameplay that aren’t RPG oriented.
Unfortunately these tutorials usually have a refresh/timer to determine turn.

What I am trying to build appears simple in theory but I am finding very difficult to execute.

-Game starts,
-toss a coin to determine who goes first.
-players take turns
-record points to variables
-eventually one player wins
-Game over

I’m just not sure where the BPs should be placed, in which order.

GameInstance, GameState, GameMode, Level BP, Player BP, Dart/Ball/Playing Object BP et…

I have a menu gamemode that feeds player/team name to the GI so the actual games gamemode can populate the UI,

At that point I have the first player possessing the dart/ball, they throw. But at that point I am kind of stuck.

I should posses the second player pawn, but does the level BP trigger that once the throw has been registered?

if i were you i would first do the single player version first. So you only have to deal with 1 controller. Single player games are much more lenient as far as what logic is stored where. You can do the whole thing in the player controller in fact. That way you can learn how to do the scoring system as a 1 person game first. You want to at last have that understanding under your belt before dealing with 2 player