mirror of
https://github.com/copyrighttxt/watrbx-game-engine.git
synced 2026-09-04 20:57:49 +00:00
25 lines
659 B
C++
25 lines
659 B
C++
#pragma once
|
|
|
|
#include "v8datamodel/TeleportCallback.h"
|
|
#include "FunctionMarshaller.h"
|
|
|
|
class PlaceLauncher;
|
|
class Teleporter: public RBX::TeleportCallback
|
|
{
|
|
RBX::FunctionMarshaller* mMarshaller;
|
|
|
|
static void teleportImpl(std::string url, std::string ticket, std::string script);
|
|
|
|
public:
|
|
Teleporter(RBX::FunctionMarshaller* marshaller): mMarshaller(marshaller)
|
|
{
|
|
}
|
|
|
|
virtual void doTeleport(const std::string& url, const std::string& ticket, const std::string& script)
|
|
{
|
|
mMarshaller->Submit(boost::bind(teleportImpl, url, ticket, script));
|
|
}
|
|
|
|
virtual bool isTeleportEnabled() const { return true; }
|
|
};
|