optimized codes of MaterialFileLoader.cpp

This commit is contained in:
HuYingzhuo(hugo/hyzboy) 2023-10-10 19:30:07 +08:00
parent a2669d2123
commit bee48890cb

View File

@ -77,6 +77,10 @@ namespace
if(!text||!*text||len<=0) if(!text||!*text||len<=0)
return(false); return(false);
if(hgl::stricmp(text,"Require ",8)==0)
{
}
return(true); return(true);
} }
};//struct MaterialBlockParse };//struct MaterialBlockParse
@ -159,7 +163,7 @@ namespace
code=true; code=true;
} }
else else
if(hgl::stricmp(text,"Length",6)==0) if(hgl::stricmp(text,"Length ",7)==0)
{ {
text+=7; text+=7;
while(*text==' '||*text=='\t')++text; while(*text==' '||*text=='\t')++text;
@ -167,7 +171,7 @@ namespace
hgl::stou(text,mi_bytes); hgl::stou(text,mi_bytes);
} }
else else
if(hgl::stricmp(text,"Stage",5)==0) if(hgl::stricmp(text,"Stage ",6)==0)
{ {
const char *ep=text+len; const char *ep=text+len;
const char *sp; const char *sp;