Module: GamePlay::RSEClockHelpers::Logic

Included in:
GamePlay::RSEClock
Defined in:
scripts/01450 Systems/00400 RSE Clock/00001 RSEClockLogic.rb

Overview

Module defining the logic of the RSEClock

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#hourInteger (readonly)

Get the hour that was set on the clock

Returns:



8
9
10
# File 'scripts/01450 Systems/00400 RSE Clock/00001 RSEClockLogic.rb', line 8

def hour
  @hour
end

#minute (readonly)

Get the minute that was set on the clock



10
11
12
# File 'scripts/01450 Systems/00400 RSE Clock/00001 RSEClockLogic.rb', line 10

def minute
  @minute
end

Instance Method Details

#initialize(hour = 0, minute = 0)

Create a new RSEClock

Parameters:

  • hour (Integer) (defaults to: 0)

    hour to start the clock

  • minute (Integer) (defaults to: 0)

    minute to start the clock



15
16
17
18
19
20
21
# File 'scripts/01450 Systems/00400 RSE Clock/00001 RSEClockLogic.rb', line 15

def initialize(hour = 0, minute = 0)
  super(false)
  @hour = hour
  @minute = minute
  @choice_result = nil
  initialize_state_machine
end