Class: Nitro::HeaderBin
- Inherits:
-
Object
- Object
- Nitro::HeaderBin
- Includes:
- NitroBind
- Defined in:
- lib/nitro/nitro.rb
Instance Method Summary collapse
- #arm7_auto_load_hook_offset ⇒ Object (also: #arm7_auto_load_hook_ofs)
- #arm7_entry_address ⇒ Object (also: #arm7_entry_addr)
- #arm7_ram_address ⇒ Object (also: #arm7_ram_addr)
- #arm9_auto_load_hook_offset ⇒ Object (also: #arm9_auto_load_hook_ofs)
- #arm9_entry_address ⇒ Object (also: #arm9_entry_addr)
- #arm9_ovt_size ⇒ Object
- #arm9_ram_address ⇒ Object (also: #arm9_ram_addr)
- #game_code ⇒ Object
- #game_title ⇒ Object
-
#initialize(arg) ⇒ HeaderBin
constructor
A new instance of HeaderBin.
- #maker_code ⇒ Object
Constructor Details
#initialize(arg) ⇒ HeaderBin
Returns a new instance of HeaderBin.
321 322 323 324 325 326 327 328 329 330 331 332 |
# File 'lib/nitro/nitro.rb', line 321 def initialize(arg) if arg.is_a? String @ptr = FFI::AutoPointer.new(headerBin_alloc, method(:headerBin_release)) if not File.exist? arg puts "Error: #{arg} does not exist" raise "HeaderBin initialization failed" end headerBin_load(@ptr, arg) elsif arg.is_a? FFI::Pointer @ptr = arg end end |
Instance Method Details
#arm7_auto_load_hook_offset ⇒ Object Also known as: arm7_auto_load_hook_ofs
351 352 353 |
# File 'lib/nitro/nitro.rb', line 351 def arm7_auto_load_hook_offset headerBin_getArm7AutoLoadHookOffset(@ptr) end |
#arm7_entry_address ⇒ Object Also known as: arm7_entry_addr
361 362 363 |
# File 'lib/nitro/nitro.rb', line 361 def arm7_entry_address headerBin_getArm7EntryAddress(@ptr) end |
#arm7_ram_address ⇒ Object Also known as: arm7_ram_addr
371 372 373 |
# File 'lib/nitro/nitro.rb', line 371 def arm7_ram_address headerBin_getArm7RamAddress(@ptr) end |
#arm9_auto_load_hook_offset ⇒ Object Also known as: arm9_auto_load_hook_ofs
346 347 348 |
# File 'lib/nitro/nitro.rb', line 346 def arm9_auto_load_hook_offset headerBin_getArm9AutoLoadHookOffset(@ptr) end |
#arm9_entry_address ⇒ Object Also known as: arm9_entry_addr
356 357 358 |
# File 'lib/nitro/nitro.rb', line 356 def arm9_entry_address headerBin_getArm9EntryAddress(@ptr) end |
#arm9_ovt_size ⇒ Object
376 377 378 |
# File 'lib/nitro/nitro.rb', line 376 def arm9_ovt_size headerBin_getArm9OvTSize(@ptr) end |
#arm9_ram_address ⇒ Object Also known as: arm9_ram_addr
366 367 368 |
# File 'lib/nitro/nitro.rb', line 366 def arm9_ram_address headerBin_getArm9RamAddress(@ptr) end |
#game_code ⇒ Object
338 339 340 |
# File 'lib/nitro/nitro.rb', line 338 def game_code headerBin_getGameCode(@ptr) end |
#game_title ⇒ Object
334 335 336 |
# File 'lib/nitro/nitro.rb', line 334 def game_title headerBin_getGameTitle(@ptr) end |
#maker_code ⇒ Object
342 343 344 |
# File 'lib/nitro/nitro.rb', line 342 def maker_code headerBin_getMakerCode(@ptr) end |