mirror of
https://github.com/open-goal/jak-project
synced 2026-06-28 11:11:00 -04:00
eb703ee96e
Motivated by - https://github.com/open-goal/opengoal-vscode/pull/358 This addresses the following: - Fixes #2939 spam edge-case - Stop picking a different nREPL port based on the game mode by default, this causes friction for tools in the average usecase (having a REPL open for a single game, and wanting to connect to it). `goalc` spins up fine even if the port is already bound to. - For people that need/want this behaviour, adding per-game configuration to the `repl-config.json` is on my todo list. - Allows `goalc` to permit redefining symbols, including functions. This is defaulted to off via the `repl-config.json` but it allows you to for example, change the definition of a function without having to restart and rebuild the entire game.  - Updates the welcome message to include a bunch of useful metadata up-front. Cleaned up all the startup logs that appear when starting goalc, many of whom's information is now included in the welcome message. - Before:  - After: 
41 lines
1.4 KiB
C++
41 lines
1.4 KiB
C++
#pragma once
|
|
|
|
#include "common/util/gltf_util.h"
|
|
|
|
#include "goalc/build_actor/jak1/build_actor.h"
|
|
|
|
struct MercExtractData {
|
|
gltf_util::TexturePool tex_pool;
|
|
std::vector<u32> new_indices;
|
|
std::vector<tfrag3::PreloadedVertex> new_vertices;
|
|
std::vector<math::Vector<u8, 4>> new_colors;
|
|
std::vector<math::Vector3f> normals;
|
|
|
|
tfrag3::MercModel new_model;
|
|
};
|
|
|
|
// Data produced by loading a replacement model
|
|
struct MercSwapData {
|
|
std::vector<u32> new_indices;
|
|
std::vector<tfrag3::MercVertex> new_vertices;
|
|
std::vector<tfrag3::Texture> new_textures;
|
|
tfrag3::MercModel new_model;
|
|
};
|
|
|
|
void extract(const std::string& name,
|
|
MercExtractData& out,
|
|
const tinygltf::Model& model,
|
|
const std::vector<gltf_util::NodeWithTransform>& all_nodes,
|
|
u32 index_offset,
|
|
u32 vertex_offset,
|
|
u32 tex_offset);
|
|
void merc_convert(MercSwapData& out, const MercExtractData& in);
|
|
MercSwapData load_merc_model(u32 current_idx_count,
|
|
u32 current_vtx_count,
|
|
u32 current_tex_count,
|
|
const std::string& path,
|
|
const std::string& name);
|
|
std::vector<jak1::CollideMesh> gen_collide_mesh_from_model(
|
|
const tinygltf::Model& model,
|
|
const std::vector<gltf_util::NodeWithTransform>& all_nodes,
|
|
int joint_idx); |