class

GB::DmgOps::Operation

Inherits JSON::Serializable < Reference < Object

Constructors

new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source

Instance methods

assign_extra_integers

set u8, u16, and i8 if necessary

Source
branch(cond : String, body : Array(String)) : Array(String)

create a branch condition

Source
codegen

generate the code required to process this operation

Source
cycles
Source
cycles=(cycles : UInt8)
Source
cycles_branch
Source
cycles_branch=(cycles_branch : UInt8)
Source
flags
Source
flags=(flags : Flags)
Source
group

read the group as a Group enum

Source
length
Source
length=(length : UInt8)
Source
name
Source
name=(name : String)
Source
normalize_operand(operand : String) : String

normalize an operand to work with the existing cpu methods/fields

Source
operands

read the operation operands from the name

Source
set_flag_c(o : Object) : Array(String)

set flag c to the given value if specified by this operation

Source
set_flag_c!(o : Object) : Array(String)

set flag c to the given value

Source
set_flag_h(o : Object) : Array(String)

set flag h to the given value if specified by this operation

Source
set_flag_h!(o : Object) : Array(String)

set flag h to the given value

Source
set_flag_n(o : Object) : Array(String)

set flag n to the given value if specified by this operation

Source
set_flag_n!(o : Object) : Array(String)

set flag n to the given value

Source
set_flag_z(o : Object) : Array(String)

set flag z to the given value if specified by this operation

Source
set_flag_z!(o : Object) : Array(String)

set flag z to the given value

Source
set_reset_flags

generate code to set/reset flags if necessary

Source
type

read the operation type from the name

Source