napcae / ApolloLive

Hades mod for integration with the Apollo calculator.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ApolloLive

This Hades plugin provides live integration with the Apollo trait calculator, as well as a browser logging tool for use by other mod developers.  

Dependencies

 

Installation

Warning! Backup save files before using.

  1. Copy the ApolloLive mod directory to ...\Steam\steamapps\common\Hades\Content\Mods or equivalent.
  2. Run the Hades Mod Importer.
  3. Open the Apollo trait calculator.
  4. Click the connection status bar to scan for a connection.
  5. Launch the x86 executable at ...\Steam\steamapps\common\Hades\x86\Hades.exe or equivalent.
  6. Load a save file and start a run.

 

 

ApolloLive.Send

ApolloLive provides the Send function for use by other modders in exploration and debugging. After installing ApolloLive, other mods may send messages to the Apollo app running in the web browser. By default, a connected ApolloLive logs any such messages to the console:

 

MyMod.lua

ApolloLive.Send('Hello World')

Browser Console:

> ApolloLive: Hello World

 

Messages can also be lua tables, which will be converted to json objects, transmitted, and displayed as javascript objects in the browser console:

MyMod.lua

ApolloLive.Send(CurrentRun.Hero)

Browser Console: apollo_console

This can be used to explore the structure of ingame data objects.

 

If you would like to overwrite the default event handler for messages passed to ApolloLive.Send, simply pass a new function handler to ApolloLive.setListener in the browser console:

function handler(msg) {
  console.log('received a message', msg)
}

ApolloLive.setListener(handler)


> received a message    Hello World

About

Hades mod for integration with the Apollo calculator.

License:MIT License


Languages

Language:Lua 100.0%