Jump to content

Error when loading Waterplane or Atmosphere


L B
 Share

Recommended Posts

I'm getting the following error in my log:

 

Loading model "c:/program files/aerora/environment/waterplane/environment_waterplane.gmf"...
Loading mesh "c:/program files/aerora/environment/waterplane/environment_waterplane.gmf"...
Loading script "c:/program files/aerora/environment/waterplane/environment_waterplane.lua"...
Creating class environment_waterplane
Warning: Failed to save body "c:/program files/aerora/environment/waterplane/environment_waterplane.phy".
Lua error: [string "c:/program files/aerora/environment/waterpl..."]:34: C:/Program Files/BlitzMax/mod/lugi.mod/core.mod/lgcore.cpp:891@lugi_index_object: Index for object is
not a valid field or method.
Lua error: [string "c:/program files/aerora/environment/waterpl..."]:34: C:/Program Files/BlitzMax/mod/lugi.mod/core.mod/lgcore.cpp:891@lugi_index_object: Index for object is
not a valid field or method.
Lua error: [string "c:/program files/aerora/environment/waterpl..."]:34: C:/Program Files/BlitzMax/mod/lugi.mod/core.mod/lgcore.cpp:891@lugi_index_object: Index for object is
not a valid field or method.
Loading model "c:/program files/aerora/environment/atmosphere/environment_atmosphere.gmf"...
Loading mesh "c:/program files/aerora/environment/atmosphere/environment_atmosphere.gmf"...
Loading script "c:/program files/aerora/environment/atmosphere/environment_atmosphere.lua"...
Creating class environment_atmosphere
Lua error: [string "c:/program files/aerora/environment/atmosph..."]:69: C:/Program Files/BlitzMax/mod/lugi.mod/core.mod/lgcore.cpp:891@lugi_index_object: Index for object is
not a valid field or method.
Lua error: [string "c:/program files/aerora/environment/atmosph..."]:69: C:/Program Files/BlitzMax/mod/lugi.mod/core.mod/lgcore.cpp:891@lugi_index_object: Index for object is
not a valid field or method.

 

Lua error: [string "c:/program files/aerora/environment/waterpl..."]:34: C:/Program Files/BlitzMax/mod/lugi.mod/core.mod/lgcore.cpp:891@lugi_index_object: Index for object is not a valid field or method.

 

Any idea at all? I'm lost at the moment.

Link to comment
Share on other sites

Its telling you exactly where the problem is... line 34 of the waterplane script and line 69 of the atmosphere script. It doesn't recognize the "fw.renderer.SetWater(1)" and "fw.renderer.BackgroundMode(1)".

 

Do you have those commands available in C# or have you changed these to some derivation so it doesn't recognize them?

Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590

LE / 3DWS / BMX / Hexagon

macklebee's channel

Link to comment
Share on other sites

no he must have or it would have never gotten to those lines in the script since it checks for fw~=nil... that was what i thought as first as well, but I couldn't get the same errors to occur when I tried it. It only happened when I changed those commands to something that wasn't in my lua glue functions...

Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590

LE / 3DWS / BMX / Hexagon

macklebee's channel

Link to comment
Share on other sites

Here's the inner header code for initializing framework:

Framework.Pointer = Core.CreateFramework();

Framework.CheckPointerDll();

Framework.StatisticMode = StatisticMode.None;

//Global.Objects["fw"] = Framework.Pointer; I had this commented out, because it didn't make any change.

IntPtr lua = Core.GetLuaState();
Core.lua_pushobject(lua, Framework.Pointer);
Core.lua_setglobal(lua, "fw");
Core.lua_pop(lua, 1);

 

Oh yeah, the global goes as follows:

	public class GlobalPointers
{
	internal GlobalPointers() { }

	public IntPtr this[string key]
	{
		get
		{
			return Core.GetGlobalObject(key);
		}
		set
		{
			Core.SetGlobalObject(key, value); //  There.
		}
	}
}

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...