Weird Error Please Help

stephen008

  • Posts: 1
I can't test my games because it comes up with this.

TypeError: Error #1009: Cannot access a property or method of a null object reference.
   at stencyl.api.data::Assets$/toXML()[/home/stencyl/stencyl.net/jenkins/jobs/StencylWorks-Dist/workspace/plaf/flash/root/stencyl/api/data/Assets.as:145]
   at scripts::MyAssets/initMasterLists()[C:\Users\User 1\stencylworks\preview\scripts\MyAssets.as:491]
   at scripts::MyAssets/initAssets()[C:\Users\User 1\stencylworks\preview\scripts\MyAssets.as:446]
   at Function/<anonymous>()[C:\Users\User 1\stencylworks\preview\scripts\MyAssets.as:427]
   at flash.events::EventDispatcher/dispatchEventFunction()
   at flash.events::EventDispatcher/dispatchEvent()
   at flash.net::URLLoader/onComplete()

Please help

Rob

  • *
  • Posts: 1268
We can help you.

Can you do a few things for us?

0. What OS are you on?

1. Go into Stencyl, do Debug ->Generate Logs and post it here.

2a. Try to test any sample games -> use Test in Flash Player on Top. Let us know if this works
  b.  Try to test any sample games -> user Test in Browser on Top. Let us know if this works.

3. Go into Stencyl, do File->Preferences->Workspace and post your workspace folder path here.

4. Next, navigate to this workspace in your file system (outside of stencyl program), you should see a stencylworks folder.
    Are you seeing 5 folders:
    - games
    - log
    - extensions
    - preview
    - prefs
    Go into stencylworks:
    a. Can you zip the prefs folder and post here
    b. Can you also zip the preview folder and post here.

Please make sure you do all the things above. So far, I worked with close to 10 people and none of them get us the information we requested.
GOLDEN RULE #1 : SAVE YOUR GAMES FREQUENTLY
IOS/XCODE DEBUGGING
http://www.stencyl.com/help/view/xcode-ios-troubleshoot/
WATCH STENCYLWORKS VIDEO TUTORIAL BY SUNRISEKINGDOM
http://www.youtube.com/watch?v=KDfRfjzr9j4&feature=channel_video_title

Plotz

  • Posts: 4
Hi

I have the same problem and get the same error message. The only difference is the numbers
displayed after "...\MyAssets.as:..." are different.

If I'm jumping in here and stepping on toes I apologize. Hopefully we can solve this issue.
Answering the questions you requested:

0. I'm running windows 7 64bit. Also just upgraded to stencyl 2.0

1. Attached are my log files

2a. Sample games report the same error.
2b. Sample games run in a browser with no problems.

3. Workspace folder path: C:\Users\Philip Lotz\   
   
4. All 5 folders are there, zips of "prefs" and "preview" attached.

Thanks

Rob

  • *
  • Posts: 1268
Amazing. You are the first one who has answered all my questions cleanly.

This is what you can do:

1. Go to C:\Users\Philip Lotz\

2. You should see stencylworks folder. Rename it to anything but PLEASE DO NOT DELETE IT.

3. Next, reinstall stencyl 2.0.

4. With that navigate to C:\Users\Philip Lotz\AppData/Roaming/Stencyl and let me know if you see:

a. Stencylworks.prefs. If so, please post the lines inside.

b. stencylworks folder

5. Just test any sample games in flash player. It should work.

GOLDEN RULE #1 : SAVE YOUR GAMES FREQUENTLY
IOS/XCODE DEBUGGING
http://www.stencyl.com/help/view/xcode-ios-troubleshoot/
WATCH STENCYLWORKS VIDEO TUTORIAL BY SUNRISEKINGDOM
http://www.youtube.com/watch?v=KDfRfjzr9j4&feature=channel_video_title

Plotz

  • Posts: 4
Rob

I did as you said and it worked! Thank you so much!

Both Stencylworks.prefs and stencylworks folder are present in ...\AppData/Roaming/Stencyl
Didn't understand what you meant by "If so, please post lines inside" though.

I also noticed that the workspace path is different now than previously (...\AppData/Roaming/Stencyl). Obviously this is a bit of a moot point but why is that? I'm just curious as to why reinstalling and a different workspace path can fix this problem. This is more a question of wanting to know than needing to know.

Thanks again for your help!

Rob

  • *
  • Posts: 1268
You have been of great help. I am definitely marking you name down.

Your scenarios is exactly what happened to probably 10-20 people who have the problem. I'm still trying to figure out the root cause.

In term of window workspace, this is what's under the hood.

Stencyl 1.4x

For stenycl 1.4x and prior or that, there are 2 installation areas, one for the stencyl program itself (defaulted to C:\Program Files\Stencylworks) and one for stencyl data files (generally defaulted to user <home folder>\stencylworks.). The stencylworks folder contains subfolders like games, logs, extensions which are pertinent to user game data. There is one additional file called Stencylworks.prefs which contains user preferred settings (global settings that controls Stencyl data file location, naming and others)

One of the most important field in this file is :
       global.workdir=G:\Documents and Settings\<user name>\/
which let one control where all existing and future data files should reside. This field is settable by going into Stencyl Program and changing the workspace under File-> Preferences-> Workspace ->Workspace Folder.

One other note of interest, in window system, one's home folder is located at:
C:\Document and Settings\<user name> for window xp
C:\Users\<user name> for window vista or window 7.

Stencyl 2.0

For stenycl 2.0, there are still 2 installation areas, one for the stencyl program itself (defaulted to C:\Program Files\Stencyl) and one for stencyl data files.

The data files location are now defaulted to:

C:\Document and Settings\<user name>\Application Data\Stencyl for window xp
C:\Users\<user name>\AppData\Roaming\Stencyl  for window vista or window 7.

Under these Stencyl folder, you will still find the stencylworks folder and Stencylworks.prefs file

Stencyl 1.4x to Stencyl 2.0

Now comes the most important part of our transition from 1.4x to 2.0.

If Stencyl can find BOTH the Stencylworks.prefs and stencylworks, it will:

(a) Move the Stencylworks.prefs to our new location:

C:\Document and Settings\<user name>\Application Data\Stencyl\ Stencylworks.prefs for window xp
C:\Users\<user name>\AppData\Roaming\Stencyl\Stencylworks.prefs for window vista or window 7.

(b) Retain the location of stencylworks which in most cases is under user <home folder>  (Note Stencylworks.prefs contains info of this workspace location).

If Stencyl cannot find the Stencylworks.prefs or stencylworks or neither of these items, it will be set to the default location as mentioned above.

C:\Document and Settings\<user name>\Application Data\Stencyl for window xp
C:\Users\<user name>\AppData\Roaming\Stencyl  for window vista or window 7.

Under thse Stencyl folder, you will find a new stencylworks folder and the Stencylworks.prefs file with workspace now pointing to ...\AppData/Roaming/Stencyl.

Hope all this make it clear.

Since I requested you to rename stenylworks folder, it is essentially asking Stencyl to reset to it's default data file settings and location.

"Obviously this is a bit of a moot point but why is that? I'm just curious as to why reinstalling and a different workspace path can fix this problem. This is more a question of wanting to know than needing to know." This is exactly what I am trying to figure out too.




« Last Edit: April 28, 2012, 08:08:09 am by Rob »
GOLDEN RULE #1 : SAVE YOUR GAMES FREQUENTLY
IOS/XCODE DEBUGGING
http://www.stencyl.com/help/view/xcode-ios-troubleshoot/
WATCH STENCYLWORKS VIDEO TUTORIAL BY SUNRISEKINGDOM
http://www.youtube.com/watch?v=KDfRfjzr9j4&feature=channel_video_title

Rob

  • *
  • Posts: 1268
One think I forgot to ask you is whether you have administrator access when you have those test game 1009 problems.
GOLDEN RULE #1 : SAVE YOUR GAMES FREQUENTLY
IOS/XCODE DEBUGGING
http://www.stencyl.com/help/view/xcode-ios-troubleshoot/
WATCH STENCYLWORKS VIDEO TUTORIAL BY SUNRISEKINGDOM
http://www.youtube.com/watch?v=KDfRfjzr9j4&feature=channel_video_title

Plotz

  • Posts: 4
Thanks for your explanation. Very clear.
I did have administrator access when I got those errors.

Thanks again.

Rob

  • *
  • Posts: 1268
Hmm.

The main problem is that I do not have the machines and setup to debug this further. I've already send in your logs for investigation.

If you still have your "bad" stencylworks, please continue to keep a copy of that.

If you have extra time and are not developing any games yet, please give this a try.

Just simply move your stencylworks (the good one) under ...\AppData/Roaming/Stencyl to another name, now copy the "bad" stencylworks folder to this location. Make sure the folder name is still stencylworks. Now, fire up stencyl 2.0 and see if you can test game properly.

This is to test whether the problem is data files (stuff inside stencylworks) related or it's location related (because we moved away from home folder to Roaming folder). I hope it's data related. Then we can hunt this down further.

Thanks for helping out in this matter.
GOLDEN RULE #1 : SAVE YOUR GAMES FREQUENTLY
IOS/XCODE DEBUGGING
http://www.stencyl.com/help/view/xcode-ios-troubleshoot/
WATCH STENCYLWORKS VIDEO TUTORIAL BY SUNRISEKINGDOM
http://www.youtube.com/watch?v=KDfRfjzr9j4&feature=channel_video_title

Plotz

  • Posts: 4
Hey
Sorry for the late reply.
Did what you asked and I could test the game properly. Don't know if that helps.

Rob

  • *
  • Posts: 1268
Thanks for getting back to me.

We eventually traced the issue to this:

http://community.stencyl.com/index.php/topic,10245.msg62447.html#msg62447

So, if you ever have problem again, just hunt down Stencylworks.prefs and look for global.workdir.
GOLDEN RULE #1 : SAVE YOUR GAMES FREQUENTLY
IOS/XCODE DEBUGGING
http://www.stencyl.com/help/view/xcode-ios-troubleshoot/
WATCH STENCYLWORKS VIDEO TUTORIAL BY SUNRISEKINGDOM
http://www.youtube.com/watch?v=KDfRfjzr9j4&feature=channel_video_title

karatekatana

  • Posts: 1
0. Windows xp Professional, Stencyl 2.1.0 (b501)

1. Files are attached below

2a. Sample games run without error
2b. Sample games run in internet explorer also with no error

3. C:\Documents and Settings\jwinter/Application Data/Stencyl/

4a. Attached
4b. Attached
Thanks in advance if this helps :)

***Game is not finished don't expect it to be good***