Batch #8258 by Toshiro: 0 byte-identical, 1 confirmed by peer review. - fn_17650 WorldRayQuery::WorldRayQuery: logic confirmed by peer review Peer-reviewed-by: eAthena, System4z Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes).
28 lines
792 B
C++
28 lines
792 B
C++
#ifndef RAGNAROK_SOURCE_CONTENTS_WORLD_WORLDRAYQUERY_H
|
|
#define RAGNAROK_SOURCE_CONTENTS_WORLD_WORLDRAYQUERY_H
|
|
|
|
#include <cstddef>
|
|
#include <list>
|
|
|
|
struct WorldSpatialTree;
|
|
|
|
struct WorldRayQuery {
|
|
/* 0000 */ std::list<WorldSpatialTree*> nodes;
|
|
/* 0008 */ float origin[3];
|
|
/* 0014 */ float direction[3];
|
|
/* 0020 */ float limit;
|
|
|
|
WorldRayQuery();
|
|
bool Intersects(const float* bounds) const;
|
|
void Collect(const float* ray, WorldSpatialTree* root);
|
|
void CollectNode(WorldSpatialTree* node, int depth);
|
|
};
|
|
|
|
#if defined(_WIN32) && !defined(_WIN64)
|
|
static_assert(sizeof(WorldRayQuery) == 36);
|
|
static_assert(offsetof(WorldRayQuery, origin) == 0x0008);
|
|
static_assert(offsetof(WorldRayQuery, direction) == 0x0014);
|
|
static_assert(offsetof(WorldRayQuery, limit) == 0x0020);
|
|
#endif
|
|
|
|
#endif
|