How to read and write in plaintext without using external editors and parsers?

Discuss the new AI features ("NoAI") introduced into OpenTTD 0.7, allowing you to implement custom AIs, and the new Game Scripts available in OpenTTD 1.2 and higher.

Moderator: OpenTTD Developers

Post Reply
agentw4b
Traffic Manager
Traffic Manager
Posts: 155
Joined: 14 Apr 2017 15:51
Location: Czech Republic

How to read and write in plaintext without using external editors and parsers?

Post by agentw4b » 06 May 2019 20:50

Unfortunately gamescript can only read with use function "Import" a text in the directory where the script is installed.
And turning on logging will produce dirty text as an output with various tags that is not usable without an external parser.
I miss ordinary editor typu read / write pro gamescripty :-( Can I do it somehow?
Last edited by agentw4b on 06 May 2019 21:02, edited 2 times in total.
Owner and admin of servers:Experimental games 01 (92.63.57.152:3979), Experimental games 02 (92.63.57.152:3879), Experimental games 03 (92.63.57.152:3779), Experimental games 04 (92.63.57.152:3679), Experimental games 05 (92.63.57.152:3579).
My heightmaps: Flat Earth Map and United nations logo
My scenarios: Game Fallout 1,2,3 Map scenario
My gamescripts: City Founder GS

agentw4b
Traffic Manager
Traffic Manager
Posts: 155
Joined: 14 Apr 2017 15:51
Location: Czech Republic

Re: How to read and write in plaintext without using external editors and parsers?

Post by agentw4b » 06 May 2019 20:57

Regarding the outputs and inputs via the Admin port using JSON format, there is, unfortunately, no usable tool to play with, which would solve this for an ordinary user. The tools I have seen are unusable for non-programmers ...
Owner and admin of servers:Experimental games 01 (92.63.57.152:3979), Experimental games 02 (92.63.57.152:3879), Experimental games 03 (92.63.57.152:3779), Experimental games 04 (92.63.57.152:3679), Experimental games 05 (92.63.57.152:3579).
My heightmaps: Flat Earth Map and United nations logo
My scenarios: Game Fallout 1,2,3 Map scenario
My gamescripts: City Founder GS

Post Reply

Return to “OpenTTD AIs and Game Scripts”

Who is online

Users browsing this forum: No registered users and 2 guests