Game Development Community

MessageBoxYesNoOld in wrong place

by Rex Hiebert · in Torque 3D Professional · 07/09/2009 (2:27 pm) · 1 replies

Using Beta 3 I created a new project using the "Full" template.
The MessageBoxYesNoOld function is defined in "/tools/gui/messageBoxes/messageBox.ed.cs" which works as expected when working in on a dev pc. But when you "Package Project" the tools get stripped (as they should) but also take the dialog functions with them. Because of this, if you run a packaged project on a client that doesn't have access to any other Torque scripts, you do not get the message boxes for "Quit Game? Yes/No", etc. If you bring up the console you see an error "Unable to find function MessageBoxYesNoOld".

I would think that these functions and gui definitions should be moved to the "unifiedShell" section. Here's what I did to resolve the issue:

Move the folder "/tools/gui/messageBoxes" (and all the files in "messageBoxes") to "/core/unifiedShell"

remove the line:
exec("./messageBoxes/messageBox.ed.cs");
from "/tools/gui/guiDialogs.ed.cs"

add the line:
exec("./messageBoxes/messageBox.ed.cs");
to "/core/unifiedShell/main.cs"

#1
07/09/2009 (3:34 pm)
Yes, I've lamented this very thing before... along with others. In fact there is also some "core" functionality that I feel should be game specific -- but hey that's what packages are for too.