« first day (1464 days earlier)      last day (3485 days later) » 

12:13 AM
it's not like they are something people don't use anymore :P
 
mia
12:39 AM
hey
can someone please help
i got headche out of this i can't figure it out
 
1:16 AM
@mia Take some ibuprofen
 
 
3 hours later…
5:32 AM
@Zirak !!Was it really?
!!thefarter
 
9 hours ago, by towc
and I start farting like hell as I finish
 
5:52 AM
@SomeGuy -_-
you didn't have to do that
 
6:04 AM
@rlemon probably in italy there is just no reason for not going outside and running
half of the time the weather is good and hot here
 
6:50 AM
How do I pause my program for 1 seconds?
Something like this:
for(i=0;i<=10;i++){
document.write(i)
..wait 1 sec..
}
@SomeGuy @towc
 
@Sawarnik there is nothing to pause the program
but try out setTimeout
google it and see if it can help
you'll have to use recursion tho
if you can't find a solution come back to us
 
7:26 AM
@towc I googled it, but then it needs some function?
 
@Sawarnik exactly
it triggers that function after n milliseconds
let's say I wrote this:
setTimeout(function(){console.log(1)}, 1000)
type that into the console and see what happens
you can also do better stuff like this:
function a(i){
    if(i <= 10) setTimeout(function(){a(i+1)}, 1000);
    console.log(i);
}
guess what does that one do
let's say you just called a(i+1) without the setTimeout
it would have logged the numbers from 1 to 10, in about a millisecond, right?
 
1 sec..
 
adding it simply calls the function after the second parameter's amount of milliseconds
 
@towc it returns undefined :/
 
so it will log 1, then call a(i+1)
@Sawarnik because you have to call a(i)
 
7:32 AM
undefined
 
try a(0)
should do stuff
 
7:43 AM
@towc You are so awesome at these things only at 14 :)
 
@Sawarnik I'm actually 95
 
what do you mean?
 
but thank you
my age is 95
 
@towc No less awesome anyway then. So good at 95!
 
:D
 
7:45 AM
@towc But I saw your photos on fb, definitely not 95 :P
 
@Sawarnik those were from when I was 14, yes
and 80 years ago we did have colored photocameras if you ask :P
 
hmm.
@towc But you say you are a student?
 
@Sawarnik it's good to keep learning even at this age
 
@towc You go to school?
 
@Sawarnik yep
school for elders
 
7:54 AM
@towc Why are you lying on your profile then? :D
 
@Sawarnik this is my grand grandson's profile
he do is 14
 
Ok, its getting confusing.
Developers at 14 are awesome.
 
thx
 
You are 14 then.
@towc Are you great at math as well?
 
@Sawarnik not as much as I'd like to be
btw everyone, added bombs! throwable with B towc.eu/game/invaders
they're too overpowered for my likings, I'll have to limit them
 
8:00 AM
@towc then how good are you?
 
@Sawarnik I'm best in class, but I still know a lot of 14ns that are better than me
 
@towc Same with me.
 
ok, only 3 bombs par wave now
 
@towc Maze is nice and simple :)
 
maze?
 
8:13 AM
I wonder if i ll understand the code to any extent.
 
@Sawarnik oh, that was one of my first minigames
they were just idea of concepts, didn't really plan on having anyone play those
the maze code really is simple, even tho written quite badly
I had almost no experience at the time
 
@towc :O
@towc How much money do you make btw from freelance coding?
@towc I like it :)
 
@Sawarnik I make no money because everything I do is free
 
Good.
I am 14 too anyway.
But my coding skills are so filthy.
 
@darkyen00 lemme ruin the numbah
667 :P
 
fuck you
 
Roundoff error
 
8:48 AM
@darkyen00 you'll have to unstar your star now :P
 
i didn't star
 
btw, nobody click this
 
@towc despite being of curious nature, I usually take people's word for "don't click this"
 
@Neil good boy
but wouldn't you like to know what happens if you click that?
 
morning ppl
@towc happy sunday from school dude :D
 
8:54 AM
@AwalGarg you go to school on sundays?
also, good morning
 
Oct 15 at 4:54, by Awal Garg
I have college which I rarely attend.
 
oh, right
btw, check the new stuff! towc.eu/game/invaders
BOMBSSS
I lov'em
 
@AwalGarg Why pay for college if you rarely attend? :|
 
good job man
 
@towc Gah! Sounds!
Almost got noticed at work XD
 
8:56 AM
@SecondRikudo lol
ok, I'll see if there's a way to turn it down
 
@SecondRikudo Government colleges in here don't cost much, and pay only cus of parental pressure. I dun wanna have college.
 
@SecondRikudo in the meantime, press K to mute them
also, is there a way to turn the volume of an audio context down with the Audio API? Can't seem to find any with google
 
@towc nice job
I like that it shakes when you destroy enemy craft
feels a lot more like an arcade game that way
 
oh, found it!
source.connect(volume);
volume.connect(output);
seems easy enough
should I have a spinner input or again with buttons?
 
problem -> search -> copy -> paste -> save -> F5 -> \o/ :D :D :D
3
^My workflow to solve problems three months ago
> Take for example the huge security hole in IE6/7 where JavaScript can be placed in an image and still be executed... allowing any site with an image upload feature (gallery) to be compromised by an XSS attack...
^is this true?
 
9:13 AM
@AwalGarg More like `problem -> search -> copy -> paste -> save -> F5 -> :/ -> adjust -> save -> F5 -> :( -> check documentation -> get frustrated -> lose confidence in programming skills -> \o/
 
@Neil lol true dat
 
9:28 AM
@SecondRikudo press I, there'll be a range input at the top. turn it a lot to the left to have a subtle sound towc.eu/game/invaders
I guess I'll add a starting screen, where I'll explain the user the basic rules
 
9:46 AM
I guess that this is good enough as a starting screen: towc.eu/game/invaders
so... one guy thought that to press the inventory you have to press L, because there's not much different between I (i maiusc) and l (L minusc)
there's a problem
 
10:07 AM
@towc I asked a related question on GDSE
4
Q: Difference in glyphs of I and l

Awal GargIn many fonts I come across, I see that the glyph uppercase i - I is same as lowercase l. Why is it so? Why don't font designers add a differentiating factor between the two glyphs? This specially creates a problem with the word 'Ill'. Whether to read it roman 3 or short for 'I will'. Extra ...

 
@AwalGarg Technically, you asked it on User Experience :P
 
@SecondRikudo haha yes
 
@towc Use a serif font
 
10:22 AM
@SecondRikudo a good looking one for a game?
for my experience seriffed fonts look quite bad in old-like games
 
@towc Or just designate a key for "L" and document that before the I one
 
@SecondRikudo doable
I'll use the sound one
 
lol
Only now I discovered the bombs
I got to The Lemon without them XD
 
what bombs?
 
@SecondRikudo :P
 
10:28 AM
@AwalGarg B
 
if you get lucky with the upgrades you can even beat The Lemon
without bombs
 
That knockback though
 
maybe a boss after The Lemon?
@SecondRikudo :P
I guess it's still a good feature
gives you a reason not to keep on pressing space
 
Feature requests:
- Document all upgrades
- Limit upgrades such as moving speed etc, otherwise it gets impossible to control
 
@SecondRikudo for upgrade documenting: press I
such as speed (which I agree on) and what?
 
10:34 AM
^number of times this game got shared ;p
 
@AwalGarg never enough ;)
 
indeed :D
 
The Lemon is the last level?
 
@SecondRikudo for now
I still have to find better stuff for the invaders
 
@towc No "You win!" screen?
 
10:38 AM
like, different weapons and AIs and stuff
@SecondRikudo no, because that would make you satisfy too much, and I don't want the user to be too satisfied
:P
It'll be easy
maybe I'll add some fireworks
maybe the occasional kamikaze invader?
which runs straight down at you, but if he misses and hits the bottom you won't loose?
also, some aiming invaders?
I really am not sure what would the user like
I could add more difficulties
in the easiest the upgrades are ultra-common, the enemies are slow, and they don't fire much
in the hardest I do the inverse
also greater knockback the greater the difficulty
oh well... I guess I'm done programming that for today. Keep on sending me suggestions if you have any please towc.eu/game/invaders
 
10:55 AM
hey
 
hey
 
11:12 AM
Apparently Brittish people want internet trolls to be raped in prison
Apparently people have to be controlled what they say and do like the rest of the sheeple
 
hello
@ziGi haha I just checked your profile, you are the room owner of an amazing number of rooms dude!
 
yes
I am teh master
haha
 
chat.stackoverflow.com/users/965090 everyone see the list of rooms which he owns lol
 
he's a master of his domain
 
nice change of topic tho
 
11:45 AM
(function a(){
 console.log("start");
 function b(){
  setTimeout(function(){console.log("dude"); return "stopped?";}, 1000);
 }
 b();
 console.log("should not appear");
})();
^why this no work?
It should log "start", "should not appear", "dude" and then return "stopped", but it doesn't return "stopped". Only does the logging part ;(
 
@AwalGarg You can't return from an asynchronous function.
 
let me check my friend
 
@SecondRikudo ;( what to do in that case?
 
return "stopped?"; applies on the function inside of the setTimeout
Use a promise
You can return a Promise object.
 
@SecondRikudo but I have to use xhr
 
11:48 AM
btw the anonymous function in the settimeout returns "stopped" but nothing handles it
 
@AwalGarg Your point?
 
@AwalGarg what are you trying to achieve
maybe that is not the best way to do it
 
@SecondRikudo I send xhr, which onload returns some value. I don't want it to be asynchronous, but the sync switch was deprecated.
 
@AwalGarg First of all, you want it to be asynchronous.
Second, how does that negate anything I said about promises?
Make a function that sends an XHR call and returns a promise for the return value
And return that Promise object from the function.
The caller function can use the Promise object and call .then on it
 
hmm, anyway to do that without promises?
 
11:52 AM
Yeah, have the function that sends the XHR call accept a callback
Which will be called when the XHR completes.
 
ahh that makes sense
 
yes
 
...but how to do it?
 
don't play with timers
 
function sendXHR(url, formParams, callback) {

   ....

   xhr.onload = callback;
}
Seriously though, use promises.
 
11:52 AM
yep
so simple
 
@SecondRikudo which is not working for me
 
@AwalGarg Code please.
 
@SecondRikudo what is the promise in the example you gave?
 
function sendXHR(url, formParams) {

    ....

    return xhrPromise;
}
then
sendXHR('http://localhost:8080, { foo: 'bar' }).then(function(response) { doWhatever(); });
 
how does a promise object in JS look like?
I have never seen one
 
11:56 AM
@ziGi Lookup bluebird promises
 
omg it's too hard
 
It's the best library around (better than native), and their documentation is very good
 
I need a version for noobs
 
I was talking about the game in the first post
Regarding promises, I've read that already. I'm still gathering courage to start using them
 
11:58 AM
ok thank you
 
function send(){
    console.log("my initial code");
    function check(){
        var xhr = new XMLHttpRequest();
        xhr.open('POST', /*myFD*/); xhr.send();
        xhr.onload = function(){return xhr.responseText;};
    }
    check();
}
send(); //no return ;(
@SecondRikudo ^this
 
181
A: How to return the response from an Ajax call?

Benjamin GruenbaumIf you're not using jQuery in your code, this answer is for you Your code should be something along the lines of this: function foo() { var httpRequest = new XMLHttpRequest(); httpRequest.open('GET', "/echo/json"); httpRequest.send(); return httpRequest.responseText; } var resu...

 
@AwalGarg Like I said, you can't return from an async function.
 
And can you please at least try to understand before posting here
 
why do you need to return from an async function
isn't the purpose of an async function to trigger an event
or alter some data
read this
there are good examples around
 
12:11 PM
@SecondRikudo hmm, the callback method copy linked to worked...
@copy thanks :D
@copy I tried well enough dude... :D
19 mins ago, by Second Rikudo
function sendXHR(url, formParams, callback) {

   ....

   xhr.onload = callback;
}
(wondering why I didn't read this carefully) sry
 
Awal Garg.
 
@Sawarnik hey dude! wassup?
 
@AwalGarg nothing quite.
 
hmm, gud to see here
I gotta go right now
cya later
 
bye
 
12:37 PM
I was thinking
If it is harder for left-handed people to write because they smear what they have written
isn't it then the same for right-handed people (which are most part of the population) to write in Hebrew or Arabic (cause they write right to left). So being a left-handed Israeli or Arab is better?
 
12:57 PM
@ziGi Not in RTL languages.
@ziGi :)
 
 
1 hour later…
2:02 PM
!!> var a = 4; y = a++ * ++a * a++ ;
 
@darkyen00 144
 
how so ?
 
evenin ppl
@Sawarnik transitioning from maths to code?
 
@darkyen00 it's 4 * 6 * 6
 
how ?
 
2:06 PM
@towc indeed, but I doubt the order is correct
AFAIK, it is evaluated rtl in c++, not sure if that is followed in js too
 
first time it multiplies by the value itself, and after that changes a to 5. Then before multipliying again adds 1 again (preaddition), multiplying 4 by (4+2=6), then it multiplies again by 6, and adds 1 to a
now I'm off to lunch
 
a++ <--4 (a=5)
++a <--6 (a=6)
a++ <--6 (a=7)
@towc is correct
 
2:22 PM
posted on October 19, 2014

var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www."); document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E")); try { var pageTracker = _gat._getTracker("UA-3727700-1"); pageTracker._trackPageview(); } catch(err) {} It's BAHFest day! If you can't be there, watch the BAHFest Twitter f

 
@Awal @towc love you both :D
// you guys dont mind me rubbing your ages on my classmates faces right ?
they are debating me on why a++ * ++a * a++ => 144
and not 125 (which is a bug in TurboC imho)
 
@darkyen00 totally don't mind :P. Actually keep on telling 'em
 
haha
 
wait... localStorage is the same as cookies, right?
either that or something has gone incredibly wrong in my life
@darkyen00 that means you should rub our ages to your face aswell, right? :P
 
2:40 PM
localStorage's function is the same as cookies, yes
It isn't actually the same
It's an easier way to do pretty much the same thing
 
@darkyen00 that is not a bug. turboc evaluates those expressions rtl.
38 mins ago, by Awal Garg
AFAIK, it is evaluated rtl in c++, not sure if that is followed in js too
 
@towc nope
i knew how that works :P
i also know why is that ambigous too.
but they werent listening so streamed you all live :D
 
mahahahaha
 
one idiot
is still linkin me old online compilers -_-
to prove his point ... :x
 
3:00 PM
there once was a question. I then answered correctly that question. The answer managed to send me a comment saying that it worked perfectly and that I should receive a cookie from someone, but didn't tag my answer as correct, then a finally more clever guy wrote this:
@turkey3 the way you give people cookies here is to click the upvote and/or accept buttons. — Pointy 46 mins ago
dahell turkey???
that question most likely is a duplicate of something somewhere anyway
s/The answer/The questioner
uuuh! I've earned vote down XD
the ability to*
 
3:40 PM
@darkyen00 I must say, your avatar is beautifully disturbing.
 
@SecondRikudo yeap
 
3:55 PM
anyone here
 
anyone here
 
someone there
 
I am here to deliver pizza!
 
i made something i want to show..it...i am learning javascript...

tinyurl.com/techsin
 
3:56 PM
Who has ordered?
 
gimme mah pizzah
@AwalGarg memememem
 
its uses peerjs
and canvas
 
@towc 90 dollars, sir ;) 100 if you wanna tip me :D
 
@AwalGarg how 'bout I kick ya in dah ass and you give mi mah pizzah?
@MuhammadUmer how do you type?
 
3:59 PM
@towc Then I rub all the pizza in ya face!
 
press Enter
start typing
press enter to submit
i added text that says press enter to type
 
i can see many uses for that
 
@MuhammadUmer superb job dude
 
4:20 PM
thanks bro...i just added sound...why js audio is so hard and mysterious..if someone join it will play sound...but if lots of peeople it will STILL play one sound .
 
@MuhammadUmer if you think JS is hard and mysterious, you should try embedded C development with USB HID devices.
 
Javascript isn't hard, it is just weird. And sometimes non-sensical too.
 
!!s/sometimes/mostly/
 
@BartekBanachewicz Javascript isn't hard, it is just weird. And mostly non-sensical too. (source)
 
not sure why, but this is beautiful codepen.io/MateiGCopot/pen/CwfjH?editors=001
 
4:30 PM
trigonometric functions vOv
 
@towc hey can I use that after some modifications for the "loading" icon?
 
@AwalGarg sure, it's not like I'm the first to do it
 
I was looking for something like this for quite a while
@towc you forked it?
 
@BartekBanachewicz what's that smiley? a faceplant? a snort? a happy kid?
@AwalGarg nope, but it's simple trigonometry
just look at the code
 
@towc It's not about the maths, I just need the concept. I would be recreating it anyways in AE.
 
4:34 PM
frame += 0.034;


  var x = Math.cos(frame)*side,
      y = Math.sin(frame)*side;
that's all of the logics
then I just draw 3 points based on those, and the lines between 2 of those points
 
yeah that's all fine and good... but I really like the concept and think that after a few changes, it would suit very well as a moderately sized loading icon.
 
@AwalGarg wait, let me create a css version (good for a loader: smoother and without lines)
 
kk
 
@darkyen00 unonebox fast
 
4:54 PM
I'll add the third point now
 
@towc trails?
 
@AwalGarg on css?
to do something that even looks similar to what I've done in canvas would take about 200 elements
 
@towc yeah... but that's ok. AE works on extendscript so css doesn't really bothers me ;p
 
asdfghjkl;'
 
and since I don't know much scss or sass, I don't want to write all of that css
@AwalGarg css is much much faster than canvas
and it's processed by the browser
 
4:58 PM
@towc AE would render me a gif, that is what is useful for me.
 
oh
ok then
 
What's Æ?
 
after effects
 

« first day (1464 days earlier)      last day (3485 days later) »