News:

Simutrans Wiki Manual
The official on-line manual for Simutrans. Read and contribute.

TileCutter 1.1.2

Started by An_dz, July 25, 2018, 11:37:05 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

An_dz



New version is out, now with full season support, no more warnings for ICCP profiles and fixing TCP projects not saving.

You can choose any combination of seasons, if you enable any of autumn, winter, spring or a combination of them and also leave either autumn, winter, spring or a combination of them disabled, those disabled will have summer season graphics.

Minor fix v1.1.1
- Fixed transparency loss on Linux
- Other quality improvements (see GitHub page for complete changelog)

Minor tweak v1.1.2
- Allow entering custom pakset sizes

Known issue
Console works but doesn't output messages.

Reporting bugs
You can submit a bug report by posting a reply to this thread or on GitHub with the following information:

1. Clear steps on how to trigger it
2. tilecutter.log and TileCutter.exe.log (if present) - These can be found under "%USERPROFILE%\Application Data\tilecutter\" on Windows, "~/Library/Logs/tilecutter.log" on OSX and "~/.tilecutter/tilecutter.log" on all other platforms.

Download
If upgrading from any version before 1.0 it's advisable to completely delete the old version instead of replacing the files.

Windows executable is stand-alone. Other platforms must download the dependencies (Python 3 & wxPython 4).

Windows version needs the Visual C++ Redistributable 2010 x64. The latest version of the 2010 version is 10.0.40219, and you can download the x64 version here.

https://github.com/An-dz/tilecutter/releases/

Future
There are planned features that you can check out on GitHub.

Thanks to Ashley Baldock, the original creator, for all the work and for letting me use the same name. This tools is a time-saver.

NNW

I get an error with the "Linux" Version:File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk3/wx/_core.py", line 12003, in Append
    return _core_.Menu_Append(*args, **kwargs)
TypeError: in method 'Menu_Append', expected argument 2 of type 'int'

An_dz

#2
You're using python 2 and wxPython 3, TileCutter is now using Python 3 and wxPython 4 since v1.

I forgot to add a shebang to tell it must use Python 3. You can either run tilecutter with python3 tilecutter.pyw or add this as the first line of tilecutter.pyw: #!/usr/bin/env python3.

NNW

God thanks, that I'm not using Linux for the first time.
I have altered python tilecutter.pyw to python3 tilecutter.pyw
And now it works lol

NNW

Houston I have another problem hihi. TC removes the Alpha channel from the images and creates on with a solid black background. This does not work with ST ;)
I'm using PovRay with the +UA switch for my objects....

An_dz

Please send me your TileCutter log and a testing image.

NNW

Template is attached

An_dz

After many hours going back and forth on the confusing reference manual and lots of testing as behaviour constantly differed between Linux and Windows it's finally fixed. The code is far more elegant now and other minor fixes were included like alerting the user if they are trying to run TileCutter with unsupported Python and wxPython versions.

Download is available on the releases page on GitHub. Windows version is also affected with the changes and I recommend to update it.

NNW

You are my Hero. But though, if you start TC with bash you get:

Traceback (most recent call last):
  File "tilecutter/tilecutter.pyw", line 6, in <module>
    from main import run
  File "/home/herruntermoser/Programme/TileCutter/tilecutter/main.py", line 39, in <module>
    import project, tc, tcui, translator
  File "/home/herruntermoser/Programme/TileCutter/tilecutter/tcui/__init__.py", line 9, in <module>
    from .menuObject import menuObject
  File "/home/herruntermoser/Programme/TileCutter/tilecutter/tcui/menuObject.py", line 9, in <module>
    gt = translator.Translator()
  File "/home/herruntermoser/Programme/TileCutter/tilecutter/translator/translator.py", line 32, in __init__
    list = os.listdir(Translator.PATH_TO_TRANSLATIONS)
FileNotFoundError: [Errno 2] No such file or directory: 'languages'


But if you start tilecutter.pyw directly it works....  ;D :question:

ACarlotti

What do you mean by "start TC with bash"? The issue you're getting seems to be that you're running it with a different working directory to the one TileCutter expects. If you change directory in the tilecutter directory before running it (which I presume is what you've effectively done when you "start tilecutter.pyw directly"), then TileCutter will be looking for the languages directory in the right place.

Of course, it's probably possible to make TileCutter set the correct working directory on startup, but I don't see any reason you'd need to run it from another directory.

An_dz

They mean from the .sh file that is included. It was wrong, but now it's fixed.

R1dO

Quote from: ACarlotti on July 26, 2019, 04:06:30 PM... but I don't see any reason you'd need to run it from another directory.

A use case could be when adding the TileCutter folder to your $PATH (or symlink `tilecutter.py` to your `bin` folder).
In order to call TileCutter from the folder you are currently working in (assuming CLI workflow, when using a launcher icon it is always possible to set the startup path).

P.s. just started it up for the first time to see what it is actually all about. Must say: first impression .. looks nice.

Phystam

Can you support pak256 size?

An_dz

There you go, version 1.1.2 adds 256, 320 and 512 to the dropdown list and also allows custom pakset sizes, as long as it's between [16, 32765] (makeobj limits).

Download on GitHub

P.S.: Not many checks are made as makeobj allows it but it's very possible you'll have bugs with odd numbered sizes.

Matthew

I am trying to run TileCutter for the first time, on Windows 7 SP1 x64, but I have failed.  :-[

I have downloaded and unpacked the 7-zip archive. It is not in a 'special' directory like Program Files. Windows Control Panel confirms that version 10.0.40219 of the Visual C++ 2010 redistributables (both x86 and x64) are already installed on my system.

Unfortunately, when I double-click on the TileCutter.exe icon, nothing happens. No process appears in Windows Task Manager and no logs are created. This result is the same both as an ordinary user and using 'Run as Administrator'. Nothing happens if I type 'TileCutter -h' at a Command Prompt either.

Does anyone have any ideas where I have gone wrong, please? Does it need an installation of Python? Does it require the C++ redistributable or TileCutter itself to be installed in particular directories?
(Signature being tested) If you enjoy playing Simutrans, then you might also enjoy watching Japan Railway Journal
Available in English and simplified Chinese
如果您喜欢玩Simutrans的话,那么说不定就想看《日本铁路之旅》(英语也有简体中文字幕)。

An_dz

@Matthew Sorry, during the zipping one dll was skipped. I've reuploaded the file and now it works as expected.

Matthew

Quote from: An_dz on September 09, 2019, 11:44:47 AM
@Matthew Sorry, during the zipping one dll was skipped. I've reuploaded the file and now it works as expected.

Thank you for that extremely swift response, @An_dz!  :star: The program now loads and the wiki page looks very helpful.
(Signature being tested) If you enjoy playing Simutrans, then you might also enjoy watching Japan Railway Journal
Available in English and simplified Chinese
如果您喜欢玩Simutrans的话,那么说不定就想看《日本铁路之旅》(英语也有简体中文字幕)。

prissi

Somehow this seems broken now. When cutting, I rather get the inverse of the cutted image ...