mirror of
https://github.com/ZDoom/qzdoom.git
synced 2025-01-18 23:21:41 +00:00
Merge branch 'master' of https://github.com/rheit/zdoom
This commit is contained in:
commit
455d8d9730
3 changed files with 5 additions and 11 deletions
|
@ -339,7 +339,7 @@ struct level_info_t
|
||||||
TArray<FSpecialAction> specialactions;
|
TArray<FSpecialAction> specialactions;
|
||||||
|
|
||||||
TArray<FSoundID> PrecacheSounds;
|
TArray<FSoundID> PrecacheSounds;
|
||||||
TArray<FTextureID> PrecacheTextures;
|
TArray<FString> PrecacheTextures;
|
||||||
|
|
||||||
level_info_t()
|
level_info_t()
|
||||||
{
|
{
|
||||||
|
|
|
@ -1077,15 +1077,8 @@ DEFINE_MAP_OPTION(PrecacheTextures, true)
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
parse.sc.MustGetString();
|
parse.sc.MustGetString();
|
||||||
FTextureID tex = TexMan.CheckForTexture(parse.sc.String, FTexture::TEX_Wall, FTextureManager::TEXMAN_Overridable|FTextureManager::TEXMAN_TryAny|FTextureManager::TEXMAN_ReturnFirst);
|
//the texture manager is not initialized here so all we can do is store the texture's name.
|
||||||
if (!tex.isValid())
|
info->PrecacheTextures.Push(parse.sc.String);
|
||||||
{
|
|
||||||
parse.sc.ScriptMessage("Unknown texture \"%s\"", parse.sc.String);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
info->PrecacheTextures.Push(tex);
|
|
||||||
}
|
|
||||||
} while (parse.sc.CheckString(","));
|
} while (parse.sc.CheckString(","));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1248,7 +1248,8 @@ void FTextureManager::PrecacheLevel (void)
|
||||||
|
|
||||||
for (unsigned i = 0; i < level.info->PrecacheTextures.Size(); i++)
|
for (unsigned i = 0; i < level.info->PrecacheTextures.Size(); i++)
|
||||||
{
|
{
|
||||||
hitlist[level.info->PrecacheTextures[i].GetIndex()] |= FTextureManager::HIT_Wall;
|
FTextureID tex = TexMan.CheckForTexture(level.info->PrecacheTextures[i], FTexture::TEX_Wall, FTextureManager::TEXMAN_Overridable|FTextureManager::TEXMAN_TryAny|FTextureManager::TEXMAN_ReturnFirst);
|
||||||
|
if (tex.Exists()) hitlist[tex.GetIndex()] |= FTextureManager::HIT_Wall;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (int i = cnt - 1; i >= 0; i--)
|
for (int i = cnt - 1; i >= 0; i--)
|
||||||
|
|
Loading…
Reference in a new issue