mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-07-22 11:39:19 +02:00
continued refactoring: traction, events, event launchers, sounds; additional diagnostics timers, minor performance enhancements and bug fixes
This commit is contained in:
55
EvLaunch.h
55
EvLaunch.h
@@ -10,32 +10,43 @@ http://mozilla.org/MPL/2.0/.
|
||||
#pragma once
|
||||
|
||||
#include <string>
|
||||
#include "Classes.h"
|
||||
|
||||
class TEventLauncher
|
||||
{
|
||||
private:
|
||||
int iKey;
|
||||
double DeltaTime;
|
||||
double UpdatedTime;
|
||||
double fVal1;
|
||||
double fVal2;
|
||||
std::string szText;
|
||||
int iHour, iMinute; // minuta uruchomienia
|
||||
public:
|
||||
double dRadius;
|
||||
#include "Classes.h"
|
||||
#include "scenenode.h"
|
||||
|
||||
class TEventLauncher : public editor::basic_node {
|
||||
|
||||
public:
|
||||
// constructor
|
||||
TEventLauncher( scene::node_data const &Nodedata ) : basic_node( Nodedata ) {}
|
||||
// legacy constructor
|
||||
TEventLauncher() = default;
|
||||
|
||||
// methods
|
||||
bool Load( cParser *parser );
|
||||
// checks conditions associated with the event. returns: true if the conditions are met
|
||||
bool check_conditions();
|
||||
bool IsGlobal() const;
|
||||
// members
|
||||
std::string asEvent1Name;
|
||||
std::string asEvent2Name;
|
||||
std::string asMemCellName;
|
||||
TEvent *Event1;
|
||||
TEvent *Event2;
|
||||
TMemCell *MemCell;
|
||||
int iCheckMask;
|
||||
TEventLauncher();
|
||||
void Init();
|
||||
bool Load(cParser *parser);
|
||||
bool Render();
|
||||
bool IsGlobal();
|
||||
TEvent *Event1 { nullptr };
|
||||
TEvent *Event2 { nullptr };
|
||||
TMemCell *MemCell { nullptr };
|
||||
int iCheckMask { 0 };
|
||||
double dRadius { 0.0 };
|
||||
|
||||
private:
|
||||
// members
|
||||
int iKey { 0 };
|
||||
double DeltaTime { -1.0 };
|
||||
double UpdatedTime { 0.0 };
|
||||
double fVal1 { 0.0 };
|
||||
double fVal2 { 0.0 };
|
||||
std::string szText;
|
||||
int iHour { -1 };
|
||||
int iMinute { -1 }; // minuta uruchomienia
|
||||
};
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user