IRC logs for #openttd on OFTC at 2025-01-07
β΄ go to previous day
01:11:28 <peter1139> Hmm, maybe the EncodedString stuff is getting in the way after all.
02:38:17 *** gelignite has quit IRC (Quit: Stay safe!)
03:12:21 *** gnu_jj_ has joined #openttd
03:15:51 *** gnu_jj has quit IRC (Ping timeout: 480 seconds)
03:20:56 *** Wormnest has quit IRC (Quit: Leaving)
03:21:09 *** debdog has quit IRC (Ping timeout: 480 seconds)
03:46:48 *** Flygon has quit IRC (Read error: Connection reset by peer)
03:59:23 *** D-HUND is now known as debdog
04:41:46 <DorpsGek> - Update: Translations from eints (by translators)
05:37:27 <pickpacket> Rubidium: How do I make sure the event is sent to the company that is renamed?
06:05:19 *** keikoz has quit IRC (Ping timeout: 480 seconds)
06:19:08 *** Extrems` has joined #openttd
06:22:05 *** Extrems has quit IRC (Ping timeout: 480 seconds)
06:22:05 *** Extrems` is now known as Extrems
06:46:25 *** Extrems has quit IRC (Remote host closed the connection)
06:46:28 *** Extrems has joined #openttd
07:36:24 *** nielsm has quit IRC (Ping timeout: 480 seconds)
07:56:57 <merni> Wow, 13285 must've been a huge amount of work
08:30:52 <locosage> parallel sounds as if it's multithreaded but looks like it isn't
08:42:51 *** gelignite has joined #openttd
09:42:27 <LordAro> it is a bit misleading
09:42:34 <LordAro> but apparently it *can* be used multithreaded
10:07:27 *** gelignite has quit IRC (Quit: Stay safe!)
10:37:11 *** gelignite has joined #openttd
10:51:56 <andythenorth> probably 80% of the 10k trains in Horse are just custom colour variants of wagons
10:52:14 <andythenorth> if there could be a custom wagon colour per train...or per group?
10:52:19 <andythenorth> delete 8000 vehicles?
10:52:36 <andythenorth> I'd want a custom recolour option though π
10:52:46 <andythenorth> user-settable badge?
10:53:12 <peter1139> A bit like cargo subtypes?
11:06:06 <xarick> I'd like to test it but I don't know how to import 3rd party projects
11:07:07 <LordAro> stick it somewhere in src/3rdparty and include it
11:07:24 <LordAro> it's header only, so should just be able to do #include "foo/bar/phmap.h"
11:10:08 <peter1139> locosage, What. Have. You. Done.
11:16:51 <xarick> iron horse makes my AI sad
11:17:37 <xarick> list of available engines is absurdly high
11:18:59 <xarick> AI is like... calculating the best one out of them. This is expected to be a fast operation.
11:19:12 <xarick> but not when the pool has 10k engines or so
11:20:50 <xarick> and you're saying they're just variants?
11:21:10 <xarick> same sizes, same cargo limits, costs, etc?
11:24:49 <xarick> same reliability, age, etc... the only difference is colours?
11:29:27 <peter1139> More often than not.
11:29:52 <peter1139> "Things you should've thought about."
11:31:19 <andythenorth> for a set which is explicitly designed to try and eliminate "best"
11:31:26 <andythenorth> GL to your economic min-maxing AI
11:49:35 <pickpacket> tt-forums just died
11:50:57 <pickpacket> xarick, andythenorth: fastest is always best. Breakdowns set to None and long train lines. Done
11:51:14 <pickpacket> kuhnovic: works again now!
11:51:36 <pickpacket> ah, I do believe it must have restarted. I was logged out again
11:57:47 <xarick> strange, `IsValidTile(t)` is faster than `!IsTileType(t, MP_VOID)`
11:58:46 <xarick> i better rebase both build to the same version
12:06:11 <xarick> IsValidTile(t) also does a !IsTileType, i just don't get it
12:23:24 <Artea> is "-D" command use with [] between IP and Port ?
12:25:11 <Artea> I removed -f from .sh file
12:25:21 <Artea> and seems detects all my IPs
12:25:45 <Artea> does twice 0.0.0.0:3969
12:26:07 <Artea> and works with other IP even if is -D IP:3969
12:27:09 <Artea> also in Detected broadcast addresses, only IPv4 shows up, regardless have at least 1 IPv6
12:40:45 <LordAro> [] should only be necessary for ip6 addresses
12:51:19 <peter1139> Hmm, NewsSubtype maybe.
13:24:34 <Artea> srv.cfg have same info of private.cfg and if not present, server gets "Unnamed Server"
13:38:10 <peter1139> Since the split to separate private and secrets config, the sections that appear in those files must be in those files.
13:39:08 <peter1139> This has been the case for the last 3 major releases.
13:39:43 <Artea> which makes dedicated servers harder to setup, in my opinion
13:40:21 <Artea> makes sense in "run ottd"
13:40:34 <Artea> in case of setup multi-servers, not so much
13:41:01 <Artea> for the fact that private.cfg doesn't even can be called via command
13:41:14 <Artea> and most of server info is on openttd.cfg
13:41:32 <peter1139> It's a configuration file, not a script to be called.
13:41:40 <LordAro> safer/more secure? yes
13:41:55 <Artea> you know what I have on private.cfg ?
13:42:04 <peter1139> Just use a separate directory for each server instance. Then they won't trample over each others temporary network files and autosaves either.
13:42:41 <Artea> client_name and server_name
13:43:33 <Artea> "connect_to_ip = ", "last_joined = ", "use_relay_service = no", "participate_survey = no"
13:44:34 <Artea> so in my prespective, why I have to have a private.cfg where all the important info for server is on srv.cfg ?
13:48:01 <Artea> "separate directory for each server instance" - easier make a bash script doing mv for each private.cfg for each server
13:49:05 <peter1139> You could do that but it's not going to work very well.
13:52:48 <peter1139> Fighting the design isn't going to help you.
14:02:37 <Artea> well, wouldn't hurt me to try
14:02:59 <peter1139> It will. secrets.cfg also needs to be per-instance.
14:05:20 <Artea> even with "reload_cfg = off" ?
14:05:28 <Artea> or that is just for openttd.cfg ?
14:07:16 <Artea> at least "-c <conf>" could handle more, like "-c srv.cfg srv.private srv.secret"
14:07:49 <Artea> is kinda frustating because I don't wanna have more than 1 directory of the game on my VPS
14:08:23 <Artea> I would for multi-version for testing purposes
14:08:49 <Artea> same version to run 2 diff servers, not my suit for it
14:08:57 <_glx_> `-c` sets the config dir
14:09:41 <_glx_> so it will search private and secret relative to the passed cfg
14:10:14 <Artea> it says on help: "-c config_file = use 'config_file' instead of 'openttd.cfg' "
14:11:17 <Artea> and writing secret.cfg, can't be 'avoided' using -x ?
14:11:38 <_glx_> and you need 1 secret per instance because it stores invite code
14:13:00 <_glx_> `-c` also implies autosaves and stuff will be relative to config
14:13:13 <Artea> together with server password, rcon password and default company password
14:14:12 <peter1139> `openttd@games:~$ ./openttd-15.0-beta1-linux-generic-amd64/openttd -D -c ~/openttd-s1/openttd.cfg`
14:14:35 <Artea> from dedicated server, not so much
14:15:23 <_glx_> and it this case, `~/openttd-s1` will have the 3 config files, and the usual folders
14:16:05 *** kuka_lie has joined #openttd
14:17:28 <_glx_> of course all instances can share newgrf, AI and GS if they are in the common place
14:19:56 <peter1139> And having it outside the openttd binary directory makes switching versions much more robust.
14:20:55 <Artea> srv1/ with srv1.cfg private.cfg and secrets.cfg and srv2/
14:21:08 <Artea> with a srv.sh calling both
14:22:34 *** gelignite has quit IRC (Quit: Stay safe!)
14:24:58 <Artea> well, both show up in listserver
14:30:04 <xarick> openttd exe suddenly increased ~100kb
14:31:05 <peter1139> Compile with -Os (or ever MSVC's equivalent is) if you care about binary size.
14:33:02 <peter1139> "Brings consistency across workflows"
14:33:30 <peter1139> I could look at catcodec again. Last time I go distracted and ended up C++ifying some more of it.
15:09:07 <Rubidium> pickpacket: technically you could try to figure out how to get the new result.txt, but in my PR I just updated result.txt manually as that was simpler. With regression I know the event is sent to the company that is renamed, because 'regression' is a company renaming itself. If you don't get the event, then it has been filtered out (or it isn't created at all)
15:33:37 <_glx_> Rubidium: when regression fails the output is kept in build dir as `regression_<test>_output.txt` so it's easy to overwrite `regression/<test>/result.txt`
15:37:02 <xarick> the average winner is openttd MakeLake.exe, which is the one with IsTileFlat, the PR
15:37:51 <xarick> it makes no sense for me
15:37:52 <_glx_> ah yes, numbers without any context
15:39:38 <Rubidium> peter1139: maybe not necessarily a NewsSubType, but rather make NewsType list just all news messages (maybe even in the same order in english.txt and not passing a StringID at all), and make the current NewsType a NewsClass with a simple mapping from NewsType to NewsClass.
15:40:22 <Rubidium> maybe even a lookup table for type -> flags?
15:41:28 <peter1139> + saveload conversion.
15:41:29 <Rubidium> maybe even replace ref1/ref2 with std::variant<Station*, Vehicle*, Industry*, Town*, Engine*, TileIndex>?
15:41:38 <peter1139> Wait, news messages aren't saved.
15:42:13 <peter1139> Okay, so before everything, revamp news.
15:44:46 <Rubidium> are there any 'AddNews' calls with SetDParam that aren't ref1/ref2?
15:45:56 <Rubidium> hmm, yes... so it won't immediately solve the SetDParam issue :(
15:57:59 <peter1139> Ah the old expansion practice.
15:59:11 <peter1139> The simple task of "allowing sandbox placing of town buildings" turns into "changing OpenTTD into a direct city-building game where placing houses costs money and is part of the gameplay"
16:01:50 <andythenorth> it just makes me want to rage quit π
16:01:59 <andythenorth> I should be a better person, it's not even my PR
16:02:46 <talltyler> I donβt mind houses costing money, I just have no desire to implement that myself. π
16:06:32 <andythenorth> I hate lectures about 'please think of others' from people who seem to lack theory of mind
16:07:10 <peter1139> It's not really possible to balance it, because you can just plop lots of houses down and then reap the rewards of lots of passengers to transport.
16:07:25 <peter1139> Of course that's kinda already the case without placing houses yourself.
16:09:32 <andythenorth> no it must be economic
16:09:45 <andythenorth> I will make a giant 4k map savegame to prove it
16:13:38 <peter1139> You're right, what does it matter.
16:16:26 <peter1139> Is building more expensive than demolishing?
16:16:39 <andythenorth> depends how much asbestos is in the building
16:16:43 <andythenorth> we should consider that
16:16:54 <andythenorth> and if it's built on a pet semetary or anything
16:17:11 <peter1139> If it costs money to build, should it even be a sandbox setting?
16:17:22 <peter1139> Should magic-bulldozer cost money to use?
16:17:28 <peter1139> How much does it cost to destroy an industry?
16:17:51 <andythenorth> it costs an arbitrary amount in grf
16:18:03 <andythenorth> it will probably need a base cost amount too
16:18:17 <andythenorth> and we need to think about the implications of wallclock on the costs
16:28:26 <talltyler> The moment Infinite Money was added, I turned on the setting and havenβt touched it since
16:28:48 <andythenorth> that's unbalanced, won't you think of the poor starving donkeys?
16:28:55 <andythenorth> or the sad kittens?
16:28:57 <kuka_lie> talltyler: there is infinite money? how to get it?
16:29:06 <talltyler> I will not, you canβt make it π
16:29:28 <_glx_> sandbox window most likely
16:29:29 <peter1139> It's in the secret setting called "infinite money"
16:29:30 <talltyler> Search for βinfinite moneyβ in Settings, itβs new in 14
16:32:16 <kuka_lie> i used to open cheat menu and put some money to my company
16:33:40 <kuka_lie> i miss that feature of baying other companys stocks
16:35:04 <kuka_lie> it was really fun when i played with my friends and we had a competition of company value
16:47:33 <LordAro> i mean, company value graphs haven't gone anywhere
16:51:02 <xarick> infinite money for multiplayer works?
16:52:54 <kuka_lie> LordAro: but i cant bay stocks
16:56:45 <kuka_lie> _glx_: i talked about this in openttd discord and them told that its removed
16:57:09 <_glx_> I was talking about infinite money
16:57:22 <_glx_> stocks have been removed, they didn't work
17:01:53 <kuka_lie> hmm is c++ hard? should i make a new stock selling system? i have never writed c/c++
17:03:15 <kuhnovic> It's not C++ that's hard here, it's designing a decent stock system that actually works well
17:03:51 <kuhnovic> (And C++ is also quite hard if you have never written code before π)
17:07:46 <xarick> these results are strange π¦
17:08:50 <xarick> so, checking for the tileset first actually loses
17:11:09 *** Wormnest has joined #openttd
17:12:09 <Rubidium> xarick: have you checked with assertions disabled?
17:14:08 <xarick> `if (_settings_game.game_creation.landscape == LT_TROPIC && GetTropicZone(tile) == TROPICZONE_DESERT)`
17:17:26 <kuka_lie> kuhnovic: like is that stock math hard? $Company1ValueWithStocks = $company1value + $stockvaluecompany1; $stockvaluecompany1 = $company2value*companyowningscompany2bycompany1 + $company3value...
17:21:00 <xarick> I could actually exclude the LT_TROPIC check
17:21:36 <xarick> GetTropicZone return TROPICZONE_NORMAL for the other tilesets
17:22:21 <xarick> and there's no assert on GetTropicZone for the landscape
17:25:34 <xarick> not sure I wanna do it π
17:26:02 <LordAro> kuka_lie: you'd be surprised
17:26:50 <kuka_lie> LordAro: lets try it at first in exel
17:28:23 <LordAro> seriously, read some of the context before wasting any time on it
17:31:18 <kuka_lie> should i try to learn c by writing stock trade game
17:31:48 <kuka_lie> or new ui for gnushess or fics
17:40:23 <xarick> i found an ugly code style
17:40:49 <xarick> in tree_cmd.cpp line 850
17:52:20 <_glx_> `operator,` can be useful
17:55:07 <xarick> it's safe to remove the tileset check
17:55:18 <xarick> more performance maybe
17:56:00 <xarick> I was checking where GetTropicZone was being used
17:56:19 <xarick> LT_TROPIC sometimes isn't enforced
17:56:46 <_glx_> tileset check is faster, it skips the GetTropicZone call
17:57:41 <_glx_> in `a && b` b is not evaluated if a is false
17:58:17 <_glx_> and with `a || b` it skips b if a is true
18:13:08 <xarick> you're right, slightly less performance π¦
18:15:00 <xarick> IsTileFlat vs TileHeight
18:18:55 <xarick> if the height matches, IsTileFlat is run, 5 corners computed
18:20:07 <xarick> if height doesn't match, return false, 1 corner computed
18:21:27 <xarick> solo IsTileFlat: min 2 corners computed to return false
18:22:15 <xarick> IsTileFlat is true, 4 corners computed + equality test
18:23:50 <xarick> well i like them, my bad
18:24:28 <xarick> I need to do something dumb
18:25:25 <xarick> iterate full map benchmarking the 2 MakeLakes
18:25:45 <xarick> i need a conclusive result
18:36:28 *** gelignite has joined #openttd
18:47:17 *** ChanServ sets mode: +v tokai
18:50:14 <xarick> gonna test the GetTropicZone too
18:53:58 *** tokai|noir has quit IRC (Ping timeout: 480 seconds)
19:03:40 *** benjaminv has quit IRC (Quit: Gateway shutdown)
19:46:09 <Rubidium> peter1139: there's at least 70+ variants of news. Mostly trivial, but for accidents/arrival you got a distinction between "ours" and "others" and potentially multiple variants per vehicle type (e.g. there would be 8 news types for the arrivals of road vehicles alone). Not to mention that industries provide their own news strings making getting away from news strings so much less elegant. So in the end I
19:46:15 <Rubidium> think a NewsType might not be such a good idea, and a sub type might be better suited. After all, the sub type only seem to be needed for the advices, so it's fairly limited
19:47:56 <peter1139> Yeah, it's NT_ADVICE only.
20:27:52 <pickpacket> What's the difference between Owner and CompanyID in GS?
20:29:14 <pickpacket> Rubidium: I'm changing my event to include the new name in the event, like you do with the new manager name. I figure that there's a possible race condition otherwise between getting the rename event and fetching the name from the company
20:31:30 <truebrain> _glx_: the more I look at it, the more sems/feels wrong π
20:31:37 <truebrain> the screenshot you report, skipped `Testing / Testing / ...`
20:31:46 <truebrain> but the `Required` is on `Testing / Annotation ...`
20:32:01 <truebrain> There is a `Testing /` missing there π
20:32:31 *** kuka_lie has quit IRC (Remote host closed the connection)
20:32:32 <_glx_> it skipped annotation check because `needs` saw a failing result
20:32:33 <truebrain> I had that before with GitHub
20:32:42 <peter1139> Looking at some code gen and it's not nice :S
20:32:44 <truebrain> yes yes, but I wonder if you PR solves your screenshot π
20:33:07 <truebrain> or if GitHub is just presenting it broken (again) π
20:33:45 <pickpacket> One uses Owner and the other uses CompanyID. What's the practical difference? Which is preferred?
20:34:03 <_glx_> could be because it's reusable workflow inside a reusable workflow
20:34:19 <truebrain> Possibly the `Required` got never updated
20:34:24 <truebrain> as OpenGFX is a very old repo
20:34:46 <_glx_> that's also possible π
20:34:55 <truebrain> doesn't mean your PR isn't a good idea btw
20:35:03 <truebrain> there is just a lot of things that feels misaligned π
20:35:44 <truebrain> yeah, pretty sure it should be `Testing / Testing / ...` .. at least, that makes much more sense π
20:36:15 <_glx_> and it's using the same workflow
20:36:19 <truebrain> There too it reads `Testing / Testing / ...` π
20:36:42 <truebrain> so that means the Required tag for sure is wrong π But okay, you will figure that out when we handled this PR π
20:36:59 <truebrain> bit annoying that `if` inside a `uses` is not evaluated earlier
20:37:02 <truebrain> I guess it makes sense
20:37:20 <_glx_> oh indeed opengfx has the wrong required
20:37:24 <truebrain> luckily, only 3 other repos use the `rw-annotation-check`, so it is easy to fix π
20:38:01 <truebrain> _glx_: I think if you fix that Required, the results makes a bit more sense at least. As it shouldn't be pending π
20:40:42 <truebrain> I really wonder why those `rw-`s execute the `rw-annotation-check`, and not the annotation check directly .. I think it is because I assumed the `if` would be evaluated
20:42:00 <_glx_> of course I need a run without skipped annotation check to be able to add the rule
20:42:55 <truebrain> OpenTTD itself calls the `annotation-check` directly, not via a `uses` π
20:43:11 <truebrain> as do a bunch of other repos
20:43:14 <truebrain> we are so inconsistent! π
20:43:19 <_glx_> yes they follow the doc
20:43:39 <truebrain> the doc offers both
20:43:45 <truebrain> so there currently is no wrong or right π
20:43:59 <truebrain> but I think we should just remove the `rw-annotation-check`, now I am looking at it a bit more
20:45:49 <truebrain> as in, not remove it in this PR, remove its uses first π
20:46:02 <truebrain> but just switch to using the annotation-check itself directly
20:46:33 <_glx_> yeah "copy" the job instead of using another workflow
20:46:52 <truebrain> as the other workflow is very tiny, and it doesn't actually solve the problem it suggests to solve π
20:48:58 <truebrain> left my summary in the comment too, just for future reference π
20:49:48 <truebrain> would mean we also need to fix the Required flag on all Python repos, but okay; if that also means we can drop the Required flag on all the other jobs, that would be an overall win π
20:57:50 <_glx_> and I'll trigger a release with the recent commits
21:07:42 <_glx_> so rerun failed jobs doesn't use the updated version, but rerun all did
21:08:48 <truebrain> as they should π
21:10:33 <_glx_> gimp steps are slooooow
21:36:48 <talltyler> Doing some goofy shit again
21:40:55 <kuhnovic> I kinda like it! "Island mode"
21:42:19 <kuhnovic> What happens when you terraform at the edge of the map? Will it look weird?
21:42:58 <_glx_> description says it's disabled
21:48:44 <kuhnovic> I confess that I did a TL;DR
21:55:55 <truebrain> also: in before someone complaints they can no longer raise tiles on border in this situation π
21:55:58 <truebrain> THERE WILL BE PITCHFORKS! π
21:57:33 <andythenorth> free pitchfork with every download
21:57:42 <andythenorth> think of the game balance though
22:00:43 <talltyler> Yeah, it's a weird enum, and `BORDERS_RANDOM = 16,` is already wrong, since that's not a bit π
22:01:07 <talltyler> If anything, it should be `BORDERS_RANDOM = 4`
22:01:58 <talltyler> I will try your bitshifting suggestion -- my grasp of bit math isn't quite advanced to come up with that on my own π
22:01:58 <andythenorth> what do infinite water tiles cost to clear?
22:02:08 <talltyler> andythenorth: Infinite money, duh
22:02:09 <andythenorth> and has xarick optimised them yet? π
22:02:18 <andythenorth> countable infinite, or uncountable?
22:02:24 <_zephyris> Ooh, it'd be fun to have sea borders properly supported, I often use a static grf for that π
22:02:53 <talltyler> Okay, I'll need to handle terraformed void tiles then π
22:03:02 <talltyler> (raised the land, then lowered it again)
22:03:18 <andythenorth> can we have animated porpoises?
22:03:22 <andythenorth> infinite numbers, but random?
22:03:26 <truebrain> talltyler: I think it would make this PR even more awesome π
22:03:26 <andythenorth> random infinite?
22:03:53 <truebrain> talltyler: But, it is one devs opinion, so maybe others feel different π
22:05:19 <truebrain> News post suggestion: the seas are endless now
22:08:17 *** Wolf01 has quit IRC (Quit: Once again the world is quick to bury me.)
22:10:51 <xarick> I want infinite land too
22:14:59 <truebrain> Dorpsgek also needs an update it seems π
22:15:20 <xarick> how would aircraft shadows work on the water?
22:24:00 <andythenorth> hmm we have 'clone train', could we have 'clone train vehicle'? π
22:26:59 <_glx_> yeah I know, empty description, but the title should be enough
22:28:14 <truebrain> _glx_: It does π
22:29:59 <_zephyris> talltyler: How horrible would it be to add a new sprite for off-the-edge-of-the-map water tiles? I'm imagining a sprite which maybe lacks the bright sparkle pixels, or has a dithered shading effect to make it a little darker.
22:30:25 <_zephyris> So you can have infinite water, but can still subtly see which tiles are in bounds.
22:30:56 <peter1139> andythenorth, what's a "train vehicle"?
22:31:05 <truebrain> _zephyris: Cool idea π
22:31:15 <andythenorth> peter1139: individual engine or wagon
22:32:41 <talltyler> _zephyris: I like the idea, care to draw me such a sprite? π
22:34:53 <peter1139> Normal water sprite but with 32bpp shading, like slopes?
22:39:37 <_zephyris> talltyler: Absolutely, just not right now, sleep calls to me!
22:40:39 *** keikoz has quit IRC (Ping timeout: 480 seconds)
22:42:52 <xarick> there's free form edges too
22:45:16 <xarick> am I missing something, why start at y = 1 ?
22:46:38 <talltyler> The corners have already been checked, same reason it's `y < Map::SizeY()` and not `<=`
22:47:04 <talltyler> _zephyris: Awesome, thanks. I put a note in the PR description so I don't forget! β€οΈ
22:48:44 <_zephyris> Awesome. Not that it by any means vital, just makes the idea that bit nicer.
22:49:55 <_zephyris> I'm getting a funny deja vu, I'm sure I played with this idea in early opengfx1, replacing the black tile waaay before freedom map edges was a thing.
22:51:04 <peter1139> I think that was possible yeah.
22:51:24 <xarick> ah, now that makes sense with the new update
22:53:13 <xarick> with freeform_edges, a tile outside the map would be tile -1, -1
22:57:39 <reldred> Weβve had it in JGRPP for a lil while now. Personally Iβm not sure Iβm keen on having the water look different at the map edge but eh
22:58:28 <xarick> heh TileHeightOutsideMap just clamps it to coordinates inside the map
22:58:45 <truebrain> reldred: Has to be subtle, but that might make it even better π
22:59:19 <xarick> so basically CheckBorders is just checking Slopes of the void tiles
23:00:01 <xarick> those tiles are part of the map
23:03:03 <talltyler> It asserts without that change π
23:03:30 <xarick> oh, GetTileSlope requires valid tile I forgot
23:04:53 <xarick> nope, not even that, I need to check myself
23:16:02 <xarick> i understand now. GetTilePixelSlopeOutsideMap is the only safe option
23:16:57 <xarick> let me experiment GetTileSlopeZ
23:18:27 <xarick> oh, damn, it wants TileIndex, alright
23:18:56 <xarick> yeah, sorry for the mess
23:20:08 <xarick> I'd still change the Map::SizeX(), Map::SizeY() to Map::MaxX(), Map::MaxY() since it's gonna clamp to those anyway
23:22:33 <ufiby> talltyler: This is great, but I'm afraid beginners complain that ships don't sail further if terraforming reaches the edge of the map.
23:24:35 <xarick> but I worry about aircraft shadows over that water
23:31:47 <xarick> talltyler: something like this:
23:31:47 <xarick> ``` /* Check the map corners. */
23:31:47 <xarick> if (!check_tile(0, 0, SLOPE_S)) return false;
23:31:47 <xarick> if (!check_tile(0, Map::MaxY(), SLOPE_W)) return false;
23:31:47 <xarick> if (!check_tile(Map::MaxX(), 0, SLOPE_E)) return false;
23:31:48 <xarick> if (!check_tile(Map::MaxX(), Map::MaxY(), SLOPE_N)) return false;
23:31:48 <xarick> /* Check the map edges.*/
23:31:50 <xarick> for (uint x = 1; x < Map::MaxX(); x++) {
23:31:50 <xarick> if (!check_tile(x, 0, SLOPE_SE)) return false;
23:31:52 <xarick> if (!check_tile(x, Map::MaxY() - 1, SLOPE_NW)) return false;
23:31:54 <xarick> for (uint y = 1; y < Map::MaxY(); y++) {
23:31:54 <xarick> if (!check_tile(0, y, SLOPE_SW)) return false;
23:31:56 <xarick> if (!check_tile(Map::MaxX() - 1, y, SLOPE_NE)) return false;
23:32:43 <xarick> nah, there's still something off there...
23:34:18 *** nielsm has quit IRC (Ping timeout: 480 seconds)
23:35:55 *** gelignite has quit IRC (Quit: Stay safe!)
continue to next day β΅