Skip to content

Commit 87704fc

Browse files
authored
Refactor replacement texture to a modelinstance parameter (scp-fs2open#6154)
* Move replacement textures from ship to modelinstance * Actually set pmi * Fix texture replace in fred as well * Fix bad indent * incorporate feedback
1 parent c1af431 commit 87704fc

File tree

19 files changed

+293
-294
lines changed

19 files changed

+293
-294
lines changed

code/asteroid/asteroid.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1523,6 +1523,8 @@ void asteroid_render(object * obj, model_draw_list *scene)
15231523

15241524
render_info.set_object_number( OBJ_INDEX(obj) );
15251525
render_info.set_flags(MR_IS_ASTEROID);
1526+
if (asp->model_instance_num >= 0)
1527+
render_info.set_replacement_textures(model_get_instance(asp->model_instance_num)->texture_replace);
15261528

15271529
model_render_queue(&render_info, scene, Asteroid_info[asp->asteroid_type].model_num[asp->asteroid_subtype], &obj->orient, &obj->pos); // Replace MR_NORMAL with 0x07 for big yellow blobs
15281530
}

code/debris/debris.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1197,6 +1197,9 @@ void debris_render(object * obj, model_draw_list *scene)
11971197
// render_info.set_flags(MR_NO_LIGHTING);
11981198
}
11991199

1200+
if (db->model_instance_num >= 0)
1201+
render_info.set_replacement_textures(model_get_instance(db->model_instance_num)->texture_replace);
1202+
12001203
submodel_render_queue( &render_info, scene, pm, pmi, db->submodel_num, &obj->orient, &obj->pos );
12011204

12021205
if (tbase != NULL && (swapped!=-1) && pm) {

code/hud/hudshield.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -641,7 +641,7 @@ void HudGaugeShield::showShields(object *objp, int mode)
641641
model_render_params render_info;
642642

643643
render_info.set_flags(MR_NO_LIGHTING | MR_AUTOCENTER | MR_NO_FOGGING);
644-
render_info.set_replacement_textures(sp->ship_replacement_textures);
644+
render_info.set_replacement_textures(model_get_instance(sp->model_instance_num)->texture_replace);
645645
render_info.set_detail_level_lock(1);
646646
render_info.set_object_number(OBJ_INDEX(objp));
647647

code/hud/hudtargetbox.cpp

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -677,7 +677,7 @@ void HudGaugeTargetBox::renderTargetShip(object *target_objp)
677677
if(target_sip->model_num_hud >= 0){
678678
model_render_immediate( &render_info, target_sip->model_num_hud, &target_objp->orient, &obj_pos);
679679
} else {
680-
render_info.set_replacement_textures(target_shipp->ship_replacement_textures);
680+
render_info.set_replacement_textures(model_get_instance(target_shipp->model_instance_num)->texture_replace);
681681

682682
model_render_immediate( &render_info, target_sip->model_num, &target_objp->orient, &obj_pos);
683683
}
@@ -777,6 +777,9 @@ void HudGaugeTargetBox::renderTargetDebris(object *target_objp)
777777

778778
model_render_params render_info;
779779

780+
if (debrisp->model_instance_num >= 0)
781+
render_info.set_replacement_textures(model_get_instance(debrisp->model_instance_num)->texture_replace);
782+
780783
color thisColor = GaugeWirecolor;
781784
bool thisOverride = GaugeWirecolorOverride;
782785

@@ -863,7 +866,7 @@ void HudGaugeTargetBox::renderTargetWeapon(object *target_objp)
863866
weapon_info *target_wip = NULL;
864867
weapon *wp = NULL;
865868
object *viewer_obj, *viewed_obj;
866-
int *replacement_textures = NULL;
869+
std::shared_ptr<model_texture_replace> replacement_textures = nullptr;
867870
int target_team, is_homing, is_player_missile, missile_view, viewed_model_num, hud_target_lod, w, h;
868871
int flags=0;
869872

@@ -902,10 +905,13 @@ void HudGaugeTargetBox::renderTargetWeapon(object *target_objp)
902905
viewed_obj = wp->homing_object;
903906
missile_view = TRUE;
904907
viewed_model_num = homing_sip->model_num;
905-
replacement_textures = homing_shipp->ship_replacement_textures;
906908
hud_target_lod = homing_sip->hud_target_lod;
907909
}
908910

911+
int pmi_id = object_get_model_instance(viewed_obj);
912+
if (pmi_id >= 0)
913+
replacement_textures = model_get_instance(pmi_id)->texture_replace;
914+
909915
// take the forward orientation to be the vector from the player to the current target
910916
vm_vec_sub(&orient_vec, &viewed_obj->pos, &viewer_obj->pos);
911917
vm_vec_normalize(&orient_vec);
@@ -1068,7 +1074,6 @@ void HudGaugeTargetBox::renderTargetWeapon(object *target_objp)
10681074
model_render_immediate( &render_info, homing_sip->model_num_hud, &viewed_obj->orient, &obj_pos);
10691075
} else {
10701076
render_info.set_flags(flags | MR_NO_FOGGING);
1071-
render_info.set_replacement_textures(homing_shipp->ship_replacement_textures);
10721077

10731078
model_render_immediate( &render_info, homing_sip->model_num, &viewed_obj->orient, &obj_pos );
10741079
}
@@ -1170,6 +1175,9 @@ void HudGaugeTargetBox::renderTargetAsteroid(object *target_objp)
11701175

11711176
model_render_params render_info;
11721177

1178+
if (asteroidp->model_instance_num >= 0)
1179+
render_info.set_replacement_textures(model_get_instance(asteroidp->model_instance_num)->texture_replace);
1180+
11731181
color thisColor = GaugeWirecolor;
11741182
bool thisOverride = GaugeWirecolorOverride;
11751183

code/model/model.h

Lines changed: 27 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -140,13 +140,40 @@ struct submodel_instance
140140
}
141141
};
142142

143+
#define TM_BASE_TYPE 0 // the standard base map
144+
#define TM_GLOW_TYPE 1 // optional glow map
145+
#define TM_SPECULAR_TYPE 2 // optional specular map
146+
#define TM_NORMAL_TYPE 3 // optional normal map
147+
#define TM_HEIGHT_TYPE 4 // optional height map (for parallax mapping)
148+
#define TM_MISC_TYPE 5 // optional utility map
149+
#define TM_SPEC_GLOSS_TYPE 6 // optional reflectance map (specular and gloss)
150+
#define TM_AMBIENT_TYPE 7 // optional ambient occlusion map with ambient occlusion and cavity occlusion factors for red and green channels.
151+
#define TM_NUM_TYPES 8 //WMC - Number of texture_info objects in texture_map
152+
//Used by scripting - if you change this, do a search
153+
//to update switch() statement in lua.cpp
154+
155+
#define MAX_REPLACEMENT_TEXTURES MAX_MODEL_TEXTURES * TM_NUM_TYPES
156+
157+
// Goober5000 - since we need something < 0
158+
#define REPLACE_WITH_INVISIBLE -47
159+
160+
class model_texture_replace : public std::array<int, MAX_REPLACEMENT_TEXTURES> {
161+
public:
162+
model_texture_replace() : std::array<int, MAX_REPLACEMENT_TEXTURES>() {
163+
for (int& tex : *this)
164+
tex = -1;
165+
}
166+
};
167+
143168
// Data specific to a particular instance of a model.
144169
struct polymodel_instance
145170
{
146171
int id = -1; // global model_instance num index
147172
int model_num = -1; // global model num index, same as polymodel->id
148173
submodel_instance *submodel = nullptr; // array of submodel instances; mirrors the polymodel->submodel array
149174

175+
std::shared_ptr<model_texture_replace> texture_replace = nullptr;
176+
150177
int objnum; // id of the object using this pmi, or -1 if no object (e.g. skybox)
151178
};
152179

@@ -730,17 +757,6 @@ class texture_info
730757
int SetTexture(int n_tex);
731758
};
732759

733-
#define TM_BASE_TYPE 0 // the standard base map
734-
#define TM_GLOW_TYPE 1 // optional glow map
735-
#define TM_SPECULAR_TYPE 2 // optional specular map
736-
#define TM_NORMAL_TYPE 3 // optional normal map
737-
#define TM_HEIGHT_TYPE 4 // optional height map (for parallax mapping)
738-
#define TM_MISC_TYPE 5 // optional utility map
739-
#define TM_SPEC_GLOSS_TYPE 6 // optional reflectance map (specular and gloss)
740-
#define TM_AMBIENT_TYPE 7 // optional ambient occlusion map with ambient occlusion and cavity occlusion factors for red and green channels.
741-
#define TM_NUM_TYPES 8 //WMC - Number of texture_info objects in texture_map
742-
//Used by scripting - if you change this, do a search
743-
//to update switch() statement in lua.cpp
744760
// taylor
745761
//WMC - OOPified
746762
class texture_map
@@ -765,11 +781,6 @@ class texture_map
765781
{}
766782
};
767783

768-
#define MAX_REPLACEMENT_TEXTURES MAX_MODEL_TEXTURES * TM_NUM_TYPES
769-
770-
// Goober5000 - since we need something < 0
771-
#define REPLACE_WITH_INVISIBLE -47
772-
773784
//used to describe a polygon model
774785
// NOTE: Because WMC OOPified the textures, this must now be treated as a class, rather than a struct.
775786
// Additionally, a lot of model initialization and de-initialization is currently done in model_load or model_unload.

code/model/modelrender.cpp

Lines changed: 30 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,7 @@ model_render_params::model_render_params() :
6464
Xparent_alpha(1.0f),
6565
Forced_bitmap(-1),
6666
Insignia_bitmap(-1),
67-
Replacement_textures(NULL),
68-
Manage_replacement_textures(false),
67+
Replacement_textures(nullptr),
6968
Team_color_set(false),
7069
Clip_plane_set(false),
7170
Animated_effect(-1),
@@ -91,12 +90,6 @@ model_render_params::model_render_params() :
9190
gr_init_color(&Color, 0, 0, 0);
9291
}
9392

94-
model_render_params::~model_render_params()
95-
{
96-
if (Manage_replacement_textures)
97-
vm_free(const_cast<int*>(Replacement_textures));
98-
}
99-
10093
uint model_render_params::get_model_flags() const
10194
{
10295
return Model_flags;
@@ -157,7 +150,7 @@ int model_render_params::get_insignia_bitmap() const
157150
return Insignia_bitmap;
158151
}
159152

160-
const int* model_render_params::get_replacement_textures() const
153+
std::shared_ptr<const model_texture_replace> model_render_params::get_replacement_textures() const
161154
{
162155
return Replacement_textures;
163156
}
@@ -223,19 +216,14 @@ bool model_render_params::is_team_color_set() const
223216
return Team_color_set;
224217
}
225218

226-
void model_render_params::set_replacement_textures(const int *textures)
219+
void model_render_params::set_replacement_textures(std::shared_ptr<const model_texture_replace> textures)
227220
{
228-
Replacement_textures = textures;
221+
Replacement_textures = std::move(textures);
229222
}
230223

231224
void model_render_params::set_replacement_textures(int modelnum, const SCP_vector<texture_replace>& replacement_textures)
232225
{
233-
auto textures = (int*)vm_malloc(MAX_REPLACEMENT_TEXTURES * sizeof(int));
234-
235-
for (int i = 0; i < MAX_REPLACEMENT_TEXTURES; i++)
236-
textures[i] = -1;
237-
238-
Manage_replacement_textures = true;
226+
auto textures = make_shared<model_texture_replace>();
239227

240228
polymodel* pm = model_get(modelnum);
241229

@@ -247,11 +235,11 @@ void model_render_params::set_replacement_textures(int modelnum, const SCP_vecto
247235

248236
int tnum = tmap->FindTexture(tr.old_texture);
249237
if (tnum > -1)
250-
textures[i * TM_NUM_TYPES + tnum] = bm_load(tr.new_texture);
238+
(*textures)[i * TM_NUM_TYPES + tnum] = bm_load(tr.new_texture);
251239
}
252240
}
253241

254-
Replacement_textures = textures;
242+
Replacement_textures = std::move(textures);
255243
}
256244

257245
void model_render_params::set_insignia_bitmap(int bitmap)
@@ -1054,7 +1042,7 @@ void model_render_buffers(model_draw_list* scene, model_material *rendering_mate
10541042

10551043
int texture_maps[TM_NUM_TYPES] = { -1 };
10561044
size_t buffer_size = buffer->tex_buf.size();
1057-
const int *replacement_textures = interp->get_replacement_textures();
1045+
const auto& replacement_textures = interp->get_replacement_textures();
10581046

10591047
for ( size_t i = 0; i < buffer_size; i++ ) {
10601048
int tmap_num = buffer->tex_buf[i].texture;
@@ -1081,12 +1069,12 @@ void model_render_buffers(model_draw_list* scene, model_material *rendering_mate
10811069

10821070
} else if ( !no_texturing ) {
10831071
// pick the texture, animating it if necessary
1084-
if ( (replacement_textures != NULL) && (replacement_textures[rt_begin_index + TM_BASE_TYPE] == REPLACE_WITH_INVISIBLE) ) {
1072+
if ( (replacement_textures != nullptr) && ((*replacement_textures)[rt_begin_index + TM_BASE_TYPE] == REPLACE_WITH_INVISIBLE) ) {
10851073
// invisible textures aren't rendered, but we still have to skip assigning the underlying model texture
10861074
texture_maps[TM_BASE_TYPE] = -1;
1087-
} else if ( (replacement_textures != NULL) && (replacement_textures[rt_begin_index + TM_BASE_TYPE] >= 0) ) {
1075+
} else if ( (replacement_textures != nullptr) && ((*replacement_textures)[rt_begin_index + TM_BASE_TYPE] >= 0) ) {
10881076
// an underlying texture is replaced with a real new texture
1089-
tex_replace[TM_BASE_TYPE] = texture_info(replacement_textures[rt_begin_index + TM_BASE_TYPE]);
1077+
tex_replace[TM_BASE_TYPE] = texture_info((*replacement_textures)[rt_begin_index + TM_BASE_TYPE]);
10901078
texture_maps[TM_BASE_TYPE] = model_interp_get_texture(&tex_replace[TM_BASE_TYPE], elapsed_time);
10911079
} else {
10921080
// we just use the underlying texture
@@ -1101,8 +1089,8 @@ void model_render_buffers(model_draw_list* scene, model_material *rendering_mate
11011089
if ( !(model_flags & MR_NO_GLOWMAPS) ) {
11021090
auto tglow = &tmap->textures[TM_GLOW_TYPE];
11031091

1104-
if ( (replacement_textures != NULL) && (replacement_textures[rt_begin_index + TM_GLOW_TYPE] >= 0) ) {
1105-
tex_replace[TM_GLOW_TYPE] = texture_info(replacement_textures[rt_begin_index + TM_GLOW_TYPE]);
1092+
if ( (replacement_textures != nullptr) && ((*replacement_textures)[rt_begin_index + TM_GLOW_TYPE] >= 0) ) {
1093+
tex_replace[TM_GLOW_TYPE] = texture_info((*replacement_textures)[rt_begin_index + TM_GLOW_TYPE]);
11061094
texture_maps[TM_GLOW_TYPE] = model_interp_get_texture(&tex_replace[TM_GLOW_TYPE], elapsed_time);
11071095
} else if (tglow->GetTexture() >= 0) {
11081096
// shockwaves are special, their current frame has to come out of the shockwave code to get the timing correct
@@ -1115,17 +1103,17 @@ void model_render_buffers(model_draw_list* scene, model_material *rendering_mate
11151103
}
11161104

11171105
if (!(debug_flags & MR_DEBUG_NO_SPEC)) {
1118-
if (replacement_textures != NULL && replacement_textures[rt_begin_index + TM_SPECULAR_TYPE] >= 0) {
1119-
tex_replace[TM_SPECULAR_TYPE] = texture_info(replacement_textures[rt_begin_index + TM_SPECULAR_TYPE]);
1106+
if (replacement_textures != nullptr && (*replacement_textures)[rt_begin_index + TM_SPECULAR_TYPE] >= 0) {
1107+
tex_replace[TM_SPECULAR_TYPE] = texture_info((*replacement_textures)[rt_begin_index + TM_SPECULAR_TYPE]);
11201108
texture_maps[TM_SPECULAR_TYPE] = model_interp_get_texture(&tex_replace[TM_SPECULAR_TYPE], elapsed_time);
11211109
}
11221110
else {
11231111
texture_maps[TM_SPECULAR_TYPE] = model_interp_get_texture(&tmap->textures[TM_SPECULAR_TYPE], elapsed_time);
11241112
}
11251113
}
11261114

1127-
if ( replacement_textures != NULL && replacement_textures[rt_begin_index + TM_SPEC_GLOSS_TYPE] >= 0 ) {
1128-
tex_replace[TM_SPEC_GLOSS_TYPE] = texture_info(replacement_textures[rt_begin_index + TM_SPEC_GLOSS_TYPE]);
1115+
if ( replacement_textures != nullptr && (*replacement_textures)[rt_begin_index + TM_SPEC_GLOSS_TYPE] >= 0 ) {
1116+
tex_replace[TM_SPEC_GLOSS_TYPE] = texture_info((*replacement_textures)[rt_begin_index + TM_SPEC_GLOSS_TYPE]);
11291117
texture_maps[TM_SPEC_GLOSS_TYPE] = model_interp_get_texture(&tex_replace[TM_SPEC_GLOSS_TYPE], elapsed_time);
11301118
} else {
11311119
texture_maps[TM_SPEC_GLOSS_TYPE] = model_interp_get_texture(&tmap->textures[TM_SPEC_GLOSS_TYPE], elapsed_time);
@@ -1138,24 +1126,25 @@ void model_render_buffers(model_draw_list* scene, model_material *rendering_mate
11381126
auto ambient_map = &tmap->textures[TM_AMBIENT_TYPE];
11391127
auto misc_map = &tmap->textures[TM_MISC_TYPE];
11401128

1141-
if (replacement_textures != NULL) {
1142-
if (replacement_textures[rt_begin_index + TM_NORMAL_TYPE] >= 0) {
1143-
tex_replace[TM_NORMAL_TYPE] = texture_info(replacement_textures[rt_begin_index + TM_NORMAL_TYPE]);
1129+
if (replacement_textures != nullptr) {
1130+
const auto& replacement_textures_deref = *replacement_textures;
1131+
if (replacement_textures_deref[rt_begin_index + TM_NORMAL_TYPE] >= 0) {
1132+
tex_replace[TM_NORMAL_TYPE] = texture_info(replacement_textures_deref[rt_begin_index + TM_NORMAL_TYPE]);
11441133
norm_map = &tex_replace[TM_NORMAL_TYPE];
11451134
}
11461135

1147-
if (replacement_textures[rt_begin_index + TM_HEIGHT_TYPE] >= 0) {
1148-
tex_replace[TM_HEIGHT_TYPE] = texture_info(replacement_textures[rt_begin_index + TM_HEIGHT_TYPE]);
1136+
if (replacement_textures_deref[rt_begin_index + TM_HEIGHT_TYPE] >= 0) {
1137+
tex_replace[TM_HEIGHT_TYPE] = texture_info(replacement_textures_deref[rt_begin_index + TM_HEIGHT_TYPE]);
11491138
height_map = &tex_replace[TM_HEIGHT_TYPE];
11501139
}
11511140

1152-
if (replacement_textures[rt_begin_index + TM_AMBIENT_TYPE] >= 0) {
1153-
tex_replace[TM_AMBIENT_TYPE] = texture_info(replacement_textures[rt_begin_index + TM_AMBIENT_TYPE]);
1141+
if (replacement_textures_deref[rt_begin_index + TM_AMBIENT_TYPE] >= 0) {
1142+
tex_replace[TM_AMBIENT_TYPE] = texture_info(replacement_textures_deref[rt_begin_index + TM_AMBIENT_TYPE]);
11541143
ambient_map = &tex_replace[TM_AMBIENT_TYPE];
11551144
}
11561145

1157-
if (replacement_textures[rt_begin_index + TM_MISC_TYPE] >= 0) {
1158-
tex_replace[TM_MISC_TYPE] = texture_info(replacement_textures[rt_begin_index + TM_MISC_TYPE]);
1146+
if (replacement_textures_deref[rt_begin_index + TM_MISC_TYPE] >= 0) {
1147+
tex_replace[TM_MISC_TYPE] = texture_info(replacement_textures_deref[rt_begin_index + TM_MISC_TYPE]);
11591148
misc_map = &tex_replace[TM_MISC_TYPE];
11601149
}
11611150
}
@@ -1174,8 +1163,8 @@ void model_render_buffers(model_draw_list* scene, model_material *rendering_mate
11741163

11751164
//Check for invisible or transparent textures so they don't show up in the shadow maps - Valathil
11761165
if ( Rendering_to_shadow_map ) {
1177-
if ( (replacement_textures != NULL) && (replacement_textures[rt_begin_index + TM_BASE_TYPE] >= 0) ) {
1178-
tex_replace[TM_BASE_TYPE] = texture_info(replacement_textures[rt_begin_index + TM_BASE_TYPE]);
1166+
if ( (replacement_textures != nullptr) && ((*replacement_textures)[rt_begin_index + TM_BASE_TYPE] >= 0) ) {
1167+
tex_replace[TM_BASE_TYPE] = texture_info((*replacement_textures)[rt_begin_index + TM_BASE_TYPE]);
11791168
texture_maps[TM_BASE_TYPE] = model_interp_get_texture(&tex_replace[TM_BASE_TYPE], elapsed_time);
11801169
} else {
11811170
texture_maps[TM_BASE_TYPE] = model_interp_get_texture(&tmap->textures[TM_BASE_TYPE], elapsed_time);
@@ -3113,6 +3102,7 @@ bool render_tech_model(tech_render_type model_type, int x1, int y1, int x2, int
31133102

31143103
// Make sure model is loaded
31153104
model_num = model_load(sip->pof_file, sip->n_subsystems, &sip->subsystems[0], 0);
3105+
render_info.set_replacement_textures(model_num, sip->replacement_textures);
31163106

31173107
break;
31183108

code/model/modelrender.h

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -83,10 +83,7 @@ class model_render_params
8383

8484
int Insignia_bitmap;
8585

86-
const int *Replacement_textures;
87-
bool Manage_replacement_textures; // This is set when we are rendering a model without an associated ship object;
88-
// in that case, model_render_params is responsible for allocating and destroying
89-
// the Replacement_textures array (this is handled elsewhere otherwise)
86+
std::shared_ptr<const model_texture_replace> Replacement_textures;
9087

9188
bool Team_color_set;
9289
team_color Current_team_color;
@@ -109,7 +106,6 @@ class model_render_params
109106
model_render_params& operator=(const model_render_params&) = delete;
110107
public:
111108
model_render_params();
112-
~model_render_params();
113109

114110
void set_flags(uint flags);
115111
void set_debug_flags(uint flags);
@@ -122,7 +118,7 @@ class model_render_params
122118
void set_alpha(float alpha);
123119
void set_forced_bitmap(int bitmap);
124120
void set_insignia_bitmap(int bitmap);
125-
void set_replacement_textures(const int *textures);
121+
void set_replacement_textures(std::shared_ptr<const model_texture_replace> textures);
126122
void set_replacement_textures(int modelnum, const SCP_vector<texture_replace>& replacement_textures);
127123
void set_team_color(const team_color &clr);
128124
void set_team_color(const SCP_string &team, const SCP_string &secondaryteam, fix timestamp, int fadetime);
@@ -149,7 +145,7 @@ class model_render_params
149145
float get_alpha() const;
150146
int get_forced_bitmap() const;
151147
int get_insignia_bitmap() const;
152-
const int* get_replacement_textures() const;
148+
std::shared_ptr<const model_texture_replace> get_replacement_textures() const;
153149
const team_color& get_team_color() const;
154150
const vec3d& get_clip_plane_pos() const;
155151
const vec3d& get_clip_plane_normal() const;

code/scripting/api/objs/cockpit_display.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -512,7 +512,7 @@ bool cockpit_displays_h::isValid() const {
512512
return false;
513513
}
514514

515-
if ( Player_cockpit_textures == NULL ) {
515+
if ( Player_cockpit_textures == nullptr ) {
516516
return false;
517517
}
518518

0 commit comments

Comments
 (0)