mirror of
https://github.com/ZDoom/gzdoom.git
synced 2025-04-10 20:15:10 +00:00
Exported:
* GetLumpContainer * GetContainerName * GetLumpFullPath for WADS struct, useful for debugging custom-made parsers and identifying where problems may arise. All credit goes to Jay for the code.
This commit is contained in:
parent
da6730d0a7
commit
6f3032dc54
2 changed files with 24 additions and 0 deletions
|
@ -853,6 +853,27 @@ DEFINE_ACTION_FUNCTION(_Wads, GetLumpFullName)
|
|||
ACTION_RETURN_STRING(fileSystem.GetFileFullName(lump));
|
||||
}
|
||||
|
||||
DEFINE_ACTION_FUNCTION(_Wads, GetLumpContainer)
|
||||
{
|
||||
PARAM_PROLOGUE;
|
||||
PARAM_INT(lump);
|
||||
ACTION_RETURN_INT(fileSystem.GetFileContainer(lump));
|
||||
}
|
||||
|
||||
DEFINE_ACTION_FUNCTION(_Wads, GetContainerName)
|
||||
{
|
||||
PARAM_PROLOGUE;
|
||||
PARAM_INT(lump);
|
||||
ACTION_RETURN_STRING(fileSystem.GetResourceFileName(lump));
|
||||
}
|
||||
|
||||
DEFINE_ACTION_FUNCTION(_Wads, GetLumpFullPath)
|
||||
{
|
||||
PARAM_PROLOGUE;
|
||||
PARAM_INT(lump);
|
||||
ACTION_RETURN_STRING(fileSystem.GetFileFullPath(lump));
|
||||
}
|
||||
|
||||
DEFINE_ACTION_FUNCTION(_Wads, GetLumpNamespace)
|
||||
{
|
||||
PARAM_PROLOGUE;
|
||||
|
|
|
@ -898,6 +898,9 @@ struct Wads // todo: make FileSystem an alias to 'Wads'
|
|||
native static string GetLumpName(int lump);
|
||||
native static string GetLumpFullName(int lump);
|
||||
native static int GetLumpNamespace(int lump);
|
||||
native static int GetLumpContainer(int lump);
|
||||
native static string GetContainerName(int lump);
|
||||
native static string GetLumpFullPath(int lump);
|
||||
}
|
||||
|
||||
enum EmptyTokenType
|
||||
|
|
Loading…
Reference in a new issue