Skip to content

Instantly share code, notes, and snippets.

@rondreas
Created May 4, 2021 14:18
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save rondreas/96999e8c4a4aa1ade53dc6a688ed1a14 to your computer and use it in GitHub Desktop.
Hello world for Modo
#include <lx_log.hpp>
#include <lxu_log.hpp>
#include <lxu_command.hpp>
#define SRVNAME_COMMAND "hello.world"
class CHelloCommand : public CLxCommand
{
public:
CLxUser_LogService log_service;
void execute()
{
log_service.DebugOut(LXi_DBLOG_NORMAL, "Hello, World!");
}
};
static CLxMeta_Command<CHelloCommand> cmd_meta(SRVNAME_COMMAND);
static class CRoot : public CLxMetaRoot
{
bool pre_init() LXx_OVERRIDE
{
cmd_meta.set_type_UI();
add(&cmd_meta);
return false;
}
} root_meta;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment