aboutsummaryrefslogtreecommitdiff
path: root/src/client.h
diff options
context:
space:
mode:
authorWeblate <42@minetest.ru>2013-03-30 19:49:52 +0100
committerWeblate <42@minetest.ru>2013-03-30 19:49:52 +0100
commita0566270d9fa075afa36a7e3e68c690b1b23ba90 (patch)
tree6bc88127ee67b7bf4d6a2d6f9d0a9e5f997d1dd1 /src/client.h
parent0d83bdc3aa9f1077836aacb833ac4ad9bbb9a4f4 (diff)
parent1aa50b13622c1e264044839ecdf0152670dae6ce (diff)
downloadminetest-a0566270d9fa075afa36a7e3e68c690b1b23ba90.tar.gz
minetest-a0566270d9fa075afa36a7e3e68c690b1b23ba90.tar.bz2
minetest-a0566270d9fa075afa36a7e3e68c690b1b23ba90.zip
Merge remote branch 'origin/master'
Diffstat (limited to 'src/client.h')
-rw-r--r--src/client.h49
1 files changed, 41 insertions, 8 deletions
diff --git a/src/client.h b/src/client.h
index 809e98b81..d476a1d51 100644
--- a/src/client.h
+++ b/src/client.h
@@ -36,6 +36,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "server.h"
#include "particles.h"
#include "util/pointedthing.h"
+#include <algorithm>
struct MeshMakeData;
class MapBlockMesh;
@@ -142,9 +143,9 @@ public:
void * Thread();
- core::list<MediaRequest> m_file_requests;
+ std::list<MediaRequest> m_file_requests;
MutexedQueue<std::pair<std::string, std::string> > m_file_data;
- core::list<MediaRequest> m_failed;
+ std::list<MediaRequest> m_failed;
std::string m_remote_url;
IGameDef *m_gamedef;
};
@@ -156,7 +157,10 @@ enum ClientEventType
CE_PLAYER_FORCE_MOVE,
CE_DEATHSCREEN,
CE_TEXTURES_UPDATED,
- CE_SHOW_FORMSPEC
+ CE_SHOW_FORMSPEC,
+ CE_SPAWN_PARTICLE,
+ CE_ADD_PARTICLESPAWNER,
+ CE_DELETE_PARTICLESPAWNER
};
struct ClientEvent
@@ -184,6 +188,35 @@ struct ClientEvent
} show_formspec;
struct{
} textures_updated;
+ struct{
+ v3f *pos;
+ v3f *vel;
+ v3f *acc;
+ f32 expirationtime;
+ f32 size;
+ bool collisiondetection;
+ std::string *texture;
+ } spawn_particle;
+ struct{
+ u16 amount;
+ f32 spawntime;
+ v3f *minpos;
+ v3f *maxpos;
+ v3f *minvel;
+ v3f *maxvel;
+ v3f *minacc;
+ v3f *maxacc;
+ f32 minexptime;
+ f32 maxexptime;
+ f32 minsize;
+ f32 maxsize;
+ bool collisiondetection;
+ std::string *texture;
+ u32 id;
+ } add_particlespawner;
+ struct{
+ u32 id;
+ } delete_particlespawner;
};
};
@@ -282,7 +315,7 @@ public:
// Prints a line or two of info
void printDebugInfo(std::ostream &os);
- core::list<std::wstring> getConnectedPlayerNames();
+ std::list<std::wstring> getConnectedPlayerNames();
float getAnimationTime();
@@ -347,7 +380,7 @@ private:
// Insert a media file appropriately into the appropriate manager
bool loadMedia(const std::string &data, const std::string &filename);
- void request_media(const core::list<MediaRequest> &file_requests);
+ void request_media(const std::list<MediaRequest> &file_requests);
// Virtual methods from con::PeerHandler
void peerAdded(con::Peer *peer);
@@ -377,7 +410,7 @@ private:
MtEventManager *m_event;
MeshUpdateThread m_mesh_update_thread;
- core::list<MediaFetchThread*> m_media_fetch_threads;
+ std::list<MediaFetchThread*> m_media_fetch_threads;
ClientEnvironment m_env;
con::Connection m_con;
IrrlichtDevice *m_device;
@@ -387,7 +420,7 @@ private:
bool m_inventory_updated;
Inventory *m_inventory_from_server;
float m_inventory_from_server_age;
- core::map<v3s16, bool> m_active_blocks;
+ std::set<v3s16> m_active_blocks;
PacketCounter m_packetcounter;
// Block mesh animation parameters
float m_animation_time;
@@ -405,7 +438,7 @@ private:
Queue<ClientEvent> m_client_event_queue;
FileCache m_media_cache;
// Mapping from media file name to SHA1 checksum
- core::map<std::string, std::string> m_media_name_sha1_map;
+ std::map<std::string, std::string> m_media_name_sha1_map;
bool m_media_receive_started;
u32 m_media_count;
u32 m_media_received_count;