载入中...
搜索中...
未找到
Destruction.h
浏览该文件的文档.
1#pragma once
2#include "common/Export.h"
3
4#include "common/Module.h"
5#include "common/Result.h"
9
10#include <memory>
11#include <string>
12
13namespace eve::physics {
14
15class World3D;
16
23public:
25
30 [[nodiscard("check destruction schema registration")]] eve::Result<void> registerGeometryCollectionSchema();
31
33 [[nodiscard("check geometry-collection decode")]]
34 eve::Result<GeometryCollectionAsset> assetFromJson(const std::string& json);
35
37 [[nodiscard("check welded-boxes fixture")]]
38 eve::Result<GeometryCollectionAsset> makeWeldedBoxesFixture(float strainThreshold = 1.f);
39
41 [[nodiscard("check cluster-pillar fixture")]]
42 eve::Result<GeometryCollectionAsset> makeClusterPillarFixture(float interClusterStrain = 0.8f);
43
48 [[nodiscard("check geometry-collection create")]]
50 const GeometryCollectionAsset& asset,
51 float originX, float originY,
52 float originZ);
53
55 GeometryCollectionAsset* newWeldedBoxesFixtureScript(float strainThreshold);
57 GeometryCollectionAsset* newClusterPillarFixtureScript(float interClusterStrain);
59 GeometryCollectionAsset* assetFromJsonScript(const std::string& json);
61 GeometryCollectionInstance* createInstanceScript(World3D* world, GeometryCollectionAsset* asset, float originX,
62 float originY, float originZ);
63};
64
65} // namespace eve::physics
#define EVENGINE_API_DOMAINS
Definition Export.h:110
World3D * world
Move-only, checked operation results for the common layer.
EVENGINE_API_FOUNDATION public API.
Definition Module.h:46
Move-only operation result carrying either a value or Status.
Definition Result.h:155
Optional physics satellite for Chaos-style geometry-collection destruction.
Definition Destruction.h:22
Runtime owner of bone state, connection strain, and PhysicsLink bindings.
Box3D rigid-body world. Script coordinates are meters (Box3D native), unlike 2D World which uses pixe...
Definition World3D.h:63
Optional physics backend for vehicle mobility and body attach.
Definition Climbing.h:36
Immutable cooked/authored geometry-collection asset.