« first day (1260 days earlier)      last day (3681 days later) » 

3:00 PM
Webtiles are best tiles
 
user3010322
@Xeo But it's never my fault! :D
 
user3010322
Uh
 
user3010322
Hm.
 
user3010322
Maybe I should use a mutex there.
 
user3010322
Instead of a condition_variable or w/e
 
3:01 PM
Yes
 
user3010322
Ugh, now I have to lock on every submit_buffers
 
user3010322
Maybe I should just keep an atomic<std::size_t> buffercount so I can just check it straight away instead of locking
 
What's the best species to play with?
I like the description of High Elf
 
Minotaurs are easy melee guys, with higher-than-average HP
They have shitty magic aptitudes, but you can win without any casting
 
user3010322
3:05 PM
Booyeah, I got it working!
 
Gargoyles get -30% HP but they have shitload of intrinsic resistances
From backgrounds you probably want to start as Fighter (gets good weapon and a shield and can worship anything) or Berserker (worships Trog by default)
For a Fighter worshipping Okawaru is the boring default choice
Both of these gods gift shit, and have pretty good abilities
 
user3010322
 
Thanks, again.
 
user3010322
@BartekBanachewicz ^ for 50 ms of sound, I can process in ~21 ms, and submit it to the underlying system in negligible time.
 
what about the weapon?
would a war axe do?
 
user3010322
3:09 PM
If I change that to like, a 20 ms of incoming sound, I can go even lower.
 
Axes get highest damage and cleaving (chance to hit multiple monsters adjacent to you), but you'll need a backup plan for hydras in midgame
Maces are a solid choice
ThePhD you are not playing Crawl
 
user3010322
What I can probably do is get a 10ms Realtime Audio Device going.
 
You should rethink your life choices
 
user3010322
@CatPlusPlus Dungeon Crawlers scare me. :c
 
eh
I looked on the screenshots and it was shitty ASCII art again.
that shit's just unusable for me
 
3:11 PM
This is offline tiles
Online has a bit different side UI and no mouse support
 
looks even worse than Baldur's Gate
 
I tried online earlier, now I'm using offline.
I prefer offline, it's faster. Plus, I like the tutorials.
Thanks, again, for showing me this game. Seems pretty awesome.
 
Online is generally a preferred way to play, because it's regularly updated and also has spectators
 
Offline daily builds are quite outdated right now, and 0.13 is completely older version (0.14 is supposed to come out in week or two)
 
user3010322
3:20 PM
Online is for scrubs.
 
user3010322
Offline, with optional Online, best play.
 
what the hell is this?
 
user1804599
It is a drawing.
 
is it like Facebook's mascotte?
a warning/message from facebook had that icon
 
user1804599
Dammit.
 
user784668
3:32 PM
@CatPlusPlus What's this game?
 
hey folks what do you think about cereal ?
looks soo C++11-y
and has VC++2013 support
 
user784668
Last time I checked, cereal looked very Haskellly.
 
user1804599
> BinaryOutputArchive
 
user1804599
Meh.
 
user1804599
3:35 PM
No underscores. :P
 
@Rapptz "external" is more correct, I think. The external refers to the linkage, and those are the ones that are zero initialized. That includes static member variables.
 
user1804599
 
Xeo
@rightfold ... wat
 
@rightfold why?
 
user1804599
true is not a keyword.
 
user1804599
3:39 PM
It is a predeclared identifier.
 
lol
 
user1804599
So you can create your own variable named true.
 
user1804599
Same for stuff like iota and uint64.
 
user784668
@rightfold Ahahahahahahaha what a dumb language
 
user1804599
true and false are documented as this: play.golang.org/p/fVw-xDIZzn
 
user784668
3:42 PM
Even Emacs Lisp gets this right.
 
user784668
You can't assign to nil and t.
 
user1804599
You cannot assign to true in Go either.
 
user1804599
FYI var declares a new variable.
 
user784668
Right.
 
What's their rationale for not just making it, you know, a keyword?
 
user784668
3:43 PM
(let ((t nil)) t) fails in Emacs Lisp.
 
user1804599
It just shadows the predeclared true.
 
user784668
So still Go is stupider.
 
Is it the same rationale that got us the silly C++11 tuples?
 
user1804599
@Griwes Makes stuff simpler I guess.
 
user1804599
(This is a non-issue really.)
 
Xeo
3:43 PM
I think @DeadMG was also contemplating to have true etc be identifiers, not keywords
 
@rightfold I don't see how.
 
@Xeo Has got that.
 
user1804599
Simpler grammar by having less keywords. :P
 
Xeo
ITT Wide as bad as Go
 
@DeadMG after seeing true = false, I would recommend making them be identifiers >.<
 
3:44 PM
personally, I've decided that it's really not a big deal at all either way.
 
@rightfold Yeah, two simplest keywords less. That makes things SO EASIER.
 
@DeadMG true
 
but keywords is better and I'll be going back to that route.
 
Xeo
@MooingDuck true = false;
 
when I find the time to be bothered about such a minor correction.
@MooingDuck Wouldn't be legal in Wide.
 
user1804599
 
@rightfold typedef int BOOL;
 
the real reason I prefer keywords is because the syntax highlight looks wrong with true not being a keyword.
4
 
Xeo
manual 'keyword' file
 
no.
 
user784668
@rightfold In Emacs Lisp neither nil nor t are keywords, yet you still can't shadow them.
 
user1804599
3:46 PM
That’s bad.
 
@Xeo That requires effort.
 
user1804599
Inconsistent special cases suck.
 
being an identifier grants you simpler implementation at the expense of lower ease-of-use in many ways.
it's not right that users can do stuff like type t { true := 5; }.
that just doesn't make sense.
 
@Fanael Lisp doesn't have "keywords" in the usual meaning at all, does it?
 
user784668
@Griwes Yes.
 
user1804599
3:47 PM
Go has only 25 keywords.
 
@Fanael So talking about them not being keywords is a bit redundant :P
 
user784668
@Griwes Well, it has special forms. But if you try hard enough you can override them, probably. Stuff will break, but who cares.
 
user784668
They still behave like functions.
 
user1804599
 
user1804599
Man.
 
user1804599
4:16 PM
I have such a fucking great idea.
 
user1804599
Static analysis is going to be a pain.
 
user784668
@rightfold Yes, Turing proved that in 1936.
 
why hello friends.
 
user1804599
Wait, nevermind.
 
user1804599
It’s gonna be simple as hell.
 
user1804599
4:21 PM
I was thinking way too hard.
 
hrmm... I don't understand operating systems class
 
user3010322
@Rapptz Really? C++ dev is a game now? xP
 
user1804599
4:42 PM
I need a function Context -> Interface -> Set Type.
 
user1804599
Which is quite buttocks to implement.
 
user1804599
And O(n) at best. :F
 
wat?
 
user1804599
I need to find all types that implement the given interface.
 
user1804599
Which is quite doable.
 
4:53 PM
is it possible to pass a method with context to a function?
 
@Fanael bragger
 
user784668
@StackedCrooked brag off
 
sorry my question was unclear.
 
@rightfold why?
 
user1804599
Because I want to do overload based on the dynamic type of an object, but give a diagnostic when not all possible overloads are implemented.
 
5:06 PM
Does anybody know is it necessary to define a destructor for objects used in vector or vector.clear does everything??
 
user1804599
All code is and types are available, so it’s technically not an issue.
 
user1804599
@HamidFzM Yes.
 
@rightfold You mean I don't need to define a destructor ?
 
user1804599
Destructors are implicitly defined.
 
@rightfold Thanks.
 
Xeo
5:11 PM
@HamidFzM it all depends on the contained type
 
why it's better to use nullptr than 0?
 
@Xeo What do you mean? please explain more.
 
user1804599
Because of this:
 
user1804599
void foo(double*);
void foo(int);
foo(0); // consufing!
 
Xeo
0 is an integer, not a pointer, and only works because C sucks
 
5:13 PM
@rightfold So... like a virtual table then?
 
Xeo
@HamidFzM what do you store in the vector?
 
user1804599
@DeadMG consider this:
 
I spent a good part of a day researching this; all that I found, including on stackover, were variations of the top code without the wrapping function. — user3474822 3 hours ago
that's a new one
 
C sucks? i thought C was a revolutionary language.
 
5:13 PM
@Jermimbilal It was, in 1972.
 
but it's still, most operating systems rely on C.
 
Xeo
legacy
 
mostly a historical accident.
 
Xeo
C is a shitty language by modern standards
 
also because many of them are essentially blindly religious towards C and can't conceive of the alternatives, or because they have some exceedingly specialized requirements.
 
5:14 PM
@Xeo I wrote a game in sdl that enemies objects created and stored in vector and if they die I erase them from vector
 
Xeo
the type, I want to know what type you store in the vector
 
user1804599
meth f a b : int // dispatch based on runtime type of a and b
impl f (a: T) (b: U) : int { … }
impl f (a: V) (b: W) : int { … }
a: baseOfTAndV = random [makeT!, makeV!]
b: baseOfUAndW = random [makeU!, makeW!]
f a b // error; f T W and f U V not implemented
 
Xeo
@rightfold that looks like the analysis could get mighty complicated?
actually, not really
 
user1804599
@Xeo not too complicated.
 
user1804599
As long as all data is available, it’s fine.
 
5:16 PM
i'm not exactly sure what nullptr is, a macro? a typedef? if it was defined in the compiler it should be something like typedef 0 nullptr
 
Xeo
you just need to check that over all overloads, for each parameter position, all derived types are covered
 
user1804599
I don’t have any implicit conversions except from T to interface that T implements, and you cannot overload on interface types.
 
@Jermimbilal It's a special value.
 
user1804599
But if I implement this right, it’s extremely flexible.
 
What is 42? A macro? A typedef?
Same thing.
 
user1804599
5:17 PM
You can both extend data types and operations on data types without modifying existing code, and get runtime polymorphism.
 
@R.MartinhoFernandes got the idea.
 
Xeo
@rightfold Isn't that, in a word, multimethods?
 
user1804599
@Xeo pretty much, but I have never used multimethods in a statically typed language.
 
Xeo
right
but yeah, not too complicated after all
could just potentially take quite some time
 
user1804599
It is also not possible to add new types at runtime (dlopen etc) AFAIK.
 
Xeo
5:19 PM
with long parameter lists, and large hierarchies
 
user1804599
Hierarchies cannot go deeper than two levels.
 
Xeo
that sounds like a rather weird limitation
Also, nom nom nom cake
 
user1804599
There are interfaces, which are lists of multimethods.
 
user1804599
Like, meth f x; meth g x; interface I { f _; g _ } (_ signals implementing type).
 
Don't do meth
 
user1804599
5:21 PM
And structs can implement interfaces.
 
user1804599
There is no inheritance or anything like that.
 
user1804599
(It would make multimethods an immense eternal pain especially with implicit upcasts and all that shit.)
 
user1804599
@CatPlusPlus meth lines up nicely with impl and func. :F
 
user1804599
Hmm interface and structure also line up nicely. Screw you struct.
 
Xeo
inface, struct!
 
user1804599
5:24 PM
interstruct and face.
 
user1804599
Hmm.
 
user1804599
Does a multimap store duplicate keys twice?
 
user1804599
I.e. is it more like std::set<std::pair<K, V>> or more like std::map<K, std::set<V>>?
 
@rightfold Beh, are you short on letters
 
Xeo
std::map<key, list<v>>
 
user1804599
5:27 PM
Nice. :3
 
@rightfold More like std::map<K, std::vector<V>>.
in fact I don't really know why multimap/multiset exist.
 
Xeo
list, actually
erasure guarantees demand a list, not vector
 
yes, I know.
 
user1804599
@DeadMG Automatically deletes key if no values are left anymore. std::map<K, std::vector<V>> doesn’t.
 
user1804599
I.e. you are left with empty vector.
 
5:29 PM
meh, trivial wrapping.
 
user1804599
True dat. :P
 
Xeo
so there is a trivial wrapper in the stdlib, big deal
 
user1804599
Meh, having a unique pointer as key sucks.
 
Xeo
hehe
unique_ptr<T, delete_except_on_search>
 
user1804599
lol
 
Xeo
5:33 PM
it actually works
have it default to a bool with true, and construct the search pointers with false in the deleter
only delete on true
 
user1804599
I will write it in Python instead. It has GC. :F
 
Xeo
lol
 
user1804599
I always have a hard time choosing a language for a new project.
 
user1804599
And I never really think of Python, which is a pity.
 
user1804599
Well, fuck. virtualenv broke with my last Python upgrade.
 
user1804599
5:36 PM
Ruby it is.
 
Xeo
lol
 
lol
 
C is very odd.
 
@Xeo More like, I've never really seen any use cases for it. It's not that I'm against trivial things being in Standard, but I'd rather see them be regularly useful things.
if it's both trivial and rarely useful, then I think you have a problem.
 
Xeo
you vs the world
 
5:41 PM
what exactly ARE the ready queue and waiting queue? Where do they reside?
 
It's all just a figment of your imagination
 
but then again, so are you Cat
 
user1804599
Hmm.
 
user1804599
Overloading is just a hash table lookup at runtime.
 
user1804599
I think.
 
5:44 PM
I have a question about some C/C++ psuedocode... there's a switch statement like this:
 
It's bad
 
switch(InterruptID) {
  case 0: // No interrupt
    break
  case 1: // Run program
    ISRrunProgramInterrupt();
    break;
then later, he has the method for ISRrunProgramInterrupt() below the switch statement. What I'm wondering is -- why not just put the contents of the method within the switch? In a higher level language, is that just as viable?
 
eh, not really.
it completely depends on how complex the method is and how complex the caller is.
 
the method which is being called is a void method with no parameters at around 10 lines, seems very... not complex.
 
user3010322
You also have to remember C++ doesn't allow you to declare new variables in a switch without brackets.
 
user3010322
5:51 PM
So, if you don't need any state from the parent function or the parent context, it all might as well jsut be in a function.
 
Yeah that's like, not an issue
 
user3010322
If it's small enough, you can manipulate the compiler to let it inline.
 
I am replacing it with code like so:
def interrupt_switch(id):
  def run_program():
    ...
  def invalid():
    raise ValueError('{} is an invalid interrupt: '.format(id))
  return {
    1: run_program
  }.get(id, invalid)()
 
user1804599
I think something like this should do. gist.github.com/rightfold/3abeb48c4f4f6316dbaf
 
user1804599
No.
 

« first day (1260 days earlier)      last day (3681 days later) »