The following warnings occurred:
Warning [2] Undefined array key "lockoutexpiry" - Line: 94 - File: global.php PHP 8.4.12 (Linux)
File Line Function
/global.php 94 errorHandler->error
/printthread.php 16 require_once
Warning [2] Undefined array key "lockoutexpiry" - Line: 573 - File: global.php PHP 8.4.12 (Linux)
File Line Function
/global.php 573 errorHandler->error
/printthread.php 16 require_once
Warning [2] Undefined variable $can_access_moderationqueue - Line: 752 - File: global.php PHP 8.4.12 (Linux)
File Line Function
/global.php 752 errorHandler->error
/printthread.php 16 require_once
Warning [2] Undefined array key "avatartype" - Line: 892 - File: global.php PHP 8.4.12 (Linux)
File Line Function
/global.php 892 errorHandler->error
/printthread.php 16 require_once
Warning [2] Undefined array key "avatartype" - Line: 892 - File: global.php PHP 8.4.12 (Linux)
File Line Function
/global.php 892 errorHandler->error
/printthread.php 16 require_once
Warning [2] Undefined variable $awaitingusers - Line: 34 - File: global.php(959) : eval()'d code PHP 8.4.12 (Linux)
File Line Function
/global.php(959) : eval()'d code 34 errorHandler->error
/global.php 959 eval
/printthread.php 16 require_once
Warning [2] Undefined array key "style" - Line: 1024 - File: global.php PHP 8.4.12 (Linux)
File Line Function
/global.php 1024 errorHandler->error
/printthread.php 16 require_once
Warning [2] Undefined property: MyLanguage::$lang_select_default - Line: 5327 - File: inc/functions.php PHP 8.4.12 (Linux)
File Line Function
/inc/functions.php 5327 errorHandler->error
/global.php 1024 build_theme_select
/printthread.php 16 require_once
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 165 errorHandler->error
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 165 errorHandler->error
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 165 errorHandler->error
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 165 errorHandler->error
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 165 errorHandler->error
Warning [2] Undefined array key 1 - Line: 866 - File: inc/class_parser.php PHP 8.4.12 (Linux)
File Line Function
/inc/class_parser.php 866 errorHandler->error
/inc/class_parser.php 938 postParser->mycode_parse_post_quotes
[PHP] postParser->mycode_parse_post_quotes_callback1
/inc/class_parser.php 816 preg_replace_callback
/inc/class_parser.php 451 postParser->mycode_parse_quotes
/inc/class_parser.php 201 postParser->parse_mycode
/printthread.php 179 postParser->parse_message
Warning [2] Undefined array key 1 - Line: 885 - File: inc/class_parser.php PHP 8.4.12 (Linux)
File Line Function
/inc/class_parser.php 885 errorHandler->error
/inc/class_parser.php 938 postParser->mycode_parse_post_quotes
[PHP] postParser->mycode_parse_post_quotes_callback1
/inc/class_parser.php 816 preg_replace_callback
/inc/class_parser.php 451 postParser->mycode_parse_quotes
/inc/class_parser.php 201 postParser->parse_mycode
/printthread.php 179 postParser->parse_message
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 165 errorHandler->error
Warning [2] Undefined array key 1 - Line: 866 - File: inc/class_parser.php PHP 8.4.12 (Linux)
File Line Function
/inc/class_parser.php 866 errorHandler->error
/inc/class_parser.php 938 postParser->mycode_parse_post_quotes
[PHP] postParser->mycode_parse_post_quotes_callback1
/inc/class_parser.php 816 preg_replace_callback
/inc/class_parser.php 451 postParser->mycode_parse_quotes
/inc/class_parser.php 201 postParser->parse_mycode
/printthread.php 179 postParser->parse_message
Warning [2] Undefined array key 1 - Line: 885 - File: inc/class_parser.php PHP 8.4.12 (Linux)
File Line Function
/inc/class_parser.php 885 errorHandler->error
/inc/class_parser.php 938 postParser->mycode_parse_post_quotes
[PHP] postParser->mycode_parse_post_quotes_callback1
/inc/class_parser.php 816 preg_replace_callback
/inc/class_parser.php 451 postParser->mycode_parse_quotes
/inc/class_parser.php 201 postParser->parse_mycode
/printthread.php 179 postParser->parse_message
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 165 errorHandler->error
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 165 errorHandler->error
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.4.12 (Linux)
File Line Function
/printthread.php 165 errorHandler->error



2DWorlds Forums
I got an error when a script cloned a model from Storage - Printable Version

+- 2DWorlds Forums (http://2dworlds.buildism.net/forum)
+-- Forum: 2DWorlds (http://2dworlds.buildism.net/forum/forumdisplay.php?fid=4)
+--- Forum: Bug Reports (http://2dworlds.buildism.net/forum/forumdisplay.php?fid=23)
+--- Thread: I got an error when a script cloned a model from Storage (/showthread.php?tid=7108)



I got an error when a script cloned a model from Storage - Qwertygiy - 07-22-2011

[Image: 34fjxy1.png]



RE: I got an error when a script cloned a model from Storage - Jacob__mybb_import1 - 07-22-2011

Can you post your code?


RE: I got an error when a script cloned a model from Storage - Qwertygiy - 07-22-2011

Unfortunately not -- it was a fatal error and wiped out my script.

It was something along the lines of

[lua]
table1 = {}
stuff = game.Storage:getChildren()
for q = 1, #stuff do
if stuff[q]:isA("Model") then
table.insert(table1, stuff[q])
end end

function PickItem()
local item = table1[math.random(1, #table1)]
return item
end

while true do
sleep(10)
local players = game.Players:getChildren()
if #players > 0 then
local item = PickItem():clone()
item.Parent = game.World
sleep(100)
item:remove()
end end
[/lua]

There were a few other little bits -- messages and a sort of clock -- but I think that's the skeleton of the script.


RE: I got an error when a script cloned a model from Storage - Jacob__mybb_import1 - 07-22-2011

Remember to always use gameConfusedcheduleTask(). That could be causing your problem.


RE: I got an error when a script cloned a model from Storage - Qwertygiy - 07-23-2011

I'll try and see if that works.
Sad I didn't even run the script and this happened.

error Wrote:java.lang.NegativeArraySizeException
org.jbox2d.dynamics.Island.a(Island.java:118)
org.jbox2d.dynamics.PhysicsWorld.a(PhysicsWorld.java:573)
net.buildism.t.r(World.java:723)
net.buildism.af.h(Game.java:217)
net.buildism.f.p(Main.java:685)
net.buildism.MainApplet.run(MainApplet.java:209)
java.lang.Thread.run(Unknown Source)



RE: I got an error when a script cloned a model from Storage - Jacob__mybb_import1 - 07-23-2011

(07-23-2011, 12:53 PM)Qwertygiy Wrote: I'll try and see if that works.
Sad I didn't even run the script and this happened.

error Wrote:java.lang.NegativeArraySizeException
org.jbox2d.dynamics.Island.a(Island.java:118)
org.jbox2d.dynamics.PhysicsWorld.a(PhysicsWorld.java:573)
net.buildism.t.r(World.java:723)
net.buildism.af.h(Game.java:217)
net.buildism.f.p(Main.java:685)
net.buildism.MainApplet.run(MainApplet.java:209)
java.lang.Thread.run(Unknown Source)

Can you send me the game file? Never seen that one before...



RE: I got an error when a script cloned a model from Storage - Qwertygiy - 07-23-2011

Alright, I'll go back into Build and rebuild the script and then save it.


RE: I got an error when a script cloned a model from Storage - Jacob__mybb_import1 - 07-23-2011

(07-23-2011, 01:48 PM)Qwertygiy Wrote: Alright, I'll go back into Build and rebuild the script and then save it.

Did the save button in the new error message work?


RE: I got an error when a script cloned a model from Storage - Qwertygiy - 07-23-2011

I didn't bother clicking it; it crashed before the script could run so I figured it wouldn't be worth it when I have the script pretty much written down here and the main World saved online.
Here's the game, with the script written the way it was when that last error happened.