mirror of
https://github.com/minetest/minetest.git
synced 2024-09-12 08:28:36 +02:00
Player class: disable copy
This commit is contained in:
parent
182bd6ab45
commit
ab9f3b92f2
@ -23,6 +23,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||||||
#include "irrlichttypes_bloated.h"
|
#include "irrlichttypes_bloated.h"
|
||||||
#include "inventory.h"
|
#include "inventory.h"
|
||||||
#include "constants.h"
|
#include "constants.h"
|
||||||
|
#include "util/basic_macros.h"
|
||||||
#include <list>
|
#include <list>
|
||||||
#include <mutex>
|
#include <mutex>
|
||||||
|
|
||||||
@ -88,9 +89,6 @@ struct CollisionInfo;
|
|||||||
struct HudElement;
|
struct HudElement;
|
||||||
class Environment;
|
class Environment;
|
||||||
|
|
||||||
// IMPORTANT:
|
|
||||||
// Do *not* perform an assignment or copy operation on a Player or
|
|
||||||
// RemotePlayer object! This will copy the lock held for HUD synchronization
|
|
||||||
class Player
|
class Player
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
@ -98,6 +96,8 @@ public:
|
|||||||
Player(const char *name, IItemDefManager *idef);
|
Player(const char *name, IItemDefManager *idef);
|
||||||
virtual ~Player() = 0;
|
virtual ~Player() = 0;
|
||||||
|
|
||||||
|
DISABLE_CLASS_COPY(Player);
|
||||||
|
|
||||||
virtual void move(f32 dtime, Environment *env, f32 pos_max_d)
|
virtual void move(f32 dtime, Environment *env, f32 pos_max_d)
|
||||||
{}
|
{}
|
||||||
virtual void move(f32 dtime, Environment *env, f32 pos_max_d,
|
virtual void move(f32 dtime, Environment *env, f32 pos_max_d,
|
||||||
|
Loading…
Reference in New Issue
Block a user