Well, figured this looks nicer and is pretty neat.
Simba Code:
function isIndexing(id: uInt32;option: string): boolean;
begin
if execRegExpr('^(m(odels)?)$',option) then
begin
if (ogl.getModels(id).indexes()) then exit(true);
end else if execRegExpr('^(t(extures)?)$',option) then
begin
if (ogl.getTextures(id).indexes()) then exit(true);
end;
end;
example usage: (123 is the model/texture ID depending on the string)
Simba Code:
if isIndexing(123, 'm') then
Simba Code:
if isIndexing(123, 'models') then
Simba Code:
if isIndexing(123, 't') then
Simba Code:
if isIndexing(123, 'textures') then