code logs -> 2016 -> Tue, 22 Nov 2016< code.20161121.log - code.20161123.log >
--- Log opened Tue Nov 22 00:00:48 2016
00:13 himi [sjjf@Nightstar-dm0.2ni.203.150.IP] has joined #code
00:13 mode/#code [+o himi] by ChanServ
00:21 Kindamoody is now known as Kindamoody[zZz]
00:46 Derakon[AFK] is now known as Derakon
02:20 Vash [Vash@Nightstar-uhn82m.ct.comcast.net] has joined #code
03:15
<@celticminstrel>
My code is heavily bound to a specific map size. I don't think I can readily unbind it. Oh well.
03:25
<~Vornicus>
celmin: another pair of eyes may help
03:26
<@celticminstrel>
I suppose it could.
03:26
<@celticminstrel>
The thing is, the areas are mapped onto a rectangular prism, and I was unable to think of a general way of doing the ends.
03:27
<@celticminstrel>
Okay, so if I'm going to show it off I have to decide between opening a git or throwing it in a pastebin...
03:27
<@celticminstrel>
s/git/github/
03:27
<@celticminstrel>
I probably would've eventually anyway, but not until I had something that could be described as playable.
03:29
<&ToxicFrog>
You should be using some sort of version control anyways, which makes putting it on github/bitbucket/etc easy
03:29
<@celticminstrel>
Yeah, I just made the initial commit in git a few minutes ago.
03:30
<@celticminstrel>
I forget if you can rename github repositories.
03:30
<&ToxicFrog>
I think s
03:30
<&ToxicFrog>
*so
03:30
<@celticminstrel>
Okay yeah, looks like it.
03:31
<@celticminstrel>
Because this project is currently nameless, so if I put it there I'd have to rename it once I came up with a name.
03:31 * Vornicus is bad at version control partly because he tends to be in places where even his smoke tests are red for long periods of time
03:32 * celticminstrel isn't super-worried about it being bound to a specific size, but that does make it harder if I decide to make the map bigger at some point.
03:34
<@celticminstrel>
So here you go: https://github.com/CelticMinstrel/wip-roguelike/blob/master/panels/Map.js
03:34
<@celticminstrel>
The border stuff, mainly in Map().
03:34
<~Vornicus>
oh wild.
03:34
<@celticminstrel>
The number of regions is hard-coded and not easy to change.
03:35
<@celticminstrel>
Wild huh.
03:36
<~Vornicus>
I thought, when you said "rectangular prism", you meant the inside of such a thing, not the *surface*
03:37
<@celticminstrel>
Heh...
03:38
<~Vornicus>
Now *this* is my neighborhood.
03:39
<&Derakon>
A roguelike where you can walk on the walls and ceilings and the procgen is in all three dimensions.
03:39
<~Vornicus>
Typically the way I see this type of thing done is *three* coordinates - one tells you what zone you're in, and the other two coordinates tell you where in that zone you are.
03:40
<@celticminstrel>
Not quite like that, Derakon.
03:40
<~Vornicus>
Your global topology is then set by which zone edges align with which, in what directions
03:41
<&Derakon>
CM: no, that was random neuron firings
03:41
<@celticminstrel>
Vornicus: So basically you wouldn't make any attempt to make the zones' arrangement in memory reflective of the topology.
03:41
<@celticminstrel>
?
03:41
<@celticminstrel>
Derakon: Fair enough. :p
03:42
<~Vornicus>
celmin: nope. Way easier to have six or twelve or twenty or what-have-you square arrays.
03:46
<@celticminstrel>
But is there a general way to set up the zone edges?
03:46
<@celticminstrel>
Or would it just have to be done manually for whatever size you choose?
03:48
<@celticminstrel>
I don't think my code is heavily dependent on the fact that zones are currently addressed by two coordinates.
03:48
<~Vornicus>
You can have a data table that handles it - basically you can say -- for side 2, if you go off the high y side, you end up on side 0, on the low x side, with reversed coordinate
03:48
<@celticminstrel>
But that data table would still need to be tailored for your chosen size?
03:49
<~Vornicus>
For your chosen topology but not for your chosen size
03:49
<@celticminstrel>
Hmm...
03:49
<~Vornicus>
So if you decide to have, for instance, a cube shape, you can hard code that, and then a cube of *any* size will work.
03:50
<@celticminstrel>
I have more of a pillar than a cube.
03:51
<~Vornicus>
Still possible. A little more annoying
03:51
<&Derakon>
Oh, today I accidentally wrote "temfile" instead of "tempfile".
03:51
<&Derakon>
And got distracted for a bit by thinking about Undertale.
03:51
<&Derakon>
Temmie should probably not code.
03:52
<~Vornicus>
But you can plop that in the setup & motion table too - what your sizing DOFs are.
03:53
<~Vornicus>
(I wonder what they are for a rhombic dodecahedron...)
03:53
<@celticminstrel>
DOF?
03:53
<~Vornicus>
Degrees of Freedom
03:54
<~Vornicus>
Different topologies will have different degrees of freedom because you're forced to have the opposite edges of each face have the same number of cells.
03:58 * celticminstrel nod...
03:58
<~Vornicus>
So in a cube you have three degrees of freedom - there are three different tuneable dimensions.
04:00
<~Vornicus>
(yours are set to 2,2,8)
04:00
<@celticminstrel>
...wait, what about the 10?
04:00
<@celticminstrel>
Shouldn't it be 2,2,10?
04:00
<~Vornicus>
sorry, 2,2,10
04:01
<@celticminstrel>
Since the 8 is dependent on the 2,2.
04:01
<~Vornicus>
I wasn't looking at it when I spoke
04:01
<@celticminstrel>
Fair enough
04:01
<~Vornicus>
ah, rd has 3 as well.
04:03
<~Vornicus>
rt has 5, looks like
04:04
<@celticminstrel>
rt?
04:04
<~Vornicus>
rhombic triacontahedron
04:05
<~Vornicus>
oh, no, six.
04:06
<@celticminstrel>
So I guess one step in making it general would be figuring out how to calculate the 8 from the 2,2...
04:06
<@celticminstrel>
Though I might not need the 8 when building it up.
04:06
<@celticminstrel>
But it'll probably be needed somewhere for something.
04:07
<~Vornicus>
and I can't add either on the rd, it's 4 there
04:07
<~Vornicus>
(rhombic dodecahedron)
04:08
<@celticminstrel>
Yeah, I got that one since you mentioned it earlier.
04:11
<~Vornicus>
there's way more of these than I expected actually. I'd forgotten about the dyakis dodecahedron (which actually has 24 sides) for instance.
04:13 macdjord|wurk is now known as macdjord
04:14
<~Vornicus>
...which appears at first blush to have also 6 DOF in this sense, and even better there's pairs of such that don't intersect.
04:15
<~Vornicus>
...and is actually topologically equivalent to a deltoidal icositetrahedron, which itself is best represented by a *cube* because of the way the 3- and 4-corner points
04:17
<~Vornicus>
(welcome to one of my long-time interests)
04:18
<@celticminstrel>
Heh.
04:18 * celticminstrel is currently adding more named constants for readability and stuff.
04:25
<@celticminstrel>
I think I'm starting to see how to make all those assignments as a loop instead of a hard-coded block... not going to do it quite yet though.
04:30
<@celticminstrel>
Uh, I forget... x+h*y or x+w*y...?
04:32
<~Vornicus>
x + w*y
04:42 * Derakon hacks at Lua for about half an hour before running out of brain.
04:42
<&Derakon>
Maybe 50/50 not being used to Lua and not having much in the way of brain reserves.
04:56 Vash [Vash@Nightstar-uhn82m.ct.comcast.net] has quit [Connection closed]
05:02 Derakon is now known as Derakon[AFK]
05:52
<@celticminstrel>
My "converge" coordinate transformation is not working.
05:53
<@celticminstrel>
Or to be more precise, it's working for the north but not for the south.
05:53
<@celticminstrel>
In the south the transformed coordinate is (SIZE-x-1,SIZE-y-1), where (x,y) is what it should be.
05:58
<@celticminstrel>
I guess I can just have different transform functions for this case...
06:06
<~Vornicus>
this is still the thing where you're laying it out in an array?
06:07
<@celticminstrel>
Well, it is laid out in an array, yes. I'm not sure that's relevant to this particuar question though.
06:08
<@celticminstrel>
This is the function that transforms an out-of-bounds coordinate in one zone to an in-bounds coordinate in the adjacent zone.
06:08
<@celticminstrel>
Different boundaries use different functions.
06:09
<@celticminstrel>
Specifically it was the two *_converge_bmap functions.
06:09
<@celticminstrel>
I added two additional functions to use for the south pole boundaries, and it seems to work.
06:10
<~Vornicus>
I was wondering if you were still on that or trying my method
06:10
<@celticminstrel>
I haven't done anything about that yet. Maybe tomorrow. Currently working on generating a faux-longitude value.
06:10
<@celticminstrel>
(Already did latitude)
06:12
<@celticminstrel>
Though I might just sleep and do both tomorrow.
06:13
<@celticminstrel>
I've figured out that I need to project an interior point onto the perimeter of a square. No idea how to do that yet.
06:16 himi [sjjf@Nightstar-dm0.2ni.203.150.IP] has quit [Ping timeout: 121 seconds]
06:24 celticminstrel [celticminst@Nightstar-h4m24u.dsl.bell.ca] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!]
08:51 himi [sjjf@Nightstar-v37cpe.internode.on.net] has joined #code
08:51 mode/#code [+o himi] by ChanServ
09:08 himi [sjjf@Nightstar-v37cpe.internode.on.net] has quit [Ping timeout: 121 seconds]
09:17 himi [sjjf@Nightstar-v37cpe.internode.on.net] has joined #code
09:17 mode/#code [+o himi] by ChanServ
09:28 Kindamoody[zZz] is now known as Kindamoody|afk
11:30 Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has quit [Ping timeout: 121 seconds]
13:01 catadroid [catalyst@Nightstar-hl7rfp.dab.02.net] has joined #code
13:05 Emmy-werk [NSkiwiirc@Nightstar-41pbej.static.chello.nl] has joined #code
13:05 mode/#code [+o Emmy-werk] by ChanServ
13:16 Emmy-werk [NSkiwiirc@Nightstar-41pbej.static.chello.nl] has quit [[NS] Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
13:17 Emmy-werk [NSkiwiirc@Nightstar-41pbej.static.chello.nl] has joined #code
13:17 mode/#code [+o Emmy-werk] by ChanServ
14:31 catadroid` [catalyst@Nightstar-qaemkg.dab.02.net] has joined #code
14:32 catadroid [catalyst@Nightstar-hl7rfp.dab.02.net] has quit [Ping timeout: 121 seconds]
15:20 catadroid` is now known as catadroid
15:35 macdjord is now known as macdjord|wurk
--- Log opened Tue Nov 22 17:29:31 2016
17:29 TheWatcher [chris@GlobalOperator.Nightstar.Net] has joined #code
17:29 Irssi: #code: Total of 35 nicks [32 ops, 0 halfops, 0 voices, 3 normal]
17:29 mode/#code [+o TheWatcher] by ChanServ
17:29 Reiver [quassel@Nightstar-ksqup0.co.uk] has joined #code
17:29 mode/#code [+ao Reiver Reiver] by ChanServ
17:30 Irssi: Join to #code was synced in 55 secs
18:34 catadroid [catalyst@Nightstar-qaemkg.dab.02.net] has quit [[NS] Quit: Bye]
19:10 Emmy [Emmy@Nightstar-9p7hb1.direct-adsl.nl] has joined #code
19:10 mode/#code [+o Emmy] by ChanServ
20:27
<&[R]>
<enderst> https://twitter.com/docsmooth/status/800639999364448256
20:27
<&McMartin>
http://gizmodo.com/hedgehog-based-authentication-is-the-only-way-to-be-tru-17892 45671
20:31 Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has joined #code
20:31 mode/#code [+qo Vornicus Vornicus] by ChanServ
20:36
<@celticminstrel>
XD
21:52
<@celticminstrel>
Why does 'git add -N' require the file to exist? :/
21:55
<&[R]>
Because git tracks files
21:56
<@celticminstrel>
But that means I can't 'edit xxx; git add -N xxx'
21:56
<@celticminstrel>
(Since edit doesn't create the file until saved.)
21:57
<&[R]>
Because edit deletes the file after it is done?
21:57
<&[R]>
Or did you mean `edit xxx & git add -N xxx`, which I'm not certain actually works.
21:58
<@celticminstrel>
It doesn't, because this edit just tells TextWrangler to open a document and then returns.
21:58 macdjord|wurk [macdjord@Nightstar-cd2k4t.mc.videotron.ca] has quit [Connection reset by peer]
21:58 macdjord|wurk [macdjord@Nightstar-cd2k4t.mc.videotron.ca] has joined #code
21:58 mode/#code [+o macdjord|wurk] by ChanServ
21:58
<@celticminstrel>
Well, I suppose it would probably still work, but there's no point.
22:00
<&[R]>
Ah
22:00
<&[R]>
Eitherway, I don't think git likes to track things that don't exist yet, so you're best off making your edit shell script touch the file first.
22:01
<@celticminstrel>
It's not a shell-script, though I think it does have a flag to do that. Still annoying.
22:01 Kindamoody|afk is now known as Kindamoody
22:32
<@celticminstrel>
For some reason ROT is inserting an extra space before the prime characters... except it's not really a space because it's simply not rendering anything there at all.
22:33
<&McMartin>
I have just been introduced to the phrase "server-farm-to-database-table"
22:38
<@celticminstrel>
Looks like the problem is ROT treating it as a full-width character. Why would it do that?
22:39
<@celticminstrel>
isFullWidth = (cc > 0xff && cc < 0xff61) || (cc > 0xffdc && cc < 0xffe8) && cc > 0xffee;
22:39
<@celticminstrel>
The prime is 0x2032, so it falls in that first range.
22:40
<@celticminstrel>
I bet a lot of other non-full-width characters fit in there too.
22:41
<&[R]>
Prime?
22:41
<@celticminstrel>
The prime symbol.
22:42
<@celticminstrel>
Used for minutes of arc in my particular case.
22:42
<~Vornicus>
celmin: uh, something seems wrong with the first range
22:43
<@celticminstrel>
Yes indeed.
22:43
<~Vornicus>
and also the &&, which is going to not catch the second range.
22:43
<@celticminstrel>
Very very wrong.
22:43
<@celticminstrel>
...what?
22:44
<&McMartin>
Is cc signed by any chance
22:44
<@celticminstrel>
Oh, precedence?
22:44
<@celticminstrel>
McMartin: JS, so technically yes but probably doesn't matter.
22:44
<~Vornicus>
Precedence and also I don't think you want && in the first place
22:44
<&McMartin>
Oh wait no
22:44
<&McMartin>
Yeah, that last && looks like A Problem
22:45
<@celticminstrel>
Problem in that characters greater than FFEE aren't necessarily fullwidth?
22:45
<~Vornicus>
No
22:45
<~Vornicus>
Problem in that it makes you miss the entire second region of fullwidth characters
22:45
<&McMartin>
If any previous clause is true, that one is false and therefore the whole thing is false
22:46
<@celticminstrel>
Oh, hm...
22:46
<@celticminstrel>
isFullWidth definitely had a value of true for some cc, because commenting that out fixed my problem, though.
22:46
<~Vornicus>
for cc = 0xffe1, you get (true && false) || (true && true) && false = false, but it's supposed to come up true, being FULLWIDTH POUND SIGN
22:48
<~Vornicus>
You need to fix the start point of the first region, and use || instead of && to glom the third region on, and not everything beyond BMP is fullwidth; it starts, for one thing, with a bunch of ancient alphabets
22:48
<@celticminstrel>
Looks like && has higher precedence than ||
22:48
<~Vornicus>
You're ignoring the problem
22:48
<~Vornicus>
It's *supposed to be || in the first place*
22:48
<@celticminstrel>
Okay.
22:50
<@celticminstrel>
I have no idea what is and is not fullwidth though... not sure if Character Viewer can tell me... do all fullwidth characters say so in the name?
22:50
<~Vornicus>
Because what it says now is "it has to be in fullwidth region 1, or it has to be in both fullwidth region 2 AND in the bottom-of-bmp control characters plus basic multilingual plane"
22:50
<~Vornicus>
There are 103 characters that say FULLWIDTH in their names.
22:52
<@celticminstrel>
Aren't all/most of the Chinese characters fullwidth too?
22:52
<~Vornicus>
They're all in the BMP and all in the two regions listed above, once you correct the start point for the first region. The third region is only a couple of control characters and then everything that's not in the BMP
22:53
<@celticminstrel>
Ah, I see, it should be FF00 not FF.
22:55
<@celticminstrel>
So, that plus changing the && to ||...
22:55
<~Vornicus>
beyond the BMP are quite a lot of decidedly not fullwidth characters
22:55
<@celticminstrel>
But from what you said it sounded like that last range includes some non-fullwidth.
22:55
<~Vornicus>
Lots of ancient languages, lots of mathematical symbols, a huge private use area...
22:55
<@celticminstrel>
So the CJK radicals are not fullwidth, I guess...
22:56
<&McMartin>
I would expect them to be combining
22:57
<@celticminstrel>
Not sure if it's worth fixing it for characters beyond BMP though... how many roguelikes will use things like Linear B anyway...
22:57
<~Vornicus>
What are you trying to "fix" here
22:58
<@celticminstrel>
The engine corrects for fullwidth characters by inserting a space before them.
22:58
<~Vornicus>
uh huh
22:58
<@celticminstrel>
Which looks bad when the character isn't fullwidth.
22:59
<@celticminstrel>
Though I wonder if it even looks good when it is fullwidth...
22:59
<@celticminstrel>
Given that it's skipping over that space rather than filling it with the background colour.
23:01
<~Vornicus>
Probably not.
23:06
<@celticminstrel>
So, just to be sure, those two are the only full-width ranges in BMP?
23:07
<@celticminstrel>
No Chinese characters or anything?
23:07
<@celticminstrel>
ff00..ff61 and ffdc..ffe8
23:08
<~Vornicus>
right
23:09
<~Vornicus>
But I don't have any idea what it's really trying to do or why it thinks it must do this
23:09
<~Vornicus>
Unless-- wait, is it doing a translation step on the fullwidth characters?
23:09
<@celticminstrel>
No?
23:09
<@celticminstrel>
It's writing one character per cell.
23:10
<~Vornicus>
RIght, right -- if you put in a character like, say, one of the CJK ideographs, does it draw that as two cells wide?
23:11
<~Vornicus>
If so, and it's also pushing the fullwidth characters trhough a translation step that brings it down into, say, its basic latin equivalent, then cjk with embedded fullwidths will look funny unless you add spaces in
23:12
<~Vornicus>
Which would explain why only the fullwidth characters are getting this treatment: they're designed to be used with 2-cell-wide characters, but they're showing up as 1 cell wide and that makes it look weird.
23:14
<@celticminstrel>
It looks like it doesn't really work well with CJK ideographs. Before, they were treated as full-width, inserting an extra space; now they're squished together. That said, the font it's using is Courier New, so maybe with a more Chinese-oriented font it'd work better.
23:15
<@celticminstrel>
Here the ideographs simply don't fit in a cell.
23:15
<@celticminstrel>
The're not only wider but also taller.
23:15
<@celticminstrel>
^They're
23:16
<~Vornicus>
Okay, this still makes a certain level of sense then: fullwidth characters -- you'd need to find this out from reading the stride widths I suspect, but you can safely assume all cjk ideographs -- need extra space or they push each other out
23:22 catalyst [catalyst@Nightstar-bt5k4h.81.in-addr.arpa] has joined #code
23:37 Derakon[AFK] is now known as Derakon
23:59 Kindamoody is now known as Kindamoody[zZz]
--- Log closed Wed Nov 23 00:00:21 2016
code logs -> 2016 -> Tue, 22 Nov 2016< code.20161121.log - code.20161123.log >

[ Latest log file ]