Custom tiles crash my game

Re: Custom tiles crash my game

Postby dexnim » 18 Mar 2015, 05:07

~/supertux.editor$ make supertux-editor.exe
make: `supertux-editor.exe' is up to date.

~/supertux.editor$ make install supertux-editor.exe
make: *** No rule to make target `install'. Stop.

That's what happens. There's no Debug folder in there. Just data/, Dock/, gtkgl-sharp/, libeditor/, Lisp/, LispReader/, Resources/, supertux-editor/, and tools/.ll


Oh wait, I just ran the supertux editor as root from the command line, and it gave me the error that let me choose the location for the supertux.exe that it runs. I added /usr/games/ to it and I can make a new level now. I can also open old ones. However, when I attempt to pick the custom tileset in the tile selector, it crashes the game. Here's the output that gives:

DEBUGWARN: Tilegroup Snow contains invalid TileID 2947
DEBUG: UndoManager.MarkAsSaved() called when UndoStack was empty.
Marshaling expose_event signal
Exception in Gtk# callback delegate
Note: Applications can use GLib.ExceptionManager.UnhandledException to handle the exception.
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Exception: Couldn't load resource 'images/tiles/custom/custom.png' ---> System.IO.DirectoryNotFoundException: Could not find a part of the path "/usr/share/games/supertux2/images/tiles/custom/custom.png".
at System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean anonymous, FileOptions options) [0x00000] in <filename unknown>:0
at System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean isAsync, Boolean anonymous) [0x00000] in <filename unknown>:0
at System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access) [0x00000] in <filename unknown>:0
at (wrapper remoting-invoke-with-check) System.IO.FileStream:.ctor (string,System.IO.FileMode,System.IO.FileAccess)
at Resources.DefaultResourceManager.Get (System.String ResourcePath) [0x00000] in <filename unknown>:0
--- End of inner exception stack trace ---
at Resources.DefaultResourceManager.Get (System.String ResourcePath) [0x00000] in <filename unknown>:0
at Drawing.TextureManager.CreateImageTexture (System.String Resourcepath) [0x00000] in <filename unknown>:0
at Drawing.TextureManager.Get (System.String Resourcepath) [0x00000] in <filename unknown>:0
at Drawing.Surface..ctor (System.String Resourcepath, Single x, Single y, Single w, Single h) [0x00000] in <filename unknown>:0
at Tile.LoadSurface (System.String BaseDir, ImageResource Resource) [0x00000] in <filename unknown>:0
at Tile.LoadSurfaces (System.String BaseDir, Boolean Editor) [0x00000] in <filename unknown>:0
at Tileset.Get (Int32 id) [0x00000] in <filename unknown>:0
at TileListWidget.DrawGl () [0x00000] in <filename unknown>:0
at GLWidgetBase.OnExposed (System.Object o, Gtk.ExposeEventArgs args) [0x00000] in <filename unknown>:0
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0
--- End of inner exception stack trace ---
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0
at System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) [0x00000] in <filename unknown>:0
at System.Delegate.DynamicInvokeImpl (System.Object[] args) [0x00000] in <filename unknown>:0
at System.MulticastDelegate.DynamicInvokeImpl (System.Object[] args) [0x00000] in <filename unknown>:0
at System.Delegate.DynamicInvoke (System.Object[] args) [0x00000] in <filename unknown>:0
at GLib.Signal.ClosureInvokedCB (System.Object o, GLib.ClosureInvokedArgs args) [0x00000] in <filename unknown>:0
at GLib.SignalClosure.Invoke (GLib.ClosureInvokedArgs args) [0x00000] in <filename unknown>:0
at GLib.SignalClosure.MarshalCallback (IntPtr raw_closure, IntPtr return_val, UInt32 n_param_vals, IntPtr param_values, IntPtr invocation_hint, IntPtr marshal_data) [0x00000] in <filename unknown>:0
at GLib.ExceptionManager.RaiseUnhandledException(System.Exception e, Boolean is_terminal)
at GLib.SignalClosure.MarshalCallback(IntPtr raw_closure, IntPtr return_val, UInt32 n_param_vals, IntPtr param_values, IntPtr invocation_hint, IntPtr marshal_data)
at Gtk.Application.gtk_main()
at Gtk.Application.Run()
at Application.Main(System.String[] args)
dexnim
 
Posts: 23
Joined: 19 Feb 2015, 01:25

Re: Custom tiles crash my game

Postby Tobbi » 18 Mar 2015, 13:37

We're getting somewhere, Can you please place custom.png in data/images/tiles/custom/ in your selected SuperTux directory?
SuperTux developer.
User avatar
Tobbi
SuperTux Moderator
 
Posts: 353
Joined: 12 Oct 2013, 13:08

Re: Custom tiles crash my game

Postby dexnim » 19 Mar 2015, 19:37

I can't find the data/ folder. I don't see one anywhere in any of my supertux directories.
dexnim
 
Posts: 23
Joined: 19 Feb 2015, 01:25

Re: Custom tiles crash my game

Postby Tobbi » 19 Mar 2015, 23:13

It should be in the directory where supertux2 resides. If there's no data folder in that folder, supertux should crash on startup or something.
SuperTux developer.
User avatar
Tobbi
SuperTux Moderator
 
Posts: 353
Joined: 12 Oct 2013, 13:08

Re: Custom tiles crash my game

Postby dexnim » 20 Mar 2015, 03:23

There isn't a data folder in any supertux folder on my computer, except for in the supertux.editor folder. Is that the folder that you mean?
dexnim
 
Posts: 23
Joined: 19 Feb 2015, 01:25

Re: Custom tiles crash my game

Postby Tobbi » 20 Mar 2015, 10:53

When you start SuperTux, it should print the data directory on the console, like this:
[INFO] C:/msys64/home/WindowsUser/supertux/src/supertux/main.cpp:225 C:\msys64\home\WindowsUser\supertux\/data

See if you can find that.

Also, tiles.strf should be somwhere in the same data directory.
SuperTux developer.
User avatar
Tobbi
SuperTux Moderator
 
Posts: 353
Joined: 12 Oct 2013, 13:08

Re: Custom tiles crash my game

Postby dexnim » 23 Mar 2015, 21:47

Mine doesn't tell me the directory. It tells me that a bunch of stuff in /build/buildd/supertux-0.3.4/src/ happened, and that it found add-ons in /home/USERNAME/.supertux2/ but it doesn't tell me anything else.
dexnim
 
Posts: 23
Joined: 19 Feb 2015, 01:25

Re: Custom tiles crash my game

Postby Tobbi » 23 Mar 2015, 22:10

Your supertux directory is likely /build/buildd/supertux-0.3.4/

You should find the data directory there. And a tiles.strf in data/images/tiles iirc.
SuperTux developer.
User avatar
Tobbi
SuperTux Moderator
 
Posts: 353
Joined: 12 Oct 2013, 13:08

Re: Custom tiles crash my game

Postby dexnim » 23 Mar 2015, 22:42

The command
locate /buildd/
comes up blank.
locate /build/
gives me a bunch of random files, but none of them have anything remotely to do with supertux.
dexnim
 
Posts: 23
Joined: 19 Feb 2015, 01:25

Re: Custom tiles crash my game

Postby Tobbi » 23 Mar 2015, 23:09

What about locate supertux2 ?
SuperTux developer.
User avatar
Tobbi
SuperTux Moderator
 
Posts: 353
Joined: 12 Oct 2013, 13:08

Re: Custom tiles crash my game

Postby dexnim » 24 Mar 2015, 01:10

Here's the output for that command...

EDIT: WARNING! It's really really really really... ...really long. I searched for /build in there and /buildd and build and buildd, and the only thing that showed up was "builder"
Attachments
output.txt
(136.12 KiB) Downloaded 263 times
dexnim
 
Posts: 23
Joined: 19 Feb 2015, 01:25

Re: Custom tiles crash my game

Postby Tobbi » 24 Mar 2015, 10:28

The location of tiles.strf in your case is /usr/share/games/supertux2/images/tiles.strf

So, custom.png should be placed in /usr/share/games/supertux2/images/tiles/custom/custom.png

Sorry for the confusion. Please place the file there.
SuperTux developer.
User avatar
Tobbi
SuperTux Moderator
 
Posts: 353
Joined: 12 Oct 2013, 13:08

Re: Custom tiles crash my game

Postby dexnim » 24 Mar 2015, 18:24

Alright, put it in there. Now it gives me this output when I run the editor. (I have to run supertux as root, but I know how to change that)
Attachments
error.txt
(4.72 KiB) Downloaded 283 times
dexnim
 
Posts: 23
Joined: 19 Feb 2015, 01:25

Re: Custom tiles crash my game

Postby Tobbi » 24 Mar 2015, 22:12

That doesn't seem to be an error. Is there anything not working?
SuperTux developer.
User avatar
Tobbi
SuperTux Moderator
 
Posts: 353
Joined: 12 Oct 2013, 13:08

Re: Custom tiles crash my game

Postby dexnim » 26 Mar 2015, 18:04

Yeah. The game won't run. I place the custom tile, run the game, and it crashes and returns that into the console.
dexnim
 
Posts: 23
Joined: 19 Feb 2015, 01:25

Re: Custom tiles crash my game

Postby Tobbi » 27 Mar 2015, 10:29

Please attach tiles.strf and your level, and I will check it out! :-)
SuperTux developer.
User avatar
Tobbi
SuperTux Moderator
 
Posts: 353
Joined: 12 Oct 2013, 13:08

Re: Custom tiles crash my game

Postby Mr. Hilter » 05 Apr 2015, 18:01

dexnim {l Wrote}:I can't even find the editor on my system anymore. What directory is it supposed be in?


Look for supertux-editor.exe. If you used default install it should be in C:\Program Files (x86)\SuperTux Editor 0.3.0\
Mr. Hilter
 
Posts: 13
Joined: 07 Oct 2013, 22:32
Location: North Minehead

Re: Custom tiles crash my game

Postby dexnim » 07 Apr 2015, 20:31

Here's my level(with a custom tile in it already), my tiles.strf file(which won't upload for some reason), and the image.
Attachments
custom.png
custom.png (32 KiB) Viewed 9386 times
Test.txt
(22.32 KiB) Downloaded 253 times
dexnim
 
Posts: 23
Joined: 19 Feb 2015, 01:25

Re: Custom tiles crash my game

Postby Tobbi » 08 Apr 2015, 01:16

Please rename .strf into .txt for the tiles file and try to upload it again.
SuperTux developer.
User avatar
Tobbi
SuperTux Moderator
 
Posts: 353
Joined: 12 Oct 2013, 13:08

Who is online

Users browsing this forum: No registered users and 1 guest