16 lines
302 B
Elixir
16 lines
302 B
Elixir
defmodule Example.Game do
|
|
require Logger
|
|
use Amethyst.API.Game, meta: [default: true]
|
|
|
|
@impl true
|
|
def instantiate() do
|
|
{:ok, [:hello]}
|
|
end
|
|
|
|
@impl true
|
|
def login(from, cfg, state) do
|
|
Logger.info("Player logged in from #{inspect(from)}: #{inspect(cfg)}")
|
|
{:ok, state}
|
|
end
|
|
end
|