(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
This commit is contained in:
@@ -9,11 +9,13 @@
|
||||
#include "network_client.h"
|
||||
#include "../command.h"
|
||||
#include "../callback_table.h"
|
||||
#include "../helpers.hpp"
|
||||
|
||||
// Add a command to the local command queue
|
||||
void NetworkAddCommandQueue(NetworkClientState *cs, CommandPacket *cp)
|
||||
{
|
||||
CommandPacket* new_cp = malloc(sizeof(*new_cp));
|
||||
CommandPacket* new_cp;
|
||||
MallocT(&new_cp, 1);
|
||||
|
||||
*new_cp = *cp;
|
||||
|
||||
@@ -29,7 +31,8 @@ void NetworkAddCommandQueue(NetworkClientState *cs, CommandPacket *cp)
|
||||
// Prepare a DoCommand to be send over the network
|
||||
void NetworkSend_Command(TileIndex tile, uint32 p1, uint32 p2, uint32 cmd, CommandCallback *callback)
|
||||
{
|
||||
CommandPacket *c = malloc(sizeof(CommandPacket));
|
||||
CommandPacket *c;
|
||||
MallocT(&c, 1);
|
||||
byte temp_callback;
|
||||
|
||||
c->player = _local_player;
|
||||
|
Reference in New Issue
Block a user