PlayerJoin.initial constructor

PlayerJoin.initial({
  1. Widget then(
    1. Score
    )?,
  2. Entity? target,
  3. String score = 'objd_join',
})

This gives every player a unique id on join and enables you to do something the first time around with the score holding the players id.

PlayerJoin.inital
then A Function accepting a Score that gets executed by the player that joins
target The targeted player that will throw this event(default = @a)
score The scoreboard that is used(default = objd_join)

Implementation

PlayerJoin.initial({
  /// A Function accepting a Score that gets executed by the player that joins
  Widget Function(Score)? then,
  this.target,
  this.score = 'objd_join',
})  : subcommand = "initial",
      then = null,
      _then_v = then;