Announcement

Collapse
No announcement yet.

Networking - Pulling up specific widgets to specific players

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

    Networking - Pulling up specific widgets to specific players

    I'm working on a game with three different player classes (1 Killer, 1 Detective, and anyone else is a civilian.) At the start of the game, in the game mode blueprint, i'm shuffling the players, and spawning the classes (i'm using a loop for the remaining civilians.) In my pawn base class i'm spawning the main Widget for each player (and inside each player's widget i'm specifying what role they are.)

    At the end of each round, I need a specific widget to come up for whoever was assigned the role of detective and the remaining players (including the killer) would get a different widget. I can't seem to get this to work. I don't know where I'm supposed to be calling these widgets from (the base class, main widget, game mode?) The timer function is in the game mode.

    I think i should make a BOOL variable the trips at the end of each round (in the game mode) and then have an event that trips in the Base Class once that BOOL has been tripped. From there i could use branches to find the detective and create the widget on his and the other widget on the other players. But, if that's correct, what kind of event in the base class would i use?

    Also, having a similar problem with basic player names; how do i get it so that a player's name pulls up correctly for each player? Where do i set it? In my runs of four players, the most unique player names (default numbers) that i've been able to get are two before they start repeating (i don't have a picture of this one right now, but i was pulling the name in the main widget. i tried pulling it in the base pawn class, setting it, and then pulling that string in the widget, but it only worked on one player's screen.)
Working...
X