Skip to content

Commit

Permalink
Remove modelattach from API, fixes #207
Browse files Browse the repository at this point in the history
  • Loading branch information
acerspyro committed Mar 30, 2022
1 parent e811ae7 commit 341df6f
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/engine/interface/ui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@

#include "world/entities.h"
#include "world/octaedit.h"
#include "world/octaworld.h"
#include "world/bih.h"

#include "render/hud.h"
Expand Down
1 change: 1 addition & 0 deletions src/engine/model/animmodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
#include "model.h"
#include "ragdoll.h"
#include "animmodel.h"
#include "world/octaworld.h"

//animmodel
VARP(fullbrightmodels, 0, 0, 200); //sets minimum amount of brightness for a model: 200 is 100% brightness
Expand Down
2 changes: 2 additions & 0 deletions src/engine/render/rendermodel.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
#ifndef RENDERMODEL_H_
#define RENDERMODEL_H_

#include "world/octaworld.h"

struct mapmodelinfo { string name; model *m, *collide; };

extern std::vector<mapmodelinfo> mapmodels;
Expand Down
1 change: 1 addition & 0 deletions src/engine/world/entities.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@

#include "model/model.h"
#include "model/ragdoll.h"
#include "octaworld.h"

//extentity

Expand Down
16 changes: 16 additions & 0 deletions src/engine/world/octaworld.h
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,22 @@ struct octaentities
}
};


/**
* @brief A representation of a model attachment (e.g. weapon to player).
*/
struct modelattach final
{
const char *tag, *name;
int anim, basetime;
vec *pos;
model *m;

modelattach();
modelattach(const char *tag, const char *name, int anim = -1, int basetime = 0);
modelattach(const char *tag, vec *pos);
};

enum
{
Occlude_Nothing = 0,
Expand Down

0 comments on commit 341df6f

Please sign in to comment.