Module: Card::Set::Right::MachineOutput::Format

Extended by:
AbstractFormat
Defined in:
tmpsets/set/mod014-machines/right/machine_output.rb

Instance Method Summary collapse

Instance Method Details

#update_machine_output_live?Boolean

Returns:

  • (Boolean)


40
41
42
43
44
45
46
47
48
49
50
# File 'tmpsets/set/mod014-machines/right/machine_output.rb', line 40

def update_machine_output_live?
  case
  when !card.left.is_a?(Abstract::Machine) then false # must be a machine
  when card.left.locked?         then false # machine must not be running
  when card.new_card?            then true  # always update if new
  else
    # must want current output (won't re-output old stuff)
    (selected_id = card.selected_action_id) &&
      selected_id == card.last_action_id
  end
end