Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

AWorks Input Module-WASD configuration?

Greetings, what's up, and hi, I was wondering how to utilize AWorks's Input Module so that my game can use W,A,S,D for movement and 'F' for Cancel/Menu? The problem is that I have noooooo idea how to use this script. Can someone tell me how to edit so that it does the things stated above? Thanks in advance. Here is the Input Module:

viewtopic.php?f=11&t=59160
 
You need to find code segments like these:
Code:
if Input.trigger?(Input::B)
Those are key input handlers from the default Input module, whereas 'trigger?' is the input method (pressed once), and 'B' the respective key (by default mapped to Esc and x on your keyboard). So, as this is your menu and cancel key, that's what you want to change.

To do that, you first have to address vgvgf's Input module instead of the default one. You'll do that by modifying the 'trigger?' call, as you can see, he has a method called 'triggered?' (note the difference!) for his script. Now, depending on the version of his script, you have to find the respective number for the key you want and replace B with it.
Do the same for UP, DOWN, LEFT and RIGHT, replacing them each with the repective number for your W, A, S and D (out of order here) keys.

Since you have only one player walking conditional set, but many many cancel ones, you might wanna modify the method within the input script that's called
Code:
def self.B
By modifying the contents in that constant definition, you can change the key mapping for your whole game.
 
AH! It didn't work. I put, instead of Input.trigger?, Input.triggered? on every input thing in the Scripts and replaced B with 70 (F) and so on, but it didn't work at all. It came up with a SYNTAX error. I didn't change it to triggered on Input C because it was fine the way it is. I really want to change it to WASD and F though :(
 
Depending on the version of his script, it might be a different string than that... for example 'triggerd?' or something... look it up in the input module itself, where it says 'def triggered?' (or whatever it's called).
 
Mind taking a look at it for me? :)

Code:
#=============================================================================

# *** AWorks Input Module(AIM)

#=============================================================================

# Created by AWorks

# Version: 3.00

# Last Modification: 26/01/2009 (day/month/year)

# Compatible with RMXP & RMVX

#=============================================================================

#==== Description ====

# This script simulates the RGSS/2 module Input. It is not the original module,

# but it has all the original module functions and some new.

#=============================================================================

#==== Requeriments ====

# * ALibrary (AWorks Library)

#   - Version: 1.03

# * AKM (AWorks Keys Module)

#   - Optional, but recommended

#=============================================================================

#==== Version History ====

# * Version 3.00

#   - Complete rewrite of the script, now it uses AWorks.dll for input updating

#=============================================================================

#==== Features ====

# * All keyboard/mouse keys

#   - When calling one of the keys states methods(press?, trigger?, and so on)

#     you can use the AKM script for obtaining the keys identifiers.

#     Insteand of: (Like in the original Input)

#       Input.press?(Input::[KEY NAME HERE])

#     Use: (If you want to detect "X" key from keyboard/mouse)

#       Input.press?(Keys::[KEY NAME HERE])

#     Example for F3 key:

#       Input.press?(Keys::F3)

#     Example for H key:

#       Input.press?(Keys::H)

#     Example for Y key:

#       Input.press?(Keys::Y)

#

# * Input.release?(vk)

#   - Determines whether the key vk is being released. It can be considered as

#     the opposite function of Input.trigger?

#

# * Input.pressed

#   - Returns all keys which are being pressed

#

# * Input.triggered

#   - Returns all keys which are being triggered

#

# * Input.repeated

#   - Returns all keys which are being repeated

#

# * Input.released

#   - Returns all keys which are being released

#=============================================================================

#==== Notes ====

# * For more information about the Input.press?, Input.trigger?, Input.repeat?,

#   Input.dir4, Input.dir8 and Input.update methods see the RMXP/RMVX help file.

#

# * Don't confuse the Input module keys(A, B, C, X, Y, Z, L, R) with the

#   keyboard letters, as the firsts recognize only the user's buttons

#   configuration(Accessible in the F1 menu) and not the real keyboard keys.

#

# * This input system works with virtual keys(VK) for identifying all of the

#   keyboard and mouse keys, and they consist on numbers between 0..255. Each

#   key on keyboard has its own and unique VK and are listed on the

#   AKM for easy use.

#

# * Note that not all computers have the same keyboard and keyboard

#   configuration(Layout), specially for the special symbols and characters

#   keys. Commonly, keyboards just vary in the OEM keys(See AKM), but also

#   some keyboards have some extra keys others doesn't have. (The same applies

#   for mouses)

#

# * This script doesn't detect changes in the buttons configuration from the

#   F1 menu until the game closes and the configuration is saved to the

#   registry. So, you have to restart the game for the configurations to have

#   effect.

#

# * The Conditional Branch "Button being pressed" option and the "Button Input

#   Processing" command are incompatible with this new Input system. However,

#   you may use AIM:PXP patch for RMXP or AIM:PVX patch for RMVX for fixing this

#   incompatibility.

#=============================================================================

#==== Advices ====

# * You can check the state of a key in an event using the Script option of the

#   Conditional Branch event command just writing the Input method and the key

#   you want to check.

#   Example for letter "O", just put:

#     Input.press?(Keys::O)

#=============================================================================

 

#=============================================================================

# ** Module Input

#=============================================================================

module Input

  #---------------------------------------------------------------------------

  # * Variables declaration

  #---------------------------------------------------------------------------

  @time = Array.new(256, 0)

  @press = Array.new(256, false)

  @trigger = Array.new(256, false)

  @repeat = Array.new(256, false)

  @release = Array.new(256, false)

  @dirs = [0, 0]

  #---------------------------------------------------------------------------

  # * convert_keys (internal method)

  #---------------------------------------------------------------------------

  REG_KVALUES = {0=>32,1=>13,2=>27,3=>96,4=>16,5=>90,6=>88,7=>67,8=>86,9=>66,

                 10=>65,11=>83,12=>68,13=>81,14=>87}

  DEFAULT_KEYS = {11=>[16,90],12=>[27,88,96],13=>[13,32,67],14=>[65],15=>[83],

                  16=>[68],17=>[81],18=>[87]}

  def convert_keys(key)

    begin

      keys = []

      rkey = 'HKEY_CURRENT_USER\\Software\\Enterbrain\\RGSS'

      data = AWorks::Registry.read_entry(rkey, 'ButtonAssign')[10, 25].scan(/./)

      15.times {|i| keys.push(REG_KVALUES[i]) if key == data[i].unpack('C')[0]}

      keys

    rescue

      DEFAULT_KEYS[key] rescue []

    end

  end   

  module_function :convert_keys

  #---------------------------------------------------------------------------

  # * Keys Constants declaration

  #---------------------------------------------------------------------------

  LOWER_LEFT = 97

  LOWER_RIGHT = 99

  UPPER_LEFT = 103

  UPPER_RIGHT = 105

  DOWN = [98, 40]

  LEFT = [100, 37]

  RIGHT = [ 102, 39]

  UP = [104, 38]

  A = convert_keys(11)

  B = [45] + convert_keys(12)

  C = convert_keys(13)

  X = convert_keys(14)

  Y = convert_keys(15)

  Z = convert_keys(16)

  L = [33] + convert_keys(17)

  R = [34] + convert_keys(18)

  SHIFT = 16

  CTRL = 17

  ALT = 18

  F5 = 116

  F6 = 117

  F7 = 118

  F8 = 119

  F9 = 120

  #---------------------------------------------------------------------------

  # * Initialize Input

  #---------------------------------------------------------------------------

  AWorks::API::InputIni.call(@time.object_id, @press.object_id,

  @trigger.object_id, @repeat.object_id,  @release.object_id, @dirs.object_id)

  #---------------------------------------------------------------------------

  # * Keys input state update

  #---------------------------------------------------------------------------

  def Input.update

    AWorks::API::InputUpdate.call

  end

  #---------------------------------------------------------------------------

  # * Press?

  #---------------------------------------------------------------------------

  def Input.press?(vk)

    @press.indexes(*vk).include?(true)

  end

  #---------------------------------------------------------------------------

  # * Pressed

  #---------------------------------------------------------------------------

  def Input.pressed

    array = Array.new

    @press.each_index {|i| array.push(i) if @press[i]}

    array

  end

  #---------------------------------------------------------------------------

  # * Trigger?

  #---------------------------------------------------------------------------

  def Input.trigger?(vk)

    @trigger.indexes(*vk).include?(true)

  end

  #---------------------------------------------------------------------------

  # * Triggered

  #---------------------------------------------------------------------------

  def Input.triggered

    array = Array.new

    @trigger.each_index {|i| array.push(i) if @trigger[i]}

    array

  end

  #---------------------------------------------------------------------------

  # * Repeat?

  #---------------------------------------------------------------------------

  def Input.repeat?(vk)

    @repeat.indexes(*vk).include?(true)

  end

  #---------------------------------------------------------------------------

  # * Repeated

  #---------------------------------------------------------------------------

  def Input.repeated

    array = Array.new

    @repeat.each_index {|i| array.push(i) if @repeat[i]}

    array

  end

  #---------------------------------------------------------------------------

  # * Release?

  #---------------------------------------------------------------------------

  def Input.release?(vk)

    @release.indexes(*vk).include?(true)

  end

  #---------------------------------------------------------------------------

  # * Released

  #---------------------------------------------------------------------------

  def Input.released

    array = Array.new

    @release.each_index {|i| array.push(i) if @release[i]}

    array

  end

  #---------------------------------------------------------------------------

  # * 4 Directions

  #---------------------------------------------------------------------------

  def Input.dir4

    @dirs[0]

  end

  #---------------------------------------------------------------------------

  # * 8 Directions

  #---------------------------------------------------------------------------

  def Input.dir8

    @dirs[1]

  end

end

 
 
Alright, so it's either 'trigger?' or 'triggered' (this one without the question mark, meaning it doesn't check for something, aka you want to use the first one).
I thought vgvgf did it a way that wouldn't overwrite the default, but aparently, he didn't... well, you need to use the default Input.trigger? then, along with the respective number... looking like this:
Code:
if Input.trigger?(70)
 
Oh my god, now I get this error:

alibraryerror.jpg


Here's ALibrary:

Code:
#=============================================================================

# *** AWorks Library(ALibrary)

#=============================================================================

# Created by AWorks

# Version: 1.03

# Last Modification: 26/01/2009 (day/month/year)

# Compatible with RMXP & RMVX

#=============================================================================

#==== Description ====

# This script is a compilation of useful tools created and designed for their

# use in the AWorks scripts. However, some functions may be useful for other

# purposes and scripts.

#=============================================================================

#==== Credits ====

# * Ruby 1.8

#   - Win32::Registry class, base of AWorks::Registry

# * Nishikawa, Yasuhiro

#   - APIs for AWorks::Clipboard

#=============================================================================

#==== Requeriments ====

# * AWorks.dll (Place it on the game folder)

#   - Version: 1.00

#=============================================================================

#==== Features ====

# * AWorks::Ini.get_string(id[, tag[, file]])

#   Gets the string of the id field from the tag section from a .ini file.

#

# * AWorks::Ini.set_string(string, id, [, tag[, file]])

#   Sets the string of the id field from the tag section from a .ini file.

#

# * AWorks::Clipboard.read

#   Gets the clipboard data.

#

# * AWorks::Clipboard.write(string)

#   Sets the string to the clipboard data.

#

# * AWorks::Clipboard.empty

#   Empties the clipboard data.

#

# * AWorks::Registry.read_value(key, entry)

#   Read a registry value entry under key.

#

# * AWorks::Registry.enum_keys(key)

#   Enums all subkeys under key.

#

# * AWorks::Registry.enum_values(key)

#   Enums all entries under key.

#

# * AWorks::Registry.create_key(key)

#   Creates the subkey key.

#

# * AWorks::Registry.set_value(key, value[, type])

#   Sets(or creates) the value.

#

# * AWorks::Registry.delete_key(key[, recursive])

#   Deletes a subkey.

#

# * AWorks::Registry.delete_value(key)

#   Deletes a value.

#

# * AWorks.get_fonts_names

#   Returns fonts names from the windows Fonts folder.

#

# * AWorks.get_hwnd

#   Returns the HWND index of the game player.

#

# * AWorks.get_rgssdll

#   Returns the RGSS dll name.

#

# * AWorks.get_rtp_path([id])

#   Returns the rtp id path.

#

# * AWorks.get_mouse_swap_buttons_flag

#   Returns the Swap Mouse Buttons Flag.

#

# * Array.recursive_clone

#   Clones the array and all its subelements.

#

# * Array.to_hash

#   Converts the array in a hash.

#

# * Array.rindexes(*values)

#   Gets the indexes of the values.

#

# * Array.deep

#   Gets the deep of an Array. Deep stands for the max amount of subcontainers

#   (Arrays and Hashs) inside the array in a row.

#

# * Array.recursive_flatten

#   Calls the flatten method to the Array and all its subelements.

#

# * Array.recursive_flatten!

#   Calls the flatten method to the Array and all its subelements.

#

# * Array.insert(i, obj)

#   Inserts the obj object in the i index.

#

# * Hash.recursive_clone

#   Clones the hash and all its subelements.

#

# * Hash.deep(deep = -1)

#   Gets the deep of an Hash. Deep stands for the max amount of subcontainers

#   (Arrays and Hashs) inside the hash in a row.

#

# * Hash.fusion

#   Makes an array combining each key and value.

#

# * NilClass.clone

#   Empty method for allowing the cloning of nil objects.

#

# * Math.radian2degree(r)

#   Converts a radian value to a degree value,

#

# * Math.degree2radian(g)

#   Converts a degree value to a radian value,

#

# * Math.quick_cos(i)

#   Calc the cosine value of an Integer. Faster than Math.cos.

#

# * Math.quick_sin(i)

#   Calc the sine value of an Integer. Faster than Math.sine.

#

# * String.pixel_width(font)

#   Gets the width of the string for the given font in pixels.

#

# * String.pixel_width(name, size, bold)

#   Gets the width of the string for the given font format in pixels.

#

# * String.pixel_height(font)

#   Gets the height of the string for the given font in pixels.

#

# * String.pixel_height(name, size, bold)

#   Gets the height of the string for the given font format in pixels.

#

# * String.width_slice(width, font)

#   Returns in an array the string sliced in pieces which fit in the given width

#   for the given font.

#

# * String.width_slice(width, name, size, bold)

#   Returns in an array the string sliced in pieces which fit in the given width

#   for the given font format.

#

# * String.font_size_width(width, font)

#   Gets the max font size for the string to fit in the given width with the

#   given font. Font size doesn't matter.

#

# * String.font_size_width(width, name, bold)

#   Gets the max font size for the string to fit in the given width with the

#   given font format.

#

# * String.font_size_height(height, font)

#   Gets the max font size for the string to fit in the given height with the

#   given font. Font size doesn't matter.

#

# * String.font_size_height(height, name, bold)

#   Gets the max font size for the string to fit in the given height with the

#   given font format.

#

# * String.font_size(width, height, font)

#   Gets the max font size for the string to fit in the given width and height

#   with the given font. Font size doesn't matter.

#

# * String.font_size(width, height, name, bold)

#   Gets the max font size for the string to fit in the given width and height

#   with the given font format.

#

# * Bitmap.adraw_text(*args)

#   Draws like Bitmap.draw_text, but with some special features.

#

# * Graphics.auto_update (Property)

#   An array. Updates the objects and methods contained each frame. For adding

#   an object for being autoupdated add a new Array to Graphics.auto_update

#   with the following format:

#     [Object, method, frames]

#   The object must be a class and the method a symbol. If frames is nil, the

#   auto update will run undefined frames(Can be removed with .delete method).

#   If it is an Integer, it will act as a backward counter for each frame, and

#   the auto update will end when it reachs 0.

#=============================================================================

 

#=============================================================================

# ** Module AWorks

#=============================================================================

module AWorks

  module_function

  #===========================================================================

  # ** Module AWorks::API

  #===========================================================================

  module_function

  module API

    #-------------------------------------------------------------------------

    # * AWorks DLL API declaration

    #-------------------------------------------------------------------------

    Initialize = Win32API.new('AWorks', 'Initialize', 'L', '')

    InputIni = Win32API.new('AWorks', 'InputInitialize', 'LLLLLL', '')

    InputUpdate = Win32API.new('AWorks', 'InputUpdate', '', '')

    InputMouseIni = Win32API.new('AWorks', 'InputMouseInitialize', 'LLL', '')

    InputMouseConfig = Win32API.new('AWorks', 'InputMouseConfig', 'LLLL', '')

    BitmapRotate = Win32API.new('AWorks', 'BitmapRotate', 'LLL', '')

    #-------------------------------------------------------------------------

    # * API declaration

    #-------------------------------------------------------------------------

    BlockInput = Win32API.new('user32', 'BlockInput', 'L', 'L')

    ClientToScreen = Win32API.new('user32', 'ClientToScreen', 'LP', 'L')

    CloseClipboard = Win32API.new('user32', 'CloseClipboard', '', 'L')

    ClipCursor = Win32API.new('user32', 'ClipCursor', 'P', 'L')

    EmptyClipboard = Win32API.new('user32', 'EmptyClipboard', '', 'L')

    FindWindowA = Win32API.new('user32', 'FindWindowA', 'pp', 'l')

    GetActiveWindow = Win32API.new('user32', 'GetActiveWindow', '', 'L')

    GetAsyncKeyState = Win32API.new('user32', 'GetAsyncKeyState', 'L', 'L')

    GetClientRect = Win32API.new('user32', 'GetClientRect', 'LP', 'L')

    GetClipboardData = Win32API.new('user32', 'GetClipboardData', 'L', 'L')

    GetCursorPos = Win32API.new('user32', 'GetCursorPos', 'P', 'L')

    GetDoubleClickTime = Win32API.new('user32', 'GetDoubleClickTime', '', 'L')

    GetKeyboardLayout = Win32API.new('user32', 'GetKeyboardLayout','L', 'L')

    GetKeyboardLayoutName =Win32API.new('user32','GetKeyboardLayoutName','P','L')

    GetKeyboardState = Win32API.new('user32', 'GetKeyboardState', 'P', 'L')

    GetKeyState = Win32API.new('user32', 'GetKeyState', 'L', 'L')

    GetSystemMetrics = Win32API.new('user32', 'GetSystemMetrics', 'L', 'L')

    GetWindowPlacement = Win32API.new('user32', 'GetWindowPlacement', 'LP', 'L')

    Keybd_Event = Win32API.new('user32', 'keybd_event', 'LLLL', '')

    OpenClipboard = Win32API.new('user32', 'OpenClipboard', 'L', 'L')

    ScreenToClient = Win32API.new('user32', 'ScreenToClient', 'LP', 'L')

    SetClipboardData = Win32API.new('user32', 'SetClipboardData', 'LL', 'L')

    ShowCursor = Win32API.new('user32', 'ShowCursor', 'L', 'L')

    SwapMouseButton = Win32API.new('user32', 'SwapMouseButton', 'L', 'L')

    ToAsciiEx = Win32API.new('user32', 'ToAsciiEx', 'LLPPLL', 'L')

    GetCurrentProcessId = Win32API.new('kernel32','GetCurrentProcessId', '','L')

    GPPSA = Win32API.new('kernel32', 'GetPrivateProfileStringA', 'PPPPLP', 'L')

    WPPSA = Win32API.new('kernel32', 'WritePrivateProfileStringA', 'PPPP', 'L')

    GlobalAlloc = Win32API.new('kernel32', 'GlobalAlloc', 'LL', 'L')

    GlobalLock = Win32API.new('kernel32', 'GlobalLock', 'L', 'L')

    GlobalSize = Win32API.new('kernel32', 'GlobalSize', 'L', 'L')

    GlobalUnlock = Win32API.new('kernel32', 'GlobalUnlock', 'L', '')

    RegCloseKey = Win32API.new('advapi32', 'RegCloseKey', 'L', 'L')

    RegEnumKeyExA = Win32API.new('advapi32', 'RegEnumKeyExA', 'LLPPLLLP', 'L')

    RegEnumValueA = Win32API.new('advapi32', 'RegEnumValueA', 'LLPPPPPP', 'L')

    RegOpenKeyExA = Win32API.new('advapi32', 'RegOpenKeyExA', 'LPLLP', 'L')

    RegQueryValueExA = Win32API.new('advapi32', 'RegQueryValueExA','LPLPPP', 'L')

    RegDeleteValue = Win32API.new('advapi32', 'RegDeleteValue','LP', 'L')

    RegDeleteKey = Win32API.new('advapi32', 'RegDeleteKey','LP', 'L')

    begin

      Memcpy = Win32API.new('ntdll', 'memcpy', 'PPL', 'L')

    rescue

      Memcpy = Win32API.new('crtdll', 'memcpy', 'PPL', 'L')

    end

    dll = "\0" * 255

    GPPSA.call('Game', 'Library', '', dll, 255, '.\\Game.ini')

    dll.delete!("\0")

    RGSSGetRTPPath = Win32API.new(dll, 'RGSSGetRTPPath', 'L', 'L')

    RGSSGetPathWithRTP = Win32API.new(dll, 'RGSSGetPathWithRTP', 'L', 'P')

  end

  #===========================================================================

  # ** Module AWorks::Ini

  #===========================================================================

  module Ini

    module_function

    #-------------------------------------------------------------------------

    # * Get String from Ini File

    #-------------------------------------------------------------------------

    def get_string(id, tag = 'Game', file = '.\\Game.ini')

      buffer = "\0" * 255

      API::GPPSA.call(tag, id, '', buffer, 255, file)

      buffer.delete!("\0")

    end

    #-------------------------------------------------------------------------

    # * Write String to Ini File

    #-------------------------------------------------------------------------

    def set_string(string, id, tag = 'Game', file = '.\\Game.ini')

      API::WPPSA.call(tag, id, string, file)

    end

  end

  #===========================================================================

  # ** Module AWorks::Clipboard

  #===========================================================================

  module Clipboard

    module_function

    #-------------------------------------------------------------------------

    # * Read Clipboard Data

    #-------------------------------------------------------------------------

    def read

      API::OpenClipboard.call(0)

      data = API::GetClipboardData.call(7)

      API::CloseClipboard.call

      return '' if data == 0

      lp = API::GlobalLock.call(data)

      len = API::GlobalSize.call(data)

      data2 = ' ' * (len - 1)

      API::Memcpy.call(data2, lp, len)

      API::GlobalUnlock.call(data)

      data2

    end

    #-------------------------------------------------------------------------

    # * Write Data to Clipboard

    #-------------------------------------------------------------------------

    def write(data)

      API::OpenClipboard.call(0)

      API::EmptyClipboard.call

      set_data = API::GlobalAlloc.call(66, data.length + 1)

      len = [data.size + 1, API::GlobalSize.call(set_data)].min

      lp = API::GlobalLock.call(set_data)

      API::Memcpy.call(lp, "#{data}", len)

      API::GlobalUnlock.call(set_data)

      API::SetClipboardData.call(7, set_data)

      API::CloseClipboard.call

    end

    #-------------------------------------------------------------------------

    # * Clear Clipboard Data

    #-------------------------------------------------------------------------

    def empty

      API::EmptyClipboard.call

    end

  end

  #===========================================================================

  # ** Module AWorks::Registry

  #===========================================================================

  module Registry

    module_function

    T_AUTO = -1

    T_SZ = 1

    T_BINARY = 3

    T_DWORD = 4

    HKEYS = {'HKEY_CLASSES_ROOT' => 0x80000000,'HKEY_CURRENT_USER' =>0x80000001,

      'HKEY_LOCAL_MACHINE' => 0x80000002, 'HKEY_USERS' => 0x80000003, 

      'HKEY_CURRENT_CONFIG' => 0x80000005}

    #-------------------------------------------------------------------------

    # * Read a Value

    #-------------------------------------------------------------------------

    def read_value(key, entry)

      key.sub!(/(.*?)\\/, '')

      if !HKEYS[$1].nil?

        hkey = HKEYS[$1]

      else

        return nil

      end

      opened, type, size = [0].pack('V'), [0].pack('V'), [0].pack('V')

      API::RegOpenKeyExA.call(hkey, key, 0, 131097, opened)

      opened = (opened + [0].pack('V')).unpack('V')[0]

      API::RegQueryValueExA.call(opened, entry, 0, type, 0, size)

      data = ' ' * (size + [0].pack('V')).unpack('V')[0]

      API::RegQueryValueExA.call(opened, entry, 0, type, data, size)

      API::RegCloseKey.call(opened)

      data = data[0, (size + [0].pack('V')).unpack('V')[0]]

      type = (type += [0].pack('V')).unpack('V')[0]

      case type

      when 1

        data.chop

      when 2

        data.chop.gsub(/%([^%]+)%/) { ENV[$1] || $& }

      when 3

        data

      when 4

        (data += [0].pack('V')).unpack('V')[0]

      when 5

        data.unpack('N')[0]

      when 7

        data.split(/\0/)

      when 11

        (data.unpack('VV')[1] << 32) | data[0]

      else

        nil

      end

    end

    #-------------------------------------------------------------------------

    # * Enum Keys

    #-------------------------------------------------------------------------

    def enum_keys(key)

      key.sub!(/(.*?)\\/, '')

      if !HKEYS[$1].nil?

        hkey = HKEYS[$1]

      else

        return nil

      end

      index, keys, opened = 0, [], [0].pack('V')

      API::RegOpenKeyExA.call(hkey, key, 0, 131097, opened)

      opened = (opened + [0].pack('V')).unpack('V')[0]

      loop do

        name = ' ' * 514

        size = [514].pack('V')

        result = API::RegEnumKeyExA.call(opened, index, name, size, 0, 0, 0, 0)

        if result == 0

          keys.push(name[0, (size += [0].pack('V')).unpack('V')[0]])

          index += 1

        else

          break

        end

      end

      API::RegCloseKey.call(opened)

      keys

    end

    #-------------------------------------------------------------------------

    # * Enum Values

    #-------------------------------------------------------------------------

    def enum_values(key)

      key.sub!(/(.*?)\\/, '')

      if !HKEYS[$1].nil?

        hkey = HKEYS[$1]

      else

        return nil

      end

      index, entries, opened = 0, [], [0].pack('V')

      API::RegOpenKeyExA.call(hkey, key, 0, 131097, opened)

      opened = (opened + [0].pack('V')).unpack('V')[0]

      loop do

        name = ' ' * 514

        size = [514].pack('V')

        result = API::RegEnumValueA.call(opened, index, name, size, 0, 0, 0, 0)

        if result == 0

          entries.push(name[0, (size += [0].pack('V')).unpack('V')[0]])

          index += 1

        else

          break

        end

      end

      API::RegCloseKey.call(opened)

      entries

    end

    #-------------------------------------------------------------------------

    # * Create Key

    #-------------------------------------------------------------------------

    def create_key(key)

      key.sub!(/(.*?)\\/, '')

      if !HKEYS[$1].nil?

        hkey = HKEYS[$1]

      else

        return nil

      end

      result = [0].pack('V')

      disp = [0].pack('V')

      API::RegCreateKeyExA.call(hkey, key, 0, 0, 0, 131135, 0, result, disp)

      if [disp + [0].pack('V')].unpack('V')[0] == 2

        API::RegCloseKey.call(result)

      end

    end

    #-------------------------------------------------------------------------

    # * Set Value

    #-------------------------------------------------------------------------

    def set_value(key, value, type = T_AUTO)

      key.sub!(/(.*?)\\/, '')

      if !HKEYS[$1].nil?

        hkey = HKEYS[$1]

      else

        return nil

      end

      if type == T_AUTO

        if value.is_a?(Numeric)

          type = T_DWORD

        else

          type = T_SZ

          value = value.to_s

        end

      end

      case type

      when 1, 2

        value = value.to_s + "\0"

      when 7

        value = value.to_a.join("\0") + "\0\0"

      when 3

        value = value.to_s

      when 4

        value = [value.to_i].pack('V')

      when 5

        value = [value.to_i].pack('N')

      when 11

        value = [value.to_i & 0xFFFFFFFF, value.to_i >> 32 ].pack('VV')

      end

      API::RegSetValueExA.call(hkey, key, 0, type, value, value.length)

    end

    #-------------------------------------------------------------------------

    # * Delete Key

    #-------------------------------------------------------------------------

    def delete_key(key, recursive = false)

      skey = key.sub(/(.*?)\\/, '')

      if !HKEYS[$1].nil?

        hkey = HKEYS[$1]

      else

        return nil

      end

      if recursive

        

      else

        API::RegDeleteKey.call(hkey, key)

      end

    end

    #-------------------------------------------------------------------------

    # * Delete Value

    #-------------------------------------------------------------------------

    def delete_value(key)

      key.sub!(/(.*?)\\/, '')

      if !HKEYS[$1].nil?

        hkey = HKEYS[$1]

      else

        return nil

      end

      API::RegDeleteValue.call(hkey, key)

    end

  end

  #---------------------------------------------------------------------------

  # * Variables Declaration

  #---------------------------------------------------------------------------

  ASCII_TABLE = {1=>'☺',2=>'☻',3=>'♥',4=>'♦',5=>'♣',6=>'♠',7=>'•',8=>'◘',9=>'○',

  10=>'◙',11=>'♂',12=>'♀',13=>'♪',14=>'♫',15=>'¤',16=>'►',17=>'◄',18=>'↕',

  19=>'‼',20=>'¶',21=>'§',22=>'▬',23=>'↨',24=>'↑',25=>'↓',26=>'→',27=>'←',

  28=>'∟',29=>'↔',30=>'▲',31=>'▼',32=>' ',33=>'!',34=>'"',35=>'#',36=>'$',

  37=>'%',38=>'&',39=>"'",40=>'(',41=>')',42=>'*',43=>'+',44=>',',45=>'-',

  46=>'.',47=>'/',48=>'0',49=>'1',50=>'2',51=>'3',52=>'4',53=>'5',54=>'6',

  55=>'7',56=>'8',57=>'9',58=>':',59=>';',60=>'<',61=>'=',62=>'>',63=>'?',

  64=>'@',65=>'A',66=>'B',67=>'C',68=>'D',69=>'E',70=>'F',71=>'G',72=>'H',

  73=>'I',74=>'J',75=>'K',76=>'L',77=>'M',78=>'N',79=>'O',80=>'P',81=>'Q',

  82=>'R',83=>'S',84=>'T',85=>'U',86=>'V',87=>'W',88=>'X',89=>'Y',90=>'Z',

  91=>'[',92=>'\\',93=>']',94=>'^',95=>'_',96=>'`',97=>'a',98=>'b',99=>'c',

  100=>'d',101=>'e',102=>'f',103=>'g',104=>'h',105=>'i',106=>'j',107=>'k',

  108=>'l',109=>'m',110=>'n',111=>'o',112=>'p',113=>'q',114=>'r',115=>'s',

  116=>'t',117=>'u',118=>'v',119=>'w',120=>'x',121=>'y',122=>'z',123=>'{',

  124=>'|',125=>'}',126=>'~',127=>'¦',128=>'Ç',129=>'ü',130=>'é',131=>'â',

  132=>'ä',133=>'à',134=>'å',135=>'ç',136=>'ê',137=>'ë',138=>'è',139=>'ï',

  140=>'î',141=>'ì',142=>'Ä',143=>'Å',144=>'É',145=>'æ',146=>'Æ',147=>'ô',

  148=>'ö',149=>'ò',150=>'û',151=>'ù',152=>'ÿ',153=>'Ö',154=>'Ü',155=>'ø',

  156=>'£',157=>'Ø',158=>'×',159=>'ƒ',160=>'á',161=>'í',162=>'ó',163=>'ú',

  164=>'ñ',165=>'Ñ',166=>'ª',167=>'º',168=>'¿',169=>'®',170=>'¬',171=>'½',

  172=>'¼',173=>'¡',174=>'«',175=>'»',176=>'¦',177=>'¦',178=>'¦',179=>'¦',

  180=>'¦',181=>'Á',182=>'Â',183=>'À',184=>'©',185=>'¦',186=>'¦',187=>'+',

  188=>'+',189=>'¢',190=>'¥',191=>'+',192=>'+',193=>'-',194=>'-',195=>'+',

  196=>'-',197=>'+',198=>'ã',199=>'Ã',200=>'+',201=>'+',202=>'-',203=>'-',

  204=>'¦',205=>'-',206=>'+',207=>'¤',208=>'ð',209=>'Ð',210=>'Ê',211=>'Ë',

  212=>'È',213=>'i',214=>'Í',215=>'Î',216=>'Ï',217=>'+',218=>'+',219=>'¦',

  220=>'_',221=>'¦',222=>'Ì',223=>'¯',224=>'Ó',225=>'ß',226=>'Ô',227=>'Ò',

  228=>'õ',229=>'Õ',230=>'µ',231=>'þ',232=>'Þ',233=>'Ú',234=>'Û',235=>'Ù',

  236=>'ý',237=>'Ý',238=>'¯',239=>'´',240=>'­',241=>'±',242=>'=',243=>'¾',

  244=>'¶',245=>'§',246=>'÷',247=>'¸',248=>'°',249=>'¨',250=>'·',251=>'¹',

  252=>'³',253=>'²',254=>'¦',255=>' '}

  TRANSLATE_TABLE ={"\225"=>'•',"\244"=>'¤',"\266"=>'¶',"\247"=>'§',"\307"=>'Ç',

  "\374"=>'ü',"\351"=>'é',"\342"=>'â',"\344"=>'ä',"\340"=>'à',"\345"=>'å',

  "\347"=>'ç',"\352"=>'ê',"\353"=>'ë',"\350"=>'è',"\357"=>'ï',"\356"=>'î',

  "\354"=>'ì',"\304"=>'Ä',"\305"=>'Å',"\311"=>'É',"\346"=>'æ',"\306"=>'Æ',

  "\364"=>'ô',"\366"=>'ö',"\362"=>'ò',"\373"=>'û',"\371"=>'ù',"\377"=>'ÿ',

  "\326"=>'Ö',"\334"=>'Ü',"\370"=>'ø',"\243"=>'£',"\330"=>'Ø',"\327"=>'×',

  "\203"=>'ƒ',"\341"=>'á',"\355"=>'í',"\363"=>'ó',"\372"=>'ú',"\361"=>'ñ',

  "\321"=>'Ñ',"\252"=>'ª',"\272"=>'º',"\277"=>'¿',"\256"=>'®',"\254"=>'¬',

  "\275"=>'½',"\274"=>'¼',"\241"=>'¡',"\253"=>'«',"\273"=>'»',"\301"=>'Á',

  "\302"=>'Â',"\300"=>'À',"\251"=>'©',"\242"=>'¢',"\245"=>'¥',"\343"=>'ã',

  "\303"=>'Ã',"\244"=>'¤',"\360"=>'ð',"\320"=>'Ð',"\312"=>'Ê',"\313"=>'Ë',

  "\310"=>'È',"\315"=>'Í',"\316"=>'Î',"\317"=>'Ï',"\314"=>'Ì',"\257"=>'¯',

  "\323"=>'Ó',"\337"=>'ß',"\324"=>'Ô',"\322"=>'Ò',"\365"=>'õ',"\325"=>'Õ',

  "\265"=>'µ',"\376"=>'þ',"\336"=>'Þ',"\332"=>'Ú',"\333"=>'Û',"\331"=>'Ù',

  "\375"=>'ý',"\335"=>'Ý',"\257"=>'¯',"\264"=>'´',"\255"=>'­',"\261"=>'±',

  "\276"=>'¾',"\266"=>'¶',"\247"=>'§',"\367"=>'÷',"\270"=>'¸',"\260"=>'°',

  "\250"=>'¨',"\267"=>'·',"\271"=>'¹',"\263"=>'³',"\262"=>'²',"\240"=>' ',

  "\t"=>'        ',"\200"=>'€'}

  #---------------------------------------------------------------------------

  # * Get Fonts Names

  #---------------------------------------------------------------------------

  def get_fonts_names

    key = "HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\#{ENV['OS'].sub(/_/,' ')}\\"

    fonts = Registry.enum_values(key + 'CurrentVersion\\Fonts')

    fonts.each_index {|f|

      fonts[f].sub!(' (TrueType)', '')

      fonts[f] = nil if !Font.exist?(fonts[f])

    }.delete(nil)

    fonts

  end

  #---------------------------------------------------------------------------

  # * Get RGSS Player HWND index

  #---------------------------------------------------------------------------

  def get_hwnd

    if @hwnd.nil?

      @hwnd = API::FindWindowA.call('RGSS Player', Ini.get_string('Title'))

    else

      @hwnd

    end

  end

  #---------------------------------------------------------------------------

  # * Get RGSS DLL

  #---------------------------------------------------------------------------

  def get_rgssdll

    Ini.get_string('Library')

  end

  #-------------------------------------------------------------------------

  # * Get RTP Path

  #-------------------------------------------------------------------------

  def get_rtp_path(rtp = 0)

    API::RGSSGetPathWithRTP.call(API::RGSSGetRTPPath.cal(rtp))

  end

  #-------------------------------------------------------------------------

  # * Get Mouse Swap Buttons Flag

  #-------------------------------------------------------------------------

  def get_mouse_swap_buttons_flag

    result = API::SwapMouseButton.call(0)

    if result == 0

      API::SwapMouseButton.call(0)

      0

    else

      API::SwapMouseButton.call(1)

      1

    end

  end

  #---------------------------------------------------------------------------

  # * Initialize AWorks Library

  #---------------------------------------------------------------------------

  API::Initialize.call(self.get_hwnd)

end

 

#=============================================================================

# ** Class Array

#=============================================================================

class Array

  #---------------------------------------------------------------------------

  # * Recursive Clone

  #---------------------------------------------------------------------------

  def recursive_clone

    clon = self.clone

    clon.each_index do |i|

      clon[i] = clon[i].recursive_clone rescue clon[i].clone rescue clon[i]

    end

    clon

  end

  alias_method(:rclone, :recursive_clone)

  #---------------------------------------------------------------------------

  # * To Hash

  #---------------------------------------------------------------------------

  def to_hash

    hash = Hash.new

    self.each_index {|i| hash[i] = self[i]}

    hash

  end

  #---------------------------------------------------------------------------

  # * Indexes Reversed

  #---------------------------------------------------------------------------

  def rindexes(*values)

    array = Array.new

    self.each_index {|i| array.push(i) if values.include?(self[i])}

    array

  end

  #---------------------------------------------------------------------------

  # * Deep

  #---------------------------------------------------------------------------

  def deep(deep = -1)

    tmp_deep = deep + 1

    deep = tmp_deep

    self.each do |i|

      deep = i.deep(tmp_deep) if deep < i.deep(tmp_deep) rescue nil

    end

    deep

  end

  #---------------------------------------------------------------------------

  # * Recursive Flatten

  #---------------------------------------------------------------------------

  def recursive_flatten

    array = self.recursive_clone

    array.each_index do |i|

      array[i] = array[i].to_a if array[i].is_a?(Hash)

      array[i] = array[i].recursive_flatten rescue array[i]

    end

    array.flatten!

    array

  end

  alias_method(:rflatten, :recursive_flatten)

  #---------------------------------------------------------------------------

  # * Destructive Recursive Flatten

  #---------------------------------------------------------------------------

  def recursive_flatten!

    self.each_index do |i|

      self[i] = self[i].to_a if self[i].is_a?(Hash)

      self[i] = self[i].recursive_flatten! rescue self[i]

    end

    self.flatten!

    self

  end

  alias_method(:rflatten!, :recursive_flatten!)

  #---------------------------------------------------------------------------

  # * Insert

  #---------------------------------------------------------------------------

  def insert(i, obj)

    if i == 0

      obj + self

    elsif i == self.size

      self + obj

    elsif self.size < i

      self + Array.new(i - self.size) +  obj

    else

      self[0, i - 1] + obj + self[i, self.size]

    end

  end

end

 

#=============================================================================

# ** Class Hash

#=============================================================================

class Hash

  #---------------------------------------------------------------------------

  # * Recursive Clone

  #---------------------------------------------------------------------------

  def recursive_clone

    clon = self.clone

    clon.each_key do |i|

      clon[i] = clon[i].recursive_clone rescue clon[i].clone rescue clon[i]

    end

    clon

  end

  alias_method(:rclone, :recursive_clone)

  #---------------------------------------------------------------------------

  # * Deep

  #---------------------------------------------------------------------------

  def deep(deep = -1)

    tmp_deep = deep + 1

    key_deep = tmp_deep

    value_deep = tmp_deep

    self.each do |k, v|

      key_deep = k.deep(tmp_deep) if key_deep < k.deep(tmp_deep) rescue nil

      value_deep = v.deep(tmp_deep) if value_deep < v.deep(tmp_deep) rescue nil

    end

    if key_deep > value_deep

      key_deep

    else

      value_deep

    end

  end

  #---------------------------------------------------------------------------

  # * To Array, combining Key and Value

  #---------------------------------------------------------------------------

  def fusion

    array = self.sort

    array.each_index do|i|

      array[i] = array[i][0] + array[i][1] rescue array[i]

    end

    array

  end

end

 

#=============================================================================

# ** Nil Class

#=============================================================================

class NilClass

  def clone;end

end

 

#=============================================================================

# ** Module Math

#=============================================================================

module Math

  #---------------------------------------------------------------------------

  # * Radians to degrees

  #---------------------------------------------------------------------------

  def Math.radian2degree(r)

    r * 180 / Math::PI

  end

  #---------------------------------------------------------------------------

  # * Degrees to radians

  #---------------------------------------------------------------------------

  def Math.degree2radian(g)

    g * Math::PI / 180

  end

  #---------------------------------------------------------------------------

  # * Quick Cosine and Sine

  #---------------------------------------------------------------------------

  @cos = {}

  @sin = {}

  for i in 0..360

    @cos[i] = Math.cos(Math.degree2radian(i - 90))

    @sin[i] = Math.sin(Math.degree2radian(i - 90))

  end

  def Math.quick_cos(i)

    @cos[i.round % 360]

  end

  def Math.quick_sin(i)

    @sin[i.round % 360]

  end

end

 

#=============================================================================

# ** Class String

#=============================================================================

class String

  #---------------------------------------------------------------------------

  # * Pixel Width of String

  #---------------------------------------------------------------------------

  def pixel_width(*args)

    bitmap = Bitmap.new(1, 1)

    if args[0].is_a?(Font)

      bitmap.font.size = args[0].size

      bitmap.font.name = args[0].name

      bitmap.font.bold = args[0].bold

    else

      bitmap.font.size = args[0].nil? ? Font.default_size : args[0]

      bitmap.font.name = args[1].nil? ? Font.default_name : args[1]

      bitmap.font.bold = args[2].nil? ? Font.default_bold : args[2]

    end

    pix = bitmap.text_size(self).width

    bitmap.dispose

    pix

  end

  #---------------------------------------------------------------------------

  # * Pixel Height of String

  #---------------------------------------------------------------------------

  def pixel_height(*args)

    bitmap = Bitmap.new(1, 1)

    if args[0].is_a?(Font)

      bitmap.font.size = args[0].size

      bitmap.font.name = args[0].name

      bitmap.font.bold = args[0].bold

    else

      bitmap.font.size = args[0].nil? ? Font.default_size : args[0]

      bitmap.font.name = args[1].nil? ? Font.default_name : args[1]

      bitmap.font.bold = args[2].nil? ? Font.default_bold : args[2]

    end

    pix = bitmap.text_size(self).height

    bitmap.dispose

    pix

  end

  #---------------------------------------------------------------------------

  # * Cut String to Strings with less or equal size than Width

  #---------------------------------------------------------------------------

  def width_slice(width, *args)

    bitmap = Bitmap.new(1, 1)

    if args[0].is_a?(Font)

      bitmap.font.size = args[0].size

      bitmap.font.name = args[0].name

      bitmap.font.bold = args[0].bold

    else

      bitmap.font.size = args[0].nil? ? Font.default_size : args[0]

      bitmap.font.name = args[1].nil? ? Font.default_name : args[1]

      bitmap.font.bold = args[2].nil? ? Font.default_bold : args[2]

    end

    result = ['']

    txt = self.clone.scan(/./)

    txt.each_index do |i|

      if txt[i].is_a?(String)

        txt[i] = [txt[i], bitmap.text_size(txt[i]).width]

        if txt.include?(txt[i][0])

          txt.collect! do |e|

            e == txt[i][0] ? txt[i] : e

          end

        end

      end

    end

    bitmap.dispose

    act_width = 0

    loop do

      if txt.size > 0

        tmp_width = act_width + txt[0][1]

        tmp_width += txt[1][1] if txt.size > 1

        if width >= act_width + txt[0][1]

          result[result.size - 1] += txt[0][0]

          act_width += txt[0][1]

          txt.delete_at(0)

        else

          result.push('')

          act_width = 0

        end

      else

        break

      end

    end

    result

  end

  #---------------------------------------------------------------------------

  # * Max Font Size for Width

  #---------------------------------------------------------------------------

  def font_size_width(width, *args)

    bitmap = Bitmap.new(1, 1)

    if args[0].is_a?(Font)

      bitmap.font.name = args[0].name

      bitmap.font.bold = args[0].bold

    else

      bitmap.font.name = args[0].nil? ? Font.default_name : args[0]

      bitmap.font.bold = args[1].nil? ? Font.default_bold : args[1]

    end

    size = 6

    for i in 6..96

      bitmap.font.size = i

      size = i if bitmap.text_size(self).width <= width

    end

    bitmap.dispose

    size

  end

  #---------------------------------------------------------------------------

  # * Max Font Size for Height

  #---------------------------------------------------------------------------

  def font_size_height(height, *args)

    bitmap = Bitmap.new(1, 1)

    if args[0].is_a?(Font)

      bitmap.font.name = args[0].name

      bitmap.font.bold = args[0].bold

    else

      bitmap.font.name = args[0].nil? ? Font.default_name : args[0]

      bitmap.font.bold = args[1].nil? ? Font.default_bold : args[1]

    end

    size = 6

    for i in 6..96

      bitmap.font.size = i

      size = i if bitmap.text_size(self).height <= height

    end

    bitmap.dispose

    size

  end

  #---------------------------------------------------------------------------

  # * Max Font Size for Width & Height

  #---------------------------------------------------------------------------

  def font_size(width, height, *args)

    bitmap = Bitmap.new(1, 1)

    if args[0].is_a?(Font)

      bitmap.font.name = args[0].name

      bitmap.font.bold = args[0].bold

    else

      bitmap.font.name = args[0].nil? ? Font.default_name : args[0]

      bitmap.font.bold = args[1].nil? ? Font.default_bold : args[1]

    end

    size = 6

    for i in 6..96

      bitmap.font.size = i

      if bitmap.text_size(self).width <= width and

         bitmap.text_size(self).height <= height 

        size = i

      end

    end

    bitmap.dispose

    size

  end

  #---------------------------------------------------------------------------

  # * Transform the undrawable Characters

  #---------------------------------------------------------------------------

  def trans_undrawable_chr(font = Font.new, chr = '?')

    bmp = Bitmap.new(1, 1)

    bmp.font = font

    txt = ''

    scan(/./).each {|c| txt += (bmp.text_size(c).width == 0) ? chr : c}

    txt

  end

end

 

#=============================================================================

# ** Class Bitmap

#=============================================================================

class Bitmap

  #---------------------------------------------------------------------------

  # * Draw Text AWorks

  #---------------------------------------------------------------------------

  def adraw_text(*args)

    if args.size.between?(2,3)

      args[2] = 0 if args.size == 2

      args[4] = args[1]

      args[5] = args[2]

      args[1] = args[0].y

      args[2] = args[0].width

      args[3] = args[0].height

      args[0] = args[0].x

    elsif args.size == 5

      args[5] = 0

    end

    if args[4].is_a?(Array)

      args[4] = args[4].rflatten

      args[4].each do |t|

        t = t.nil? ? 'nil' : "#{t}"

        width = args[2].nil? ? self.text_size(t).width : args[2]

        height = args[3].nil? ? self.text_size('0').height : args[3]

        self.draw_text(args[0], args[1], width, height, t, args[5])

        args[1] += height

      end

      return

    elsif args[4].is_a?(Hash)

      args[4] = args[4].fusion

      args[4] = args[4].rflatten

      args[4].each do |t|

        t = t.nil? ? 'nil' : "#{t}"

        width = args[2].nil? ? self.text_size(t).width : args[2]

        height = args[3].nil? ? self.text_size('0').height : args[3]

        self.draw_text(args[0], args[1], width, height, t, args[5])

        args[1] += height

      end

      return

    elsif !args[4].is_a?(String)

      if args[4].to_s == ''

        args[4] = args[4].inspect

      else

        args[4] = args[4].to_s

      end

    end

    args[2] = args[2].nil? ? self.text_size(args[4]).width + 2 : args[2]

    args[3] = args[3].nil? ? self.text_size('0').height + 2 : args[3]

    draw_text(*args)

  end

end

 

#=============================================================================

# ** Module Graphics

#=============================================================================

module Graphics

  @auto_update = []

  class << self

    #-------------------------------------------------------------------------

    # * Object method auto-call

    #-------------------------------------------------------------------------

    unless self.method_defined?(:alibrary_update)

      alias_method(:alibrary_update, :update)

    end

    attr_accessor(:auto_update)

    def update

      alibrary_update

      @auto_update.each do |k|

        k[0].method(k[1]).call

        if !k[2].nil?

          k[2] -= 1

          k = nil if k[2] <= 0

        end

      end

      @auto_update.delete_if {|x| if !x[2].nil? : x[2] <= 0 else false end}

    end

  end

end
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top