mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2025-05-30 21:51:33 +00:00
Everything done, now to test
This commit is contained in:
parent
c8a3a2c6de
commit
b98470331d
@ -7,6 +7,7 @@
|
||||
#include <cstdint>
|
||||
#include <set>
|
||||
#include <string>
|
||||
#include "dTypeDefs.h"
|
||||
#include "BitStream.h"
|
||||
#include "BitStreamUtils.h"
|
||||
#include "MessageType/Client.h"
|
||||
@ -38,29 +39,6 @@ constexpr uint32_t lowFrameDelta = FRAMES_TO_MS(lowFramerate);
|
||||
#define SEND_PACKET Game::server->Send(bitStream, sysAddr, false);
|
||||
#define SEND_PACKET_BROADCAST Game::server->Send(bitStream, UNASSIGNED_SYSTEM_ADDRESS, true);
|
||||
|
||||
//=========== TYPEDEFS ==========
|
||||
|
||||
using LOT = int32_t; //!< A LOT
|
||||
using LWOOBJID = int64_t; //!< An object ID (should be unsigned actually but ok)
|
||||
using TSkillID = int32_t; //!< A skill ID
|
||||
using LWOCLONEID = uint32_t; //!< Used for Clone IDs
|
||||
using LWOMAPID = uint16_t; //!< Used for Map IDs
|
||||
using LWOINSTANCEID = uint16_t; //!< Used for Instance IDs
|
||||
using PROPERTYCLONELIST = uint32_t; //!< Used for Property Clone IDs
|
||||
using StripId = uint32_t;
|
||||
|
||||
constexpr LWOOBJID LWOOBJID_EMPTY = 0; //!< An empty object ID
|
||||
constexpr LOT LOT_NULL = -1; //!< A null LOT
|
||||
constexpr int32_t LOOTTYPE_NONE = 0; //!< No loot type available
|
||||
constexpr float SECONDARY_PRIORITY = 1.0f; //!< Secondary Priority
|
||||
constexpr uint32_t INVENTORY_MAX = 9999999; //!< The Maximum Inventory Size
|
||||
constexpr LWOCLONEID LWOCLONEID_INVALID = -1; //!< Invalid LWOCLONEID
|
||||
constexpr LWOINSTANCEID LWOINSTANCEID_INVALID = -1; //!< Invalid LWOINSTANCEID
|
||||
constexpr LWOMAPID LWOMAPID_INVALID = -1; //!< Invalid LWOMAPID
|
||||
constexpr uint64_t LWOZONEID_INVALID = 0; //!< Invalid LWOZONEID
|
||||
|
||||
constexpr float PI = 3.14159f;
|
||||
|
||||
//============ STRUCTS ==============
|
||||
|
||||
struct LWOSCENEID {
|
||||
|
29
dCommon/dTypeDefs.h
Normal file
29
dCommon/dTypeDefs.h
Normal file
@ -0,0 +1,29 @@
|
||||
#pragma once
|
||||
|
||||
#ifndef __DTYPEDEFS__H__
|
||||
#define __DTYPEDEFS__H__
|
||||
|
||||
#include <cstdint>
|
||||
|
||||
using LOT = int32_t; //!< A LOT
|
||||
using LWOOBJID = int64_t; //!< An object ID (should be unsigned actually but ok)
|
||||
using TSkillID = int32_t; //!< A skill ID
|
||||
using LWOCLONEID = uint32_t; //!< Used for Clone IDs
|
||||
using LWOMAPID = uint16_t; //!< Used for Map IDs
|
||||
using LWOINSTANCEID = uint16_t; //!< Used for Instance IDs
|
||||
using PROPERTYCLONELIST = uint32_t; //!< Used for Property Clone IDs
|
||||
using StripId = uint32_t;
|
||||
|
||||
constexpr LWOOBJID LWOOBJID_EMPTY = 0; //!< An empty object ID
|
||||
constexpr LOT LOT_NULL = -1; //!< A null LOT
|
||||
constexpr int32_t LOOTTYPE_NONE = 0; //!< No loot type available
|
||||
constexpr float SECONDARY_PRIORITY = 1.0f; //!< Secondary Priority
|
||||
constexpr uint32_t INVENTORY_MAX = 9999999; //!< The Maximum Inventory Size
|
||||
constexpr LWOCLONEID LWOCLONEID_INVALID = -1; //!< Invalid LWOCLONEID
|
||||
constexpr LWOINSTANCEID LWOINSTANCEID_INVALID = -1; //!< Invalid LWOINSTANCEID
|
||||
constexpr LWOMAPID LWOMAPID_INVALID = -1; //!< Invalid LWOMAPID
|
||||
constexpr uint64_t LWOZONEID_INVALID = 0; //!< Invalid LWOZONEID
|
||||
|
||||
constexpr float PI = 3.14159f;
|
||||
|
||||
#endif // __DTYPEDEFS__H__
|
@ -29,4 +29,5 @@ target_include_directories(dNet PRIVATE
|
||||
"${PROJECT_SOURCE_DIR}/dGame/dInventory" # via PossessableComponent.h
|
||||
"${PROJECT_SOURCE_DIR}/dGame/dUtilities" # via Item.h
|
||||
"${PROJECT_SOURCE_DIR}/dScripts" # transitive through components
|
||||
"${PROJECT_SOURCE_DIR}/dChatFilter" # for chat message handling
|
||||
)
|
||||
|
@ -8,6 +8,7 @@
|
||||
#include "User.h"
|
||||
#include "Character.h"
|
||||
#include "dChatFilter.h"
|
||||
#include "ChatPackets.h"
|
||||
|
||||
namespace WorldPackets {
|
||||
|
||||
@ -154,7 +155,7 @@ namespace WorldPackets {
|
||||
|
||||
void PositionUpdate::Handle() {
|
||||
Entity* entity = Game::entityManager->GetEntity(objectID);
|
||||
if (entity) entity->ProcessPositionUpdate(positionUpdate);
|
||||
if (entity) entity->ProcessPositionUpdate(*this);
|
||||
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user