Class: Factorix::Runtime::MacOS
- Defined in:
- lib/factorix/runtime/mac_os.rb
Overview
macOS runtime environment
This implementation assumes Factorio is installed via Steam. For other installation methods (GOG, itch.io, standalone), users should configure the installation path in the Factorix configuration file.
Instance Method Summary collapse
-
#data_dir ⇒ Pathname
Get the Factorio data directory path.
-
#executable_path ⇒ Pathname
Get the Factorio executable path.
-
#factorix_log_path ⇒ Pathname
Get the Factorix log file path.
-
#user_dir ⇒ Pathname
Get the Factorio user directory path.
Methods inherited from Base
#current_log_path, #factorix_cache_dir, #factorix_config_path, inherited, #launch, #lock_path, #mod_dir, #mod_list_path, #mod_settings_path, #player_data_path, #previous_log_path, #running?, #save_dir, #script_output_dir, #xdg_cache_home_dir, #xdg_config_home_dir, #xdg_data_home_dir, #xdg_state_home_dir
Instance Method Details
#data_dir ⇒ Pathname
Get the Factorio data directory path
This directory contains the base game data and built-in expansion MODs.
28 |
# File 'lib/factorix/runtime/mac_os.rb', line 28 def data_dir = Pathname(Dir.home) + "Library/Application Support/Steam/steamapps/common/Factorio/factorio.app/Contents/data" |
#executable_path ⇒ Pathname
Get the Factorio executable path
Returns the default Steam installation path on macOS.
16 |
# File 'lib/factorix/runtime/mac_os.rb', line 16 def executable_path = Pathname(Dir.home) + "Library/Application Support/Steam/steamapps/common/Factorio/factorio.app/Contents/MacOS/factorio" |
#factorix_log_path ⇒ Pathname
Get the Factorix log file path
Returns the path to the Factorix log file using macOS convention.
35 |
# File 'lib/factorix/runtime/mac_os.rb', line 35 def factorix_log_path = Pathname(Dir.home) + "Library/Logs/factorix/factorix.log" |
#user_dir ⇒ Pathname
Get the Factorio user directory path
21 |
# File 'lib/factorix/runtime/mac_os.rb', line 21 def user_dir = Pathname(Dir.home) + "Library/Application Support/factorio" |