(10-30-2015, 05:53 AM)Abion47 Wrote: I've been getting this error as well. It's not a game-flow-breaking bug, though, so I haven't put a whole lot of effort in investigating what is causing it. My suspicion is that, since the omnitool has a part of it that is essentially a terminal, it assumes that any map that implements it is going to be making GUI calls to that terminal, and by default it searches for functions with specific signatures (like void CathTool_OnGui(const tString &in, float), for example). My guess is if you implement those functions in any way (even as empty functions), the errors should go away.
Though like I said, the errors don't really appear to hinder game performance in any way, so you could probably safely ignore them.
EDIT: Reading through some script files, I think that the signature could be _CathTool_OnGui(const tString &in, float) instead (note the leading underscore character). I'm not 100% sure, as I'm having some difficulty finding this function in SOMA level code.
How would I go about adding this to the code? I've tried just copying the "_CathTool_OnGui(const tString &in, float)" and "CathTool_OnGui(const tString &in, float)" into the code and I still receive errors. I no longer receive the "CathTool_UseOnPanel" error, but I now receive errors that say:
So right now in my code, I just have this pasted above everything
void _CathTool_OnGui(const tString &in, float)
//-------------------------------------------------------
bool mbFinalDoorOpened = false;
//---
and I get the error that says:
FATAL ERROR: Could not load script file 'maps/test_01.hps'!
test_01.hps (164, 3): ERR: Expected method or property
test_01.hps (230, 1): ERR: Unexpected token '}'
If I get rid of the 'void; I get the same error. If I get rid of the first underscore I still get the same error. If I move the code down underneath everything, so its like this:
bool omnitool_OnUse(const tString &in asTool, const tString &in asEntity)
{
if (asEntity == "omnipanel_finaldoor")
{
cLux_AddDebugMessage("Use omnitool");
CathTool_UseOnPanel("omnitool","omnipanel_finaldoor");
mbFinalDoorOpened = true;
}
return false;
}
CathTool_OnGui(const tString &in, float)
It tells me that I need a '{' at the very end of the code, which is odd itself seeing that the end of the code is closed with '}'.
If I add that line of code to the "OnUse" code, so it looks like this:
bool omnitool_OnUse(const tString &in asTool, const tString &in asEntity)
{
if (asEntity == "omnipanel_finaldoor")
{
cLux_AddDebugMessage("Use omnitool");
CathTool_UseOnPanel("omnitool","omnipanel_finaldoor");
void _CathTool_OnGui(const tString &in, float)
mbFinalDoorOpened = true;
}
return false;
}
I get the error that says:
FATAL ERROR: Could not load script file 'maps/test_01.hps'!
test_01.hps (192, 26): ERR: Expected expression value
I figured that means I have to change the "float" value to a number, but when I do that, I still get the same error.
Sorry I'm so confused. @_@