mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-12 19:31:41 +00:00
Merge pull request #1339 from Areloch/Remove_Demo_Mode_Checks
Remove demo and trial checks
This commit is contained in:
commit
d268199f4f
25 changed files with 355 additions and 846 deletions
|
|
@ -55,10 +55,6 @@ bool GameTSCtrl::onAdd()
|
|||
if ( !Parent::onAdd() )
|
||||
return false;
|
||||
|
||||
#ifdef TORQUE_DEMO_WATERMARK
|
||||
mWatermark.init();
|
||||
#endif
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -172,10 +168,6 @@ void GameTSCtrl::onRender(Point2I offset, const RectI &updateRect)
|
|||
|
||||
if(!skipRender || true)
|
||||
Parent::onRender(offset, updateRect);
|
||||
|
||||
#ifdef TORQUE_DEMO_WATERMARK
|
||||
mWatermark.render(getExtent());
|
||||
#endif
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
|
|
|||
|
|
@ -30,12 +30,6 @@
|
|||
#include "gui/3d/guiTSControl.h"
|
||||
#endif
|
||||
|
||||
#ifdef TORQUE_DEMO_WATERMARK
|
||||
#ifndef _WATERMARK_H_
|
||||
#include "demo/watermark/watermark.h"
|
||||
#endif
|
||||
#endif
|
||||
|
||||
class ProjectileData;
|
||||
class GameBase;
|
||||
|
||||
|
|
@ -45,10 +39,6 @@ class GameTSCtrl : public GuiTSCtrl
|
|||
private:
|
||||
typedef GuiTSCtrl Parent;
|
||||
|
||||
#ifdef TORQUE_DEMO_WATERMARK
|
||||
Watermark mWatermark;
|
||||
#endif
|
||||
|
||||
void makeScriptCall(const char *func, const GuiEvent &evt) const;
|
||||
|
||||
public:
|
||||
|
|
|
|||
|
|
@ -61,10 +61,6 @@
|
|||
// For the TickMs define... fix this for T2D...
|
||||
#include "T3D/gameBase/processList.h"
|
||||
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
#include "demo/pestTimer/pestTimer.h"
|
||||
#endif
|
||||
|
||||
#ifdef TORQUE_ENABLE_VFS
|
||||
#include "platform/platformVFS.h"
|
||||
#endif
|
||||
|
|
@ -309,10 +305,6 @@ void StandardMainLoop::init()
|
|||
// Hook in for UDP notification
|
||||
Net::smPacketReceive.notify(GNet, &NetInterface::processPacketReceiveEvent);
|
||||
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
PestTimerinit();
|
||||
#endif
|
||||
|
||||
#ifdef TORQUE_DEBUG_GUARD
|
||||
Memory::flagCurrentAllocs( Memory::FLAG_Static );
|
||||
#endif
|
||||
|
|
@ -613,11 +605,6 @@ bool StandardMainLoop::doMainLoop()
|
|||
ThreadPool::processMainThreadWorkItems();
|
||||
Sampler::endFrame();
|
||||
PROFILE_END_NAMED(MainLoop);
|
||||
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
CheckTimer();
|
||||
CheckBlocker();
|
||||
#endif
|
||||
}
|
||||
|
||||
return keepRunning;
|
||||
|
|
|
|||
|
|
@ -139,22 +139,4 @@ DefineConsoleFunction( getBuildString, const char*, (), , "Get the type of build
|
|||
#endif
|
||||
}
|
||||
|
||||
ConsoleFunctionGroupEnd( CompileInformation );
|
||||
|
||||
DefineConsoleFunction( isDemo, bool, (), , "")
|
||||
{
|
||||
#ifdef TORQUE_DEMO
|
||||
return true;
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
DefineConsoleFunction( isWebDemo, bool, (), , "")
|
||||
{
|
||||
#ifdef TORQUE_DEMO
|
||||
return Platform::getWebDeployment();
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
ConsoleFunctionGroupEnd( CompileInformation );
|
||||
|
|
@ -34,10 +34,6 @@
|
|||
#include "core/util/journal/journal.h"
|
||||
#include "core/util/uuid.h"
|
||||
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
#include "gui/core/guiCanvas.h"
|
||||
#endif
|
||||
|
||||
// This is a temporary hack to get tools using the library to
|
||||
// link in this module which contains no other references.
|
||||
bool LinkConsoleFunctions = false;
|
||||
|
|
|
|||
|
|
@ -144,23 +144,12 @@ GuiCanvas::GuiCanvas(): GuiControl(),
|
|||
#else
|
||||
mNumFences = 0;
|
||||
#endif
|
||||
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
mPurchaseScreen = NULL;
|
||||
#endif
|
||||
}
|
||||
|
||||
GuiCanvas::~GuiCanvas()
|
||||
{
|
||||
SAFE_DELETE(mPlatformWindow);
|
||||
SAFE_DELETE_ARRAY( mFences );
|
||||
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
// if (mPurchaseScreen)
|
||||
// {
|
||||
// SAFE_DELETE(mPurchaseScreen);
|
||||
// }
|
||||
#endif
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
|
@ -282,13 +271,6 @@ bool GuiCanvas::onAdd()
|
|||
// Define the menu bar for this canvas (if any)
|
||||
Con::executef(this, "onCreateMenu");
|
||||
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
mPurchaseScreen = new PurchaseScreen;
|
||||
mPurchaseScreen->init();
|
||||
|
||||
mLastPurchaseHideTime = 0;
|
||||
#endif
|
||||
|
||||
Sim::findObject("PlatformGenericMenubar", mMenuBarCtrl);
|
||||
|
||||
return parentRet;
|
||||
|
|
@ -296,11 +278,6 @@ bool GuiCanvas::onAdd()
|
|||
|
||||
void GuiCanvas::onRemove()
|
||||
{
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
if (mPurchaseScreen && mPurchaseScreen->isAwake())
|
||||
removeObject(mPurchaseScreen);
|
||||
#endif
|
||||
|
||||
// And the process list
|
||||
Process::remove(this, &GuiCanvas::paint);
|
||||
|
||||
|
|
@ -1362,11 +1339,6 @@ bool GuiCanvas::rootMouseWheelDown(const GuiEvent &event)
|
|||
|
||||
void GuiCanvas::setContentControl(GuiControl *gui)
|
||||
{
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
if (mPurchaseScreen->isForceExit())
|
||||
return;
|
||||
#endif
|
||||
|
||||
// Skip out if we got passed NULL (why would that happen?)
|
||||
if(!gui)
|
||||
return;
|
||||
|
|
@ -1435,11 +1407,6 @@ GuiControl *GuiCanvas::getContentControl()
|
|||
|
||||
void GuiCanvas::pushDialogControl(GuiControl *gui, S32 layer, bool center)
|
||||
{
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
if (mPurchaseScreen->isForceExit())
|
||||
return;
|
||||
#endif
|
||||
|
||||
if( center )
|
||||
gui->setPosition( getExtent().x / 2 - gui->getExtent().x / 2,
|
||||
getExtent().y / 2 - gui->getExtent().y / 2 );
|
||||
|
|
@ -1956,10 +1923,6 @@ void GuiCanvas::renderFrame(bool preRenderOnly, bool bufferSwap /* = true */)
|
|||
// this situation is necessary because it needs to take the screenshot
|
||||
// before the buffers swap
|
||||
|
||||
#ifdef TORQUE_DEMO_TIMEOUT
|
||||
checkTimeOut();
|
||||
#endif
|
||||
|
||||
PROFILE_END();
|
||||
|
||||
// Fence logic here, because this is where endScene is called.
|
||||
|
|
|
|||
|
|
@ -37,12 +37,6 @@
|
|||
#include "windowManager/platformWindowMgr.h"
|
||||
#include "gfx/gfxFence.h"
|
||||
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
#ifndef _PURCHASESCREEN_H_
|
||||
#include "demo/purchase/purchaseScreen.h"
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/// A canvas on which rendering occurs.
|
||||
///
|
||||
///
|
||||
|
|
@ -442,21 +436,6 @@ public:
|
|||
|
||||
private:
|
||||
static const U32 MAX_GAMEPADS = 4; ///< The maximum number of supported gamepads
|
||||
|
||||
#ifdef TORQUE_DEMO_PURCHASE
|
||||
private:
|
||||
PurchaseScreen* mPurchaseScreen;
|
||||
U32 mLastPurchaseHideTime;
|
||||
|
||||
public:
|
||||
void showPurchaseScreen(bool show, bool startBlocker, const char* location, bool doExit);
|
||||
void updatePurchaseScreen(const char* value);
|
||||
#endif
|
||||
|
||||
#ifdef TORQUE_DEMO_TIMEOUT
|
||||
private:
|
||||
void checkTimeOut();
|
||||
#endif
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue