The International Simutrans Forum

 

Author Topic: TileCutter 1.2.1  (Read 2158 times)

0 Members and 1 Guest are viewing this topic.

Offline An_dz

  • Web Admin
  • Administrator
  • *
  • Posts: 2920
  • D'oh
    • by An_dz
  • Languages: pt, en, it, (de)
TileCutter 1.2.1
« on: July 15, 2020, 01:26:06 AM »


New version is out, now with night view and special colours view, the first steps to implementing Shades into TileCutter.

Night view has the same logic from Simutrans so you get the same colours from the game.

The Windows version is now compiled with Nuitka that brings improved performance. And hopefully I'll get a MacOS release compiled with Nuitka too, in the meantime you can download the Linux version and run it by calling libs/tilecutter.pyw from the root path.

The Linux version now comes with a install.sh file that will create an executable .desktop icon in the directory and will also offer the option to add an icon to the Start Menu. Some distros will allow double-clicking this install file but on some you'll need to call from terminal with ./install.sh.

Major fix v1.2.1
- Fix TileCutter main purpose failing (wxPython bug)
- Fix loading projects before full season support
- Projects created before transparency support now load with transparency off by default

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.

All executables are standalones. You only need Python, wxPython and NumPy installed if using from source.

Windows version needs the Visual C++ Redistributable 2015-2019 x64. The latest version at the time of writting was 14.26.28720.3, and you can download the x64 version here (Bottom of the page under "Other Tools and Frameworks").

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.
« Last Edit: July 26, 2020, 09:05:22 PM by An_dz »

Offline TheRoadmaster1996

  • *
  • Posts: 273
  • Languages: EN, some ES, learning JP
Re: TileCutter 1.2.0
« Reply #1 on: July 16, 2020, 06:02:26 PM »
Useful feature! I like it.

Offline TheRoadmaster1996

  • *
  • Posts: 273
  • Languages: EN, some ES, learning JP
Re: TileCutter 1.2.0
« Reply #2 on: July 17, 2020, 10:17:07 PM »
Whenever I try to create the image and .dat file using the new Tilecutter version, it won't do anything. Am I missing something or am I doing something wrong?

Offline An_dz

  • Web Admin
  • Administrator
  • *
  • Posts: 2920
  • D'oh
    • by An_dz
  • Languages: pt, en, it, (de)
Re: TileCutter 1.2.0
« Reply #3 on: July 24, 2020, 04:49:24 AM »
Probably a bug, I found some too when loading a project. You'll need to use the previous version for now

Offline TheRoadmaster1996

  • *
  • Posts: 273
  • Languages: EN, some ES, learning JP
Re: TileCutter 1.2.0
« Reply #4 on: July 24, 2020, 02:00:51 PM »
Ok.

Offline An_dz

  • Web Admin
  • Administrator
  • *
  • Posts: 2920
  • D'oh
    • by An_dz
  • Languages: pt, en, it, (de)
Re: TileCutter 1.2.1
« Reply #5 on: July 26, 2020, 09:01:12 PM »
All good now. Found out it was a bug on wxPython, so I made a workaround for now. I also fixed some bugs on loading old tcp files.

The Windows release is probably more optimised too.

Offline TheRoadmaster1996

  • *
  • Posts: 273
  • Languages: EN, some ES, learning JP
Re: TileCutter 1.2.1
« Reply #6 on: July 28, 2020, 03:13:43 PM »
Cool  8) Thank you! Now we need TileCuter to support eight directions instead of four.

Offline Leartin

  • Oh no, not him again!
  • Devotee
  • *
  • Posts: 1573
  • PAK-DEV P192C
  • Languages: DE, EN
Re: TileCutter 1.2.1
« Reply #7 on: July 28, 2020, 03:52:10 PM »
Cool  8) Thank you! Now we need TileCuter to support eight directions instead of four.
What for? Which multitile building supports more than 4 directions?

Offline TheRoadmaster1996

  • *
  • Posts: 273
  • Languages: EN, some ES, learning JP
Re: TileCutter 1.2.1
« Reply #8 on: July 28, 2020, 06:41:33 PM »
There are some like those in Pak128.Britain. They have shops and industries that have eight directions.

Offline Freahk

  • Devotee
  • *
  • Posts: 1449
  • Languages: DE, EN
Re: TileCutter 1.2.1
« Reply #9 on: July 28, 2020, 07:43:24 PM »
Eight directions?
I am quite sure you confuse something.
You might be refering to corner buildings?
« Last Edit: July 28, 2020, 08:23:31 PM by Freahk »

Offline TheRoadmaster1996

  • *
  • Posts: 273
  • Languages: EN, some ES, learning JP
Re: TileCutter 1.2.1
« Reply #10 on: July 28, 2020, 08:36:30 PM »
yes. that's it.

Offline Leartin

  • Oh no, not him again!
  • Devotee
  • *
  • Posts: 1573
  • PAK-DEV P192C
  • Languages: DE, EN
Re: TileCutter 1.2.1
« Reply #11 on: July 29, 2020, 07:58:46 AM »
Eight-directional buildings are only an option for res, com and ind - but not if they are larger than 1x1. If they are 1x1, they don't need to be cut.

Offline TheRoadmaster1996

  • *
  • Posts: 273
  • Languages: EN, some ES, learning JP
Re: TileCutter 1.2.1
« Reply #12 on: July 29, 2020, 04:11:58 PM »
Right, thank you.

Online Vladki

  • Devotee
  • *
  • Posts: 3711
    • My addons, mostly roadsigns, pak128.cs
  • Languages: EN, CS
Re: TileCutter 1.2.1
« Reply #13 on: November 14, 2020, 03:07:57 PM »
I have two problems wit the 1.2.1 release on linux.

First it does not load saved project:

Code: [Select]
TileCutter : INFO TC:Menu-File-> Open Project: menuObject.OnOpenProject
TileCutter : INFO TC:Loading project: main.OnLoadProject
TileCutter : DEBUG TC:Check Project for changes - Project Unchanged: project.has_changed
TileCutter : INFO TC:Opening Load Dialog to allow location picking: main.dialog_load
TileCutter : DEBUG TC:directory: /home/vladki/simutrans-dev/pak128.dev/lubak-lihovar, filename: lihovar-tilecutter.tcp: main.dialog_load
TileCutter : DEBUG TC:User picked location: /home/vladki/simutrans-dev/pak128.dev/lubak-lihovar/lihovar-tilecutter.tcp: main.dialog_load
TileCutter : DEBUG TC:Load dialog returned a path: /home/vladki/simutrans-dev/pak128.dev/lubak-lihovar/lihovar-tilecutter.tcp: main.OnLoadProject
TileCutter : INFO TC:Load project from file: /home/vladki/simutrans-dev/pak128.dev/lubak-lihovar/lihovar-tilecutter.tcp: main.load_project
TileCutter : INFO TC:Initialising new TcpReader, file: /home/vladki/simutrans-dev/pak128.dev/lubak-lihovar/lihovar-tilecutter.tcp: tcp.__init__
TileCutter : INFO TC:Loading object from file: tcp.load
TileCutter : DEBUG TC:attempting to load as JSON: tcp.load
Traceback (most recent call last):
  File "/home/vladki/tilecutter/libs/tcui/menuObject.py", line 142, in OnOpenProject
    self.app.OnLoadProject()
  File "/home/vladki/tilecutter/libs/main.py", line 373, in OnLoadProject
    return self.load_project(loadpath)                      # Load the project (returns project object or False depending on success)
  File "/home/vladki/tilecutter/libs/main.py", line 305, in load_project
    project = t_reader.load([self])
  File "/home/vladki/tilecutter/libs/tcp.py", line 98, in load
    loadobj = json.loads(file_content)
  File "/usr/lib/python3.5/json/__init__.py", line 312, in loads
    s.__class__.__name__))
TypeError: the JSON object must be str, not 'bytes'

Second is that it produces the cut image in some sort of inverse logic. The tile that should be there is completely transparent, while the surroundings are there. Tried with and without transparency, niether worked.

Also while creating the project, it somehow messed up paths to original images, and at first attempt created blank image. Then I entered absolute paths and it worked but produced wrong result as attached.