Some strange shit happens

This commit is contained in:
Vladislav Khorev committed 2026-04-22 22:38:20 +03:00
1 parent 4d9a5b0a6e
commit c655678486
10 files changed
+148 -36

No files matched your search

+7 -4
View File
@@ -9,6 +9,7 @@
#include <string>
#include <cstdint>
#include <vector>
#include <unordered_map>
namespace ZL {
@@ -30,9 +31,11 @@ public:
void loadAnimation(AnimationState state, const std::string& filename, const std::string& zipFile = "");
void loadBinaryAnimation(AnimationState state, const std::string& filename, const std::string& zipFile = "");
void setTexture(std::shared_ptr<Texture> texture) {
this->texture = texture;
}
// Assigns the given texture to a specific mesh (by name, as defined in the animation file).
void setTexture(const std::string& meshName, std::shared_ptr<Texture> texture);
// Assigns the given texture to every mesh in every loaded animation.
// Call AFTER loading animations so the mesh names are known.
void setTexture(std::shared_ptr<ZL::Texture> texture);
void update(int64_t deltaMs);
// onArrived is called once when the character reaches this target.
// From Python you can chain further commands (walk, wait, trigger others).
@@ -87,7 +90,7 @@ private:
std::map<AnimationState, BoneAnimationDataNew> animations;
VertexRenderStruct modelMutable;
std::shared_ptr<Texture> texture;
std::unordered_map<std::string, std::shared_ptr<Texture>> meshTextures;
Eigen::Vector3f walkTarget = Eigen::Vector3f(0.f, 0.f, 0.f);
Eigen::Vector3f requestedWalkTarget = Eigen::Vector3f(0.f, 0.f, 0.f);