Chill's patchpack v14_7

Forum for technical discussions regarding development. If you have a general suggestion, problem or comment, please use one of the other forums.

Moderator: OpenTTD Developers

User avatar
SpComb
Tycoon
Tycoon
Posts: 1109
Joined: 13 Nov 2003 20:26
Location: Finland
Contact:

Re: Chill's patchpak v5

Post by SpComb »

ChillCore wrote:I still have running_ticks at int16 and will look further for a better solution.
Be aware that Vehicle::running_ticks is also part of the saveload data:

Code: Select all

src/saveload/vehicle_sl.cpp:             SLE_CONDVAR(Vehicle, running_ticks,         SLE_UINT8,                   88, SL_MAX_VERSION),
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2852
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Chill's patchpak v5

Post by ChillCore »

Coldice wrote: hmm.. now i get only 4 warnings
I will report those perfomance warnings you have left there to Owen and ask him what has to happen with "#include strings.h" in programmable_signals.h.
Outcommenting the line does not seem to make a difference. Also in Cadde's patch it is string.h while in Owen's original patch (and the patchpak) it is strings.h ...
ColdIce wrote: I can`t make prog signal to work. The window for settings doesnt pop-up. maybe i`m doing something wrong
the rest of the patches are working just fine.
I do not know if you did something wrong.
See attachment for how it should work, for me it does.

1. Click programmable signal
2. Place signal
3. click program button
4. click signal to program
-> Window should open.
SpComb wrote: Be aware that Vehicle::running_ticks is also part of the saveload data:

Code: Select all

src/saveload/vehicle_sl.cpp:             SLE_CONDVAR(Vehicle, running_ticks,         SLE_UINT8,                   88, SL_MAX_VERSION),
Cool, thank you for the info.
int16 was a typo, I have uint16 in my code.
Could it be that the overflow warnings came from not having changed it there also?
I will change it in my source.

Edit:
Updated the patch to v5_1. You can find it in the second post.

Removed strings.h from programmable_signals.h for some people to be able to compile.
Corrected a typo in vehicle_base.h: uint16 running ticks instead of int16. (I had changed it in my testfolder but not in the folder from where I pulled the patch. Oopsie)
I have also added the needed changes for running_ticks in saveload/vehicle_sl.cpp as mentioned by SpComb.

Could someone please compile with VC++ 2008 or Visual Studio to see if the overflow warnings in aircraft_cmd.cpp, roadveh_cmd.cpp, ship_cmd.cpp and train_cmd.cpp are gone or not? For me the patch compiles cleanly so it is a bit hard to know if my changes fixed it or not.

The performance warnings provided by ColdIce have been reported in the programmable signals thread.

Edit2: Added the patch for ColdIce's build below.
Attachments
Danwell Transport, 1950-01-21.png
Danwell Transport, 1950-01-21.png (25.74 KiB) Viewed 7690 times
chipp_v5_1_r19673.diff
(799.08 KiB) Downloaded 287 times
Last edited by ChillCore on 01 May 2010 14:10, edited 1 time in total.
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
User avatar
ColdIce
Transport Coordinator
Transport Coordinator
Posts: 314
Joined: 25 Apr 2006 10:22
Location: Bucharest

Re: Chill's patchpak v5_1

Post by ColdIce »

1. programmable signal problem - that was me. it works :oops:
2. the new patch compiled ok, only with those warnings.

here is the log http://www.heypasteit.com/clip/J6Z

not compatible with previous save games (r16599)

:!: win32 build (flat_blacktiles.grf not included) :!: READ THE POST BELOW :!:
Attachments
19673.rar
(3.58 MiB) Downloaded 338 times
Last edited by ColdIce on 20 Apr 2010 16:21, edited 1 time in total.
The rest is confetti!
User avatar
ColdIce
Transport Coordinator
Transport Coordinator
Posts: 314
Joined: 25 Apr 2006 10:22
Location: Bucharest

Re: Chill's patchpak v5_1

Post by ColdIce »

sorry for double post, but the last build has a problem

towns doesnt expand more that 7x7 tiles, not even in editor.
Attachments
problem.png
The rest is confetti!
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2852
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Chill's patchpak v5_1

Post by ChillCore »

Thank you for reporting ColdIce.
Also thank you for the binary and the testing.

Quick testing with OpenTTD-1.0.1-RC1 shows that the problem is in trunk.
It will not allow to expand towns with road grids 2 * 2 and 3 * 3.
The original and the improved road grids do allow for expanding.

I tested only in the scenario editor.
I have not yet tested the latest nightly so I do not know if the problem is already reported and fixed or not...
Will try that in a bit.

The next version will be coming soon as I have fixed a the airport bug in the moreheightlevels patch and Owen has fixed the deleting signals and clicking on tiles without rail crashes.

Edit:
The same probem exist in yesterdays nightly.
Looking at Flyspray it does not seem to be reported yet.
I will try a few older versions and see if I can figure out when the bug was introduced.
Maybe it is time I get me a Flyspray account. ;)

Edit2:
Fixed in r19683.
Thank you Smatz.
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
User avatar
ColdIce
Transport Coordinator
Transport Coordinator
Posts: 314
Joined: 25 Apr 2006 10:22
Location: Bucharest

Re: Chill's patchpak v5_1

Post by ColdIce »

r19683 | smatz | 2010-04-20 17:49:11 +0000 (Tue, 20 Apr 2010) | 1 line

-Fix (r19654): towns with 3x3 and 2x2 road layouts couldn't expand

:D

is there any chance to include the copy&paste patch? :mrgreen:
The rest is confetti!
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2852
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Chill's patchpak v5_1

Post by ChillCore »

ColdIce wrote: is there any chance to include the copy&paste patch? :mrgreen:
It is included in my test build but I find it to easy to crash.
When clicking the button to open the gui or when trying to save templates crashes the game.
The gui opens with CTRL+v.
Maybe somewhere else it has problems too but I did not test it enough yet.

If you want you can patch the latest trunk version(not the 1.0.0 version) on top of the patchpack. There is only one conflict to solve in window.type.h.

Code: Select all

	WC_SIGNAL_PROGRAM,
	WC_COPY_PASTE,
Maybe I will make it part of the patchpack after having tested it more.


I am currently testing the changes in the programmable signals patch.
If all goes as it should, I will port the changes form my test build to my patchpack folder and post the new diff.
I was having some issues with the signals gui after doing the changes made by Owen. I have solved those but have not yet tested the rest yet.
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
User avatar
ColdIce
Transport Coordinator
Transport Coordinator
Posts: 314
Joined: 25 Apr 2006 10:22
Location: Bucharest

Re: Chill's patchpak v5_1

Post by ColdIce »

Copy & paste patch, revision 19692, works with chillcore patch pack r19599, but only if you download trunk r19600 :wink:
The rest is confetti!
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2852
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Chill's patchpak v5_1

Post by ChillCore »

ColdIce wrote: Copy & paste patch, revision 19692, works with chillcore patch pack r19599, but only if you download trunk r19600 :wink:
Thanks for the info.

I have been testing v6 but there is still a few crashes with it when using copypaste.
Do you see these errors also with r19600?
- NOT_REACHED triggered at line 146 of copypaste/src/strings.cpp
-> trying to load an ?unloadable? old template.
- Assertion failed at line 53 of copypaste/src/core/pool_type.hpp: index < this->first_unused
-> old template loaded but failed to paste.

Saving and loading new templates seem to work fine.
I could ofcourse post v6 and tell people not to load old templates but it would be better if I could fix it first. ;)
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
User avatar
ColdIce
Transport Coordinator
Transport Coordinator
Posts: 314
Joined: 25 Apr 2006 10:22
Location: Bucharest

Re: Chill's patchpak v5_1

Post by ColdIce »

4>console.cpp
4>..\src\copy_paste.cpp(284) : warning C4805: '|' : unsafe mix of type 'bool' and type 'int' in operation
4>..\src\copy_paste.cpp(716) : warning C4258: 'tile' : definition from the for loop is ignored; the definition from the enclosing scope is used
4> ..\src\copy_paste.cpp(697) : definition of 'tile' ignored
4> ..\src\copy_paste.cpp(514) : definition of 'tile' used
4>command_queue.cpp

with r19600, but works just fine. no crashes untill now
The rest is confetti!
wtfspiff
Engineer
Engineer
Posts: 8
Joined: 15 May 2009 18:29

Re: Chill's patchpak v5_1

Post by wtfspiff »

ColdIce

any chance for the new binary?
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2852
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Chill's patchpak v5_1

Post by ChillCore »

wtfspiff wrote: ColdIce

any chance for the new binary?
May as well be a against a newer trunk revision then.
I am still testing a few things and adding some, there will be a newer version soon ...

Added:
Copy_paste: http://www.tt-forums.net/viewtopic.php? ... 59&start=0

Updated:
- Progsigs to r19677
- Moreheightlevels to v25_2_r19692
- Cargodist to r19733

Needed grf
- copypaste.grf in the data folder NOT in the newgrf folder
get it here: http://www.tt-forums.net/viewtopic.php?p=440743#p440743

New files:
In the src folder:
command_queue.h
command_queue.cpp
copy_paste.h
copy_patste_gui.cpp
copy_paste

in the docs folder:
copy_paste_array.txt



Copypaste has some issues.
First post will be updated with the next version.
Attachments
chipp_v6_r19736.diff
(932.16 KiB) Downloaded 336 times
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
User avatar
ColdIce
Transport Coordinator
Transport Coordinator
Posts: 314
Joined: 25 Apr 2006 10:22
Location: Bucharest

Re: Chill's patchpak v5_1

Post by ColdIce »

:bow: Thank you ChillCore!

I was playing r 19600 :D

I will come back with an edit to tell you if save game r19600 is compatible with this one. :!: LE: NO. r19736 doesnt support r19600 save game :cry: :!:

here is the WIN32 BUILD.
some warnings http://www.heypasteit.com/clip/JER
Attachments
r19736.rar
(3.63 MiB) Downloaded 459 times
The rest is confetti!
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2852
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Chill's patchpak v5_1

Post by ChillCore »

Thank you for the build ColdIce and for the compiler output.

Those warnings in the copypaste files are the same as before, I think Bilbo is having a look at them.
This is a new one for me:

Code: Select all

4>..\src\newgrf_debug_gui.cpp(627) : warning C4018: '<' : signed/unsigned mismatch
As usual I did not get that warning ...
Would you mind trying to compile a clean build to see if that warning is in trunk or if it is there because of a patch.
Thank you in advance.
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
User avatar
ColdIce
Transport Coordinator
Transport Coordinator
Posts: 314
Joined: 25 Apr 2006 10:22
Location: Bucharest

Re: Chill's patchpak v5_1

Post by ColdIce »

you`re right.. the problem is in trunk

clean r19736, I still get this

4>network_chat_gui.cpp
4>..\src\newgrf_debug_gui.cpp(627) : warning C4018: '<' : signed/unsigned mismatch
4>music_gui.cpp

build log
http://www.heypasteit.com/clip/JES
The rest is confetti!
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2852
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Chill's patchpak v5_1

Post by ChillCore »

That was fast. :)
Thank you for the effort.
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
wtfspiff
Engineer
Engineer
Posts: 8
Joined: 15 May 2009 18:29

Re: Chill's patchpak v5_1

Post by wtfspiff »

Thanks a lot ColdIce :bow: and Chill! :bow:
deamonhunter11
Engineer
Engineer
Posts: 56
Joined: 10 Mar 2010 08:23

Re: Chill's patchpak v5_1

Post by deamonhunter11 »

Great patch, Chill.

The only problem is that there is a problem with saving and loading templates.

Below image is not the error. Just me and the copy and paste.
Attachments
me, trying out the copy and paste
me, trying out the copy and paste
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2852
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Chill's patchpak v5_1

Post by ChillCore »

ColdIce wrote: you`re right.. the problem is in trunk

clean r19736, I still get this
The warning should be gone in 19738.
Thank you Rubidium.
wtfspiff wrote: Thanks a lot ColdIce :bow: and Chill! :bow:
Enjoy.
deamonhunter11 wrote: The only problem is that there is a problem with saving and loading templates.

Below image is not the error. Just me and the copy and paste.
Sometimes it works sometimes it doesn't. I do not yet know what triggers the failing on pasting the loaded template.
If I keep the template rather small it seems to work.

There are a few more problems ...
- My stations are not copypasted.(Waypoints was a known issue.)
- When using NuTracks the pasted rail is converted to the type that is currently selected.
- Waterfeatures were not copypasted the last time I tried.

But I have not yet tested everything with the latest version and I do have quite some grfs installed.
To be continued ...
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
deamonhunter11
Engineer
Engineer
Posts: 56
Joined: 10 Mar 2010 08:23

Re: Chill's patchpak v5_1

Post by deamonhunter11 »

I have hardly any newgrfs turned on as I have got a new computer. Does the same problem come up when the copy and paste patch is by itself?

Just seeing if it happens with my version.
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 17 guests