« first day (1462 days earlier)      last day (3493 days later) » 

12:00 AM
is writing them as _.each() good enough
 
eg:
for (i = 0; i < mapArray.length; i++) {
    mapArray[i] = '#' + mapArray[i] + '#';
}
would become
 
I nu understunds
 
feels like that's ballooning SLOC
turning 3 into 5 for a function that has no place outside that particular map generation alg
if i had 10 different map generation algorithms that all needed that, sure that makes sense
 
mapArray = mapArray.map(wrapHashes);
var wrapHashes = function (obj) {
    return '#' + obj + '#';
};
You then have wrapHashes, which is now a testable function
@rwollr SLOC isn't a good metric for anything.
 
but muh elegance
 
12:02 AM
@rwollr your code is infinitely less elegant
 
i'll look into writing things more maintainable, lord knows it does need it
 
for loops are stupid
 
server code is currently a monolithic 700 line js file
i know which is why i'm converting it to use underscore
or will, eventually
but yeah here's the main thing i'm concerned with: pastebin.com/Zv2fnbN0
 
@rwollr yep, but do you know the difference between _.each and _.map?
 
not really
 
12:03 AM
And for what it's worth, use lodash, not underscore
 
i already have underscore because it's a requirement for a dependency
keeping slug size down
oh it's a superset
i thought lodash was just an alternative
i'll look into it then
 
it's a drop in replacement
and it's faster
 
but yeah what that pastebinned thing does is removes '#' in all cells except cells that are actually adjacent to a '.'
dunno how to improve that
 
@rwollr is mapArray a full 2D array
like are all the rows the same length?
 
i think sooo
possibly not at all points of generation
oh wait no yeah it is
 
12:08 AM
then you can change the bounds of your loop to start one in from the edge
 
it generates all the points the map will cover then generates the actual 2d array right then
 
that way you don't need to check if n + 1 / n - 1 exist
 
@SterlingArcher bro, just finished the most epic of workouts
(first gym visit in a very long time)
gym is SO much better than working out at home
 
0.o all along, the problem wasn't with my algorithm, but with js's bad luck at doing floats operations
@BadgerGirl ^
ok, mom, going to sleep in 3 mins
 
I'm totally going to be feeling that workout in the morning
 
12:13 AM
@ towc 0.1 + 0.2 = 0.30000000000000004
god bless javascript
lodash.min x 11,445,150 ops/sec ±0.79% (88 runs sampled)
underscore-min x 16,273,460 ops/sec ±1.24% (83 runs sampled)
underscore-min is 42% faster.
@phenomnomnominal maaan
 
yep: I challenge anyone to make this program fail by only pressing arrow keys towc.eu/game/kitten-shooter
 
@towc Does not doing anything count as failing?
 
@KendallFrey if you a loop doesn't get called 800 ms after the previous one the game will automatically pause, this is just to prevent crashing tabs
and also gets triggered when you look at another page for 0.8 seconds
 
well
 
just refresh the page and stay on that page
 
12:18 AM
don't you think it would have been nice to know that?
 
@KendallFrey probably, but this is just a proof of concept, going to add all of the ui and gameplay later
 
hah! broke it
 
codes i use for input on my stuff
when im not using dmauro.github.io/Keypress anyway
 
@rwollr I also have an input thing, and I don't usually use jquery :P
@KendallFrey how?
 
12:20 AM
step 1: wait 1 second
step 2: hold up
it stops at the box. that's not how physics works.
 
more about the keycodes, since your game only captures arrows keys atm
 
@KendallFrey I guess that was intended?
@rwollr I can change them to whatever I want, don't worry
I just prefer to test with arrow keys
 
@towc There's no way you intentionally wrote that specific case
 
anyway: I promised my mom to go to sleep now
 
it starts beside the box, never moves sideways, and ends up under it.
 
12:23 AM
@KendallFrey that's a weakness of AABB collision detection
 
@KendallFrey ooooh! that. Yeah, in the beginnnig the player is perfectly alligned with that box, and since I had to counterpart js's derpiness with floats perfect alignment is gone. In any case, after the player touches any key to go in the x direction, that will no longer happen
 
@towc you should use raycasting instead of AABB
or in addition to AABB
 
@rwollr what for? The only thing I need is AABB
anyway, back to sleep, and for reals
 
raycasting is very good for platformer collision detection, in addition to setting states for things like
standing on the ground, sliding down a wall
AABB has problems like the exact one mentioned above
raycasting doesn't replace AABB but it's a good supplementary system to keep things like that from happening
 
@towc floating point behaviour is not JS's fault
 
12:31 AM
oh i guess i only thought about saying i read a really good article concerning it but couldn't find it
 
My computer is doing one of the weirdest things I've seen
When I right click on the twitch player, the context menu appears in a completely different area of my desktop.
go home, Windows, you're absolutely fucking tripping
 
great, now I have to redo my tank
 
12:46 AM
hi
 
@user1467439 Welcome to the JavaScript chat! Please review the room pseudo-rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
 
Anyone here?
I am trying to address multiple DOM elements at once, is this the right way to do it?

$("[rel=tooltip], [data-rel=tooltip]").tooltip();
:(
sniff
 
Anyone know any tiling managers for windows..?
I tried maxto and hashtwm but both had critical problems
 
@phenomnomnominal Got my phone!
The size is definitely going to take some getting used to
 
@rlemon weird I havent noticed any, but I've only done canvas stuff with nodewebkit
never anything with inputs
 
12:58 AM
this was in the 'debugger' mode or w/e
just drag and drop the project folder
also,
 
lol
watch work out alright for you?
 
yea, but battery is still lacking
:/
and I need better ear buds
 
is yours always on?
the face I mean
 
it fades
 
I'm sitting at 71% right now after all day
ah, I have mine shut off now, the watch face
its kind of lame to have to do that, but idk
 
1:02 AM
at 8ish when I was leaving the gym it was at 14%
 
jesus man
yeah I have my brightness at 1 and watch face turn off, must make a huge diff
 
I start my day at 6:30am with it
so it is getting > 12 hours
I have my brightness at around half
 
I start mine at like 8-ish and its 8 here
tracked over 13k steps today
lol did a ton of walking at the pumpkin patch
 
I have no idea what I did :P I should check
 
otherwise my avg is like 5-6k
 
1:03 AM
did 30+ on the treadmill
 
I wonder if you have the newest vs
is it 4.4w.1
 
ahaha
 
under settings/about
 
5K steps @ the gym
 
the update apparently helped battery life a ton
@rlemon nice
 
1:05 AM
My normal day is probably about 200 steps
 
yea I got latest
turned brightness down to 1
was at 2
ahahaha
all of a sudden all of this gym crap is popping up on me
fuck you google and knowing everything about my life
 
LOL
 
pc gamers can be real asses sometimes :P
(top comments)
They are probably right, but don't piss on the mans parade
 
So now you can use $_ and some of the other goodies in jsh
I somehow managed to make nodes inspectable as if you did a dir on them, so browsing them like objects; getting an inspector-like view will be immensely difficult
 
I agree @rlemon
its like some weird cult now
That is a neat setup
 
1:17 AM
Maybe not immensely difficult, just much hard. So...push the lamer object view, or keep brewing until it's ready?
 
@Zirak nice, lol love the new feature
> I somehow managed to make nodes inspectable
magic coder
 
That's not live yet though. And I'm still amazed anything works
I only really understand about 30% of the code in jsh
 
my shoulders hurt :/
 
That means they liiike you
 
@Zirak i.imgur.com/ZLV6URW.gif .. I just wanted a reason to use this
 
1:20 AM
Justifiably ;)
@rlemon That somehow got me here: reddit.com/r/AskReddit/comments/cfbkx/…
Which is one of the better puns
 
lol
that brought me here
which is oddly similar to this rooms average conversation
 
Hey guys.. so I've been working with some Minified JS here and I'm getting some syntax errors.. I don't really understand lines 3 & 4 with the assignment right after the equality
 
it is basically an if statement
it is called short circuit evaluation
condition && ( statement )
 
YOU THINK THIS IS A FUCKING GAME?!
that would be cool to try
 
ARE YOU FUCKING SORRY?
 
1:30 AM
haha
thats from a reddit story isn't it? Dude yells that at someone after he hurts them
 
oh shit looking at the starred messages.. did I miss an entitlement discussion on ads?!
 
nahh just a single comment
 
haha yes @rlemon thats the one, thats hilarious
 
lol i've read it like 50 times and I still laugh every damn time.
god that is good stuff
@Loktar yea I saw that a little bit back. looks like it would be super fun. sadly that shit never happens in Canada
:/
no one cares about Canada.
 
1:34 AM
hell no one cares about the middle of the US either :(
 
cept me
 
either always on the west or east coast
 
you're my bankroll
keep growin dat corn son
 
haha
 
@Loktar That's cus you all hillibillehs, boy
 
1:35 AM
:(
 
obligatory
I've realized in Canada and USA at least, probably mexico, the stereotypes seem to only apply to the rednecks.
 
yeah definitely
 
Hmm.. alright, thanks. In that case I really can't tell what the minifier did to that line of code, assigning to a function like that, doesn't seem like valid JS to me at all
 
@CCInc it is valid. it is just slightly smaller ?
 
1:38 AM
10/10 will definitely look at it again.
 
!!> var a; true && ( a = 2 ); a;
 
@rlemon 2
 
s.descendants("words").child("@relative-x") = $$nf.coerceToXMLList(e.osDAva*j.vrsbwc);
 
erm, yeah, a CallExpression can't be an LHS of an assignment
That's definitely an error
 
!!> function foo() { return true; } foo() && ( console.log('here') );
 
1:40 AM
@rlemon "undefined" Logged: "here"
 
really?
nvm
i'm stupid
 
6 hours ago, by Zirak
Go with the lemon, he's right
 
Strange that that would be in production code.. shrug thanks!
 
That's not working production code
 
Indeed.. I can only assume that that function is not actually called anywhere
 
...wow
 
edit2 is killing me
lol
 
@Loktar that sounds terrifying
 
@rwollr haha yeah the no preview thing is nuts
 
my median time for writing code straight out of my head that doesn't break is about 45 seconds
i don't think 20 minutes would be a good idea at all
and i haven't even written html in months, i just use emmet or jade
 
2:04 AM
Hi...
I find an anomaly...
document.getElementById("myDiv").style.top="";
why not function?
 
why is that an anomaly?
 
Explain not change "disable" top?
 
@MirkoCianfarani you want to reset top?
You can change it to inherit, or initial
> document.getElementById("myDiv").style.top="inherit";
eh initial isn't supported in IE
so id go with inherit I guess
 
is anyone free to talk angular?
 
@eOgas Welcome to the JavaScript chat! Please review the room pseudo-rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
 
2:10 AM
okay, so with angular, are you meant to effectively duplicate your model on both the server and client side?
 
Already I know this example but in my case is a div
With firebug I can disable top css and not with Javascript :(
 
works for me
you didn't have no wrap set in your fiddle options either btw
 
sure.. final I have to change the position and not top...
 
hmm I'm not sure what you're asking.
 
when I click fullscreen
remains a div in the wrong position
Now is correct the position but I'm worried about the fact that it is not compatible for IE<9
mm now I have other problem ... not see the thumbnails!!!! ahhhhhhhhh
 
2:29 AM
@eOgas if all your data comes from your server and your database, then sure, you could say that there is a copy of it on both the server and client
but it has nothing to do with angular
 
@MirkoCianfarani You're worried it won't work in IE8? Do you absolutely have to support IE8? If not, don't.
 
@Mosho that makes sense. so there may be models that only live on the client, because they aren't persistent?
or models on the server side that are only used for data processing or whatever
I guess I need to stop thinking of every app as a simple crud app
 
2:44 AM
So people have asked why I've also begun to be against ++ and --. code.google.com/p/chromium/codesearch#chromium/src/third_party/… here's one example
It took me four reads to translate that
 
@monners ehehehe thx for suggest and now who still use IE!!!
 
@Zirak Bro, do you even Crockford?
 
@Loktar I solved with top:"auto"
 
@MirkoCianfarani nice
 
@monners He's what I masturbate to
 
2:47 AM
@Zirak I know
 
82
A: Remove CSS "top" and "left" attributes with jQuery

Rob HruskaThe default values for CSS top and left are auto, so setting them to that might be equivalent depending on what you're trying to do: $('.map').css('top', 'auto').css('left', 'auto'); You also have the option of wholly removing the style attribute: $('.map').removeAttr('style'); However, if ...

 
@MirkoCianfarani the first comment though is perfect
> usually such overwrites added to style attribute are meant for changing the value off from default css value; setting it to auto doesn't reset them to default value. meaning auto is not really same then not having the value at all. so correct answer would be $('map').css('top', '');
you should look at how JQ resets an attribute when you pass it a null value
 
I did it but not change position... seems perfect but not :/
 
Or, and I know this is a pretty crazy idea, perhaps we shouldn't inject inline-styles into the DOM?
 
You're crazy, man!
 
2:49 AM
Don't patronise me, kid junior buddy!
the fuck...
 
Don't be all pissy on me, sweet-cheeks!
 
I can't help it, I have a urinary tract infect!
 
Then why did you choose top bunk?
 
Because I hate you To be closer to God
Also you're too fat for top bunk
 
#toophat
 
3:01 AM
So I got tired of spontaneous linting errors, decided to sit down and solve linting shit once and for all!
...128kb file of linting errors.
I will never sleep
Fuck that I'm making a script
 
LOL
jesus dude thats a lot of errors
 
And it's not all of them, some files had too many errored before scan got completed
 
@rlemon @SterlingArcher anyone else who cares, this is the kind of crap I mean with gamergate and the game "journalists"
^ that isn't a one off comment either tons of the "journalists" say shit like that. Seems so crazy to me to talk about your core demographic like that
Sorry forgot to unbox the image above damnit
but that one is crazy! lol
doesn't @rlemon have an autounbox script?
 
3:18 AM
@Loktar I'm still not sure I understand what GamerGate is supposed to be about; are nerds doing something we shouldn't be?
When did it go from Valley Startup culture sucks to kill all of the developers?
 
@monners haha we had this discussion earlier in the day, basically there are 2 sides, one side paints it as a movement against females in gaming, the GG side is about cronyism and nepotism in games journalism
 
Well then I'm way off the mark
Movement against females in gaming? Have you seen Lara Croft in the new Tomb Raider??
 
@monners well the anti GG side says the gamergate movement is just about misogyny
which is crazy because tons of minorities and women support gamergate
 
What do you mean when you say support gamergate?
 
well, are a part of gamergate I guess
gamergate is the banner we rallied behind I guess
so there are gamergate peeps, and anti gg peeps basically
a good video on it from the GG's side. I posted it earlier too
 
3:23 AM
Cool, will check it out
So it's about game reporters being sexist in their reporting?
This is silly
The world would be a much easier place to live if people just tried a little harder to not be jerks.
:accepts Nobel Peace Prize:
 
In related new, world peace.
Release the hookers and cocaine.
 
Way ahead of you
Stock in companies selling mirrored table surfaces just sky-rocketed!
 
lol
 
@Loktar You playing Destiny?
 
no :?
 
3:36 AM
Why not?
 
you?
 
Duh!
I'm only mostly human!
 
eh a few other games came out I wanted
@monners hah
 
This CMS hates me. Every bloody stock module is built using tables
And they're a massive pain in the ass to strip out
 
4:04 AM
 
morning
@SomeGuy my pack arrived too \o/
> Simple cloud hosting, built for developers
DETAILS: $100 in platform credit for new users
Request your offer code to get access
> You can redeem your offer code using the link above, credit card required for activation
:(
 
4:27 AM
Glad I bought CS6 when I was still a student
Saved me literally thousands of dollars
 
which collection?
 
4:41 AM
Web Designer Premium I think
photoshop, indesign, illustrator, fireworks, dreamweaver (lol), flash
 
I got production premium cs4 in a student giveaway when cs5.5 was released.
 
I had 5.5 but upgraded to 6 just before I graduated
 
nice
 
I like to own the software that I use.
 
(I use most of production premium almost daily)
 
4:44 AM
I sure hope you don't use Dreamweaver
I wish I got all of my designs as illustrator files
 
I don't think PP comes with dreamweaver. It is about video(graphics) editing and production.
 
Photoshop really isn't that great for web graphics
 
Atleast I don't have dreamweaver installed.
 
Did it come with illustrator?
 
yes
and PS extended
 
4:45 AM
Nice
 
and I'm back up
 
and After Effects, Premiere Pro, Encore (I dun use it) and some other things were there which I don't know how to use.
I <3 After Effects and (sometimes) PP.
 
Never played around with the Adobe production stuff. Just vector and photos
 
@KendallFrey fixed that bug you were talking about towc.eu/game/kitten-shooter
 
5:16 AM
no more unlimited jumps for you :P towc.eu/game/kitten-shooter
 
How do people feel about Selenium?
 
@towc what is that game? what do I have to do?
 
@AwalGarg for now it's just a proof of concept for my collision algorithm
later one I'll add more things
 
ohh
!!afk
 
off to breakfast
 
5:43 AM
back from breakfast and off to school in 2 mins
 
go forth and learn
 
 
2 hours later…
7:32 AM
You guys are such nerds
 
Tom
yup
 
@Tom Welcome to the JavaScript chat! Please review the room pseudo-rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
 
@phenomnomnominal yeah, come to our club
 
@FlorianMargaine all the best are
@FlorianMargaine or it takes one to know one, what ever the right one is :P
 
@DrogoNevets : Good afternoon.
@CapricaSix : Good afternoon.
 
7:45 AM
hi
 
@rlemon @Loktar hi!
 
does anybody have spritesheets knowledge?
 
@FlorianMargaine smooth
somehow, i didnt need to click on it to know what it was
 
rlemon has to listen to it every friday, just saving him the trouble of a click
 
i just want it to be 16.00 then i can go home and relax
 
7:57 AM
@AwalGarg Congrats. Haha, what's the harm in that? It's so they can auto-renew it after your free period expires
 
@SomeGuy AwalGarg is afk.
 

« first day (1462 days earlier)      last day (3493 days later) »