« first day (533 days earlier)      last day (4406 days later) » 

11:00 AM
@IntermediateHacker That's still half your estimate. Also, I didn't really golf it. std::tolower is a bit gratuitous, etc.
 
hi guys :D
 
Hi @GradGuy
 
@IntermediateHacker Not really.
 
@Potatoswatter Yeah. I'll double-check. It does work sometimes.
May well be a mistake on my part somewhere.
 
@DeadMG need proof. show me code.
 
11:05 AM
sure
gimme a few hours to remember or find the supporting lib code
 
@KerrekSB works here: ideone.com/aOv10
2
 
@Potatoswatter Yeah. Thanks.
I'm double-checking. I think I had some setup earlier where I thought it didn't work, but perhaps I overlooked something.
 
@DeadMG okay then. will check after a few hours.
 
Of course, a compliant new is a loooot more work.
 
Once there was an actual bug in GCC related to weak linkage.
 
11:09 AM
@Potatoswatter It is? I thought new was like, 15 lines or something (given malloc) in C++11
 
@Potatoswatter Not too much. You don't have to execute the new handlers, I think. It's just what the default implementation is guaranteed to do.
 
@KerrekSB Recently, too!
@KerrekSB @DeadMG Okay, okay guys… but 15 lines is still 15x as much as I did there ;v)
 
lol
arghh
 
@KerrekSB Ah, you actually are required to do the handlers. Not that it really matters if you know nobody will use them.
 
why is it so damn slow to get help with something like Direct3D9 instead of something like C++ :(
 
11:11 AM
@Potatoswatter Says who?
 
@KerrekSB The standard simply says that the replacement functions must meet the same requirements as the originals.
 
@Potatoswatter Interesting.
 
On a related topic, Is it a good idea to overload new globally to keep track of memory or is it better to do it separately for each class? :p
 
@KerrekSB Ah, no, I looked and that requirement is not there. You're right, I'm wrong.
 
@GradGuy You don't "overload" the global allocation function. You replace it.
@Potatoswatter Yay :-)
 
11:15 AM
11
Q: Why are Standard iterator ranges [begin, end) instead of [begin, end]?

DeadMGWhy does the Standard define end() as one past the end, instead of at the actual end?

wow, wasn't expecting that much reaction to that question
 
In which section is this?
@DeadMG Quite captacular.
 
@KerrekSB I see. but semantics aside, my question is still valid i guess?
 
@GradGuy That's only useful if you want to know how much total memory was requested by the program via new. It excludes malloc, overhead, fragmentation, etc.
 
@KerrekSB lol yeah, nice 99999 upvotes there for you :P
 
@GradGuy Yes, it is.
@DeadMG I didn't read the author's name when I answered the question. It was only later on that I realized it was you.
 
11:17 AM
@Potatoswatter but you would not use malloc in C++ anyways.
 
@Potatoswatter Nobody really mallocs, though...
 
@KerrekSB What difference would it have made? :D
 
@GradGuy Depends if "someone" decides to use a C library. libgmp for example.
 
@KerrekSB The Visual C++ new implementation falls back to malloc.
 
@GradGuy If you write real C++, then per-class allocation functions would not be used at all
@DeadMG I would have been shocked that you would ask this! :-)
 
11:18 AM
@ke
oops
 
@KerrekSB lol
 
@KerrekSB um, what do you mean by that?
 
@DeadMG Yeah, but always via ::operator new. There's no naked malloc.
 
@DeadMG The point here is code that calls malloc directly, bypassing a new override.
 
@Potatoswatter aha#]
now I understand wtf ur talkin aboot
 
11:19 AM
@GradGuy If you use libraries and containers, then all dynamic allocation goes via allocators, which only use the global function.
(Or whichever allocator you provide.)
So if you have std::vector<Foo> v;, your Foo::operator new never gets used.
 
@KerrekSB but then again when you globally override new you can still keep track of their allocation
 
Not even your Foo::operator new(size_t, void*) gets used!
Because the standard allocator uses global placement-new for the construction.
 
@KerrekSB and is this bad?
 
That's what I said.
@GradGuy No, that's great.
 
note to self
the Camera should have choice of field-of-view
 
11:21 AM
It just means that per-class allocation functions are royally useless.
 
@KerrekSB So then the question is, why would you ever want to overload new on a per-class basis rather than do it globally if all you need is to keep track of global memory useage?
 
I suppose you could make a new "class-new" allocator that uses the overloaded operators.
 
@KerrekSB You can specialize the default allocator in namespace std.
 
@GradGuy That's a straw-man question. I never claimed that I would want to do that.
@Potatoswatter I suppose you could do that.
 
@KerrekSB haha sorry about that! that was more of question asking myself ... loudly!
 
11:23 AM
@GradGuy I see. Well, I wouldn't! :-)
But on that topic: Since everyone and their dog are writing make_unique hacks, we seem to be missing the corresponding allocate_unique.
 
:well guess i learneed something new today ... at 4:30 a.m
 
now I'm getting kinda srsly pissed off
why the fuck would D3D write the depth values to the depth buffer of some pixels it isn't gonna render?
 
@jalf "A Happy DreamHost Customer" is the default WHOIS privacy setting for domains bought at DreamHost. But yeah that is totally fake.
 
ah fuckles
I've spent two days chasing that bug and it was my own stupid fault :D
 
Better than spending two days chasing someone else's bug.
 
11:35 AM
true true
I moved some code from main into a class's constructor
of course, I left in all the code that referred to local variables
one frame later, and the value of the camera's FarPlane was -3x10^8
NearPlane still 1, of course
now I just have to figure out why everything is rendering bad
but at least it's visible
 
yeah
it was my own fault for failing to debug it, too, because if you didn't move the camera, then the bad variable was never accessed and the problem never manifested
found it the instant I used a breakpoint to look at the values in a frame after I'd moved the camera
also explains why attempting to move the camera back was ineffective
 
Food intake time. See ya-
 
bb hf
 
Ok, I've been grappling with this for a while , I am trying to do a BFS of a DAG to look for a particular node (to check for loops when adding new links) , when I traverse a node , I mark it as traversed , but I see no way to reset the traversed variable aside from doing another traversal !! can anyone help me with this ?
 
11:42 AM
don't mark the node
add the address to a std::unordered_set
which can be discarded when you're done
 
@DeadMG but the traversal is recursive , the only way to mark this would be to pass a pointer to the set with every call
 
yes
and?
 
@DeadMG ah the overheads ! :)
 
ah the thread safety?
 
Single threaded program :D
 
11:46 AM
for now
look, it's easy to code, just do it and come back if you're desperate for perf :P
 
@DeadMG this one ? for ever :)
@DeadMG yup
 
@angryInsomniac You can assign each node a number at some thread-safe time, such that the set of assigned numbers is dense, and then use those to map to an array instead of the pointers. But yeah, what @DeadMG said.
This is bizarre. I'm connected to the internet through my tethered cellphone. It reports "no access to network." I can chat here, but other webpages won't load…
 
@Potatoswatter Hmm , Instead of that I could just go through my map that holds pointers to all elements and just reset the ones that are set !
 
aaah, the irony
I fixed a bug, and now my ships look like crap :P
not that they don't look like crap normally, but they look even more like crap now
 
@DeadMG ships ? You making a game ?
 
11:50 AM
yep
 
@angryInsomniac I'm talking about eliminating the hashing of pointers.
 
@Potatoswatter ok .. probably thats just out of my league at this point :)
@DeadMG free ? :D link ? :D
 
lolwtf, dude
I'm obviously still developing it :P
 
:D I too am an aspiring game dev :) I always love to look at wip's
 
well
I think that, technically, in a short time, I could allow the "player" to start ordering the sample "units" around
 
11:56 AM
@DeadMG RTS ?
 
yeah
easier to get away with bad graphics :P
 
@DeadMG True ! but resource graph management must be a bitch ! thats what I am dealing with right now :)
 
@DeadMG Do you plan to integrate AI, or is it multiplayer to begin with?
 
@angryInsomniac What resource graph management?
@KillianDS Probably gonna integrate AI ... at some point in the future. AI isn't really my area of expertise
 
@DeadMG No resources to be handled in your RTS ?
Like gold food energy and shit ?
 
12:00 PM
@angryInsomniac Sure, I just don't get what's graph-y about them
 
@DeadMG Nice. Game AI isn't typically that difficult though, it's just knowing the "right" algorithms. Making an RTS myself, but it's more a POC for something else than really trying to make a game :P.
 
@DeadMG Interesting ! I'd like to take a look at this if you ever OS it :)
 
I probably won't until a significant period after release
not really the FOSS kinda guy
 
Thats cool :) So you plan to sell this ?
 
try to :P
 
12:04 PM
@angryInsomniac I don't get it, you have resources per player and you have accumulation over time, where's the graph?
 
anyway
 
@DeadMG: Well, you made a "Hot Question". Congratulations.
 
now that I fixed the code, I ... actually don't know wtf I was going to do before I got buglocked
@KerrekSB What's one of those?
 
@KillianDS If you have a standard number of resources , one of which depends on the other and there is a fixed amount of each in the system, then you would need to deal with a graph , no ?
 
@DeadMG It's in the StackExchange menu on the very top-left
You are now network-wide "hot".
I filed a GCC bug report, by the way.
 
12:07 PM
lol
aargh
SK-Logic, why do you have to exist
 
@DeadMG You mean this?
Unlambda is a minimal, "nearly pure" functional programming language invented by David Madore. It is based on combinatory logic, a version of the lambda calculus that omits the lambda operator. It relies mainly on two built-in functions (s and k) and an "apply" operator (written `, the backquote character). These alone make it Turing-complete, but there are also some I/O functions to make it possible to interact with the user, some shortcut functions and a function for lazy evaluation. There are no variables in the language. Basic principles As an esoteric programming language, Unlambda is...
 
@Potatoswatter No, he's a user on Programmers
and a total prick
 
@angryInsomniac Could be your resource system is that complicated it needs a graph. I'd usually approach it as a source and sink problem with appropriate fluxes, don't worry about a possible graph structure that could be behind it :P.
 
@angryInsomniac Why would one depend on the other?
usually resources in RTS games are independent
and the amount in the system total is not fixed at all
 
@KillianDS Hmm , true , but how would you deal with interdependent resources (if they exist in your game that is)
 
12:11 PM
don't
if you can't figure out how to develop it, it's a pretty sure shot that the user can't figure out how to use it
 
@DeadMG Really ? I would think that the amount of gold in any map of AoE was fixed at start
 
10
Q: How does one get rid of fishy behavior in Windows?

Tom WijsmanAfter I had boot my computer this morning there suddenly flooded water from the top of the screen, after which some fishes dropped into it. Now I can barely see what I am doing because the water distorts the view. Sometimes the fish follow the cursor so I need to move it away or wait for the fish...

 
Well, suppose you have something like a fletcher that depends on wood (I take stronghold as an example :P)
For the fletching you just take your current wood stockpile as a source
 
@angryInsomniac Yes, but as the gold is mined, the total goes down.
 
It's too bad that April Fool's questions tend to be written better than non-April Fool's questions
 
12:12 PM
and the fletching as a sink (which actually will annihilate the resource)
 
@KillianDS Ok , so you have one sink that consumes another , right ? what if there is a chain of sinks ?
with each sink depending on more than one resource to function
 
you don't have chain of sinks, in a source-sink system when you have a chain a node is a sink for one purpose and a source for another.
e.g. your wood stockpile can be the source for fletching, but the sink for lumbering
 
and each sink lending itself to be used by multiple sinks
 
The advantage is you don't look at some whole graph, you just look for any operation to the two appropriate nodes (or multiple nodes, but that's more becoming an economy game then an RTS).
 
@KillianDS that , would be a great advantage obviously
 
12:15 PM
generally speaking, RTS games do not have anything like that
 
Note that this is not really a general approach, it's more an abstraction of how you mostly implement it.
 
the most complex RTS economies I've seen from successful games are rate-based and the simpler ones are fixed-payment based
stuff that's more complex than that is more of an economy sim thing rather than an RTS
 
@DeadMG There is one really great game that does
 
which?
 
stronghold crusader, each resource needs to be processed in a number of steps
 
12:16 PM
Anonymous (used as a mass noun) is an Internet meme that originated in 2003 on the imageboard 4chan, representing the concept of many online and offline community users simultaneously existing as an anarchic, digitized global brain. It is also generally considered to be a blanket term for members of certain Internet subcultures, a way to refer to the actions of people in an environment where their actual identities are not known. In its early form, the concept has been adopted by a decentralized online community acting anonymously in a coordinated manner, usually toward a loosely self-...
 
right
so, some nothing game nobody has ever heard of
 
^ These people creep me out.
 
and as far as I remember , processing at each stage reqd multiple resources
 
@angryInsomniac hey, u play stronghold crusader too?
 
@DeadMG Its played quite a lot on this side of the world :D
 
12:17 PM
@DeadMG That are basically practical implementations of for example an infinte source with a steady flux. But the source=sink model I told is just an abstraction for those things, that would be more real implementations indeed.
 
@IntermediateHacker Yup I used to :)
 
@DeadMG stronghold was pretty popular here when it was released.
 
@KillianDS it was pretty popular here too.
I wonder why @DeadMG hasn't heard of it.
 
@KillianDS If I ever try to implement an RTs I might just go with what you guys are talking about :) I am just making a project where I have to make an approximation of the system
 
But in fact, it was mostly an economy game. In 2 and later versions you could even choose between a economy-based game style (with indeed the complex resource tree) and a military style which is more RTS like
 
12:19 PM
Its a bit more complex than most RTS games , but once you get the hang of it ... best game ever
 
combining the two was just not fun
 
btw , @IntermediateHacker and @KillianDS "The stockpile is full my lord" :D
2
 
@KillianDS yeah. I hated having to set up the whole Granary -> Farm -> Mill -> Bakery system. :(
 
eh
 
good morning everyone
 
12:21 PM
I checked Wikipedia and everybody was just playing Starcraft and TA during that time period
 
And it was a pain to make all those weapons. Initially I used to just use the hired Arabian soldiers. But the knights and the macemen were awesome.
@angryInsomniac that message seriously annoying. especially when you have built buildings surrounding the stock pile.
 
@IntermediateHacker You're under attack , the whole city is burning and "The stockpile is full my lord" :D
 
@DeadMG stronghold was released years after TA and even starcraft. I won't say it came to the heights of those two, but it still was popular. they didn't make 3 or 4 follow up versions of that game because it didn't sell
 
i had stock piles surrounding buildings xD
 
except both of those games were playable for plenty of years to come
@KillianDS 3 or 4 follow up versions of what game?
 
12:24 PM
stronghold
 
@joschua011 lol. I once built surrounded my entire castle with stock piles. They were free.
 
ah
perhaps it didn't sell for a reason? :P
 
It did sell :P
 
Stronghold 3 is a 2011 real-time strategy computer game developed by Firefly Studios and published by SouthPeak Games. The game is the seventh in the series after several spin-offs, including and an MMORTS. It is the sequel to Stronghold, released in 2001, and Stronghold 2 released in 2005. Unlike previous games in the series which were published by Take-Two Interactive, the game has been published by SouthPeak Games, the new parent company of Gamecock Media Group, publisher of '. Synopsis Background The original Stronghold told the story of The Boy and his quest for revenge against Duc...
@KillianDS they did make a version 3 follow up.
 
Okay, that sentence translated bad to english, is a bit confusing
@IntermediateHacker Yes, they made a two, about 4 expansions and now even a 3, I meant to say that, but I used a dutch expression and translated more or less literally to English which was a bad idea and lead to confusion ;)
 
12:27 PM
this was my favourite version though.
 
i only played the first part, a friend of mine got the second but i didn`t like it, back to the roots....
 
in any case
the vast majority of RTS games do not use anything like such a complex economic system
 
the crusader trail was bloody long and difficult. about 50 (+ 25 more in the extreme version) long missions.
 
I will probably have to buy this now :D (nostalgia)
 
@angryInsomniac me too.
 
12:29 PM
@DeadMG I do agree with that, most series even simplified economics over time.
 
@KillianDS dumbing down happens over time to widen the user base , its only natural
 
@DeadMG But over-simplified economies are bad too. Look at Command & Conquer.
 
I am afraid of the same thing happening to diablo 3 :(
 
I didn't play Command and Conquer after the first couple of games
C&C is like Doom, it was a great starter for the genre, but didn't do anything interesting apart from that, and other games did a lot better in defining the genre afterwards
for example, System Shock 2/Deus Ex/Half-Life in the FPS arena, and Starcraft/TA/Homeworld kind of thing in the RTS arena
 
@angryInsomniac I disagree, if I look at AOE for example. The first game was a PITA because you had to micro manage things like your food income. The second game was awesome because they simplified that and you could focus on strategy. The third again fucked up (IMHO), because they introduced to many ways of earning resources (and wtf was that "exp" resource). That has nothing to do with widening the userbase, but improving gaming experience
 
12:32 PM
@KillianDS Never played AoE 3
Too much !
 
AoE II The age of Kings was the only one I played.
Interestingly, I owe a history surprise test to that game.
I had to write a note on the achievements of Genghis Khan, didn't know a thing, wrote the campaign story from the game. Got awesome grades. :D
 
1:28 PM
Any sadistic people, can you break this and tell me how you did it ? filedump.net/index.php?pic=breakthis1333286850.zip
no viruses I promise :)
 
OH MY GOD!! When has this room become so vacant...?
 
Sundays are like this
 
1:44 PM
2
Q: weird calculation result

crushanatorwhy d is not equal b in this example? unsigned int z = 176400; long a = -4; long b = a*z/1000; //b=4294261 long c = a*z; // c=-705600 long d = c/1000; // d =-705 Thanks.

 
@KillianDS AoEII with the Conquerors expansion is my most played game. Spent many months online trying to get better.
 
WUT THE... I was just reading reddit/gaming, then all of a sudden 20+ members joined the chat rooom.

WUT IS GOIN ON!?
So many red X's in the avatar picture count.
Man, I hate refreshing so many pictures. Fix the webchat, SO. :/
Jesus, anyone ever had this problem?
 
2:24 PM
@tom_mai78101 Don't panic.
 
Ok then.
F. I'm getting 3 rows of X'd pictures.
 
2:36 PM
didn't we just say don't panic? :P
 
First they came for the gorillas… I said nothing.
 
then they came for you, and I laughed
 
To be honest, without those avatar pictures, I do not have the slightest idea on who you are.
 
I know, it's way faster to parse the picture than the text name
 
For example, DeadMG's avatar isn't showing. I don't know who is DeadMG. :(
 
2:49 PM
puppy
 
Without the picture, I can't say.
You could be the X-Mens
Along with the rest of the squadron of X pictures.
 
I am most assuredly the puppy
man
 
To be honest again, I'm more biased with an X-Men puppy superhero.
 
nothing feels worse than playing a game and being unfairly discriminated against
 
At least I'm being honest. :( Sorry.
 
2:52 PM
wasn't talking about you
 
oh. :P
 
Stackoverflow has a magic unicorn? WTF?
It even looks like the old MS Office paperclick in the form of a unicorn...
 
April's Fool?
That's a good fool. I thought we are going back to the roots.
 
I hope so
the paper-clip unicorn is horrific
 
2:56 PM
it's Hilarious™
COMMIT!
to source control! now you fixed the bugs!
that's what smart people do! they commit, to their source control!
 
oh, so puppies haven't reached that mental age yet?
or have you learned to commit by now?
 
I do commit whenever I remember it :P
 
so the question becomes... how often do you forget :D
 
regularly
 
Post-it Notes commonly stickied?
 
3:01 PM
huh?
 
Huh? Oh my God.
Nevermind that message.
Didn't realized I typed into SO from Yahoo! Messenger.
 
oh god. i once pasted a PORN Url into the Instant messenger and pressed Enter
 
congratulations
 
:O That's even better.
 
^haha
 
3:03 PM
i thought the damn messenger was put into "message" mode, but it was in "Clipboard" mode xD
 
Who did you sent to?
 
a friend of my sister o_O
 
Can't imagine what happened next...
 
lol
he thought it is funny and told her ><
 
Oh, and I thought the "friend" is a girl.
 
3:06 PM
yeah, me too
 
no it was a boy xD
Oh my God that would have been even more embarassing lol
 
why?
you sexist
 
Be careful with Messenger's status message list. You can't remove entries, and if you drop a file onto it (on OS X), the filename becomes your status message.
I forever have the option of changing my status to form1040.pdf, but it could be a lot worse…
 
anyone good with algorithmic complexity questions
 
Wow, I never had that on Windows 7.
 
3:15 PM
@WhatsInAName depends. I know std::map::find is O(log(n)) for example, not much else
 
3:36 PM
Hmm, my question got posted on reddit
 
Which one?
 
20
Q: Does Haskell require a garbage collector?

PubbyI'm curious as to why Haskell implementations use a GC. I can't think of a case where GC would be necessary in a pure language. Is it just an optimization to reduce copying, or is it actually necessary? I'm looking for example code that would leak if a GC wasn't present.

 
Anyone interested in stackoverflow.com/questions/9964418/… ? The comments kind of open more question than they answer.^^
 
0
Q: Any Practical Alternative to the Signals + Slots model for GUI Programming?

IntermediateHackerThe majority of GUI Toolkits nowadays use the Signals + Slots model. It was QT and GTK+, if I am not wrong, who pioneered it. You know, the widgets or graphical objects (sometimes even ones that aren't displayed) send signals to the main-loop handler. The main-loop handler then calls the even...

come on, any takers? does no one dare to answer?
 
it's been only four minutes
 
3:50 PM
sorry lol, guess I should learn patience.
 
yes, you really should
also, try accuracy
 
0
Q: How to change text and background color?

Tprice88I want every character to be a different color. for example, cout << "Hello world" << endl; 'H' would be red 'e' would be blue 'l' would be orange and so on. I know this can be done, I just don't know the code for it. and I want to change the background color to white. How would I...

an april fool straggler?
 

« first day (533 days earlier)      last day (4406 days later) »