News for hackers. Stuff that matters.

ryanpcmcquen

Re:Show HN: A 2D game engine in under 1000 lines of C on Friday February 07, 2020 @01:20PM (#22268987)
What would you recommend?
Re:Show HN: A 2D game engine in under 1000 lines of C on Monday February 03, 2020 @02:08AM (#22222062)
In my experience, including `"some_file.h"` is more common than `"some_file.c"`. I also like knowing at a quick glance what the entry point/main file is. That's less explicit when all the files have the same extension.
Re:Show HN: A 2D game engine in under 1000 lines of C on Sunday February 02, 2020 @02:18AM (#22215661)
I know that using .c and .h files is the traditional way of doing it in C, and I started the engine this way, but to be honest, is there any gain to it in this scenario?

The headers are library code, and having more files just means more maintenance and build complexity. Is there another advantage I am not aware of?

Re:Show HN: A 2D game engine in under 1000 lines of C on Sunday February 02, 2020 @02:15AM (#22215649)
Thank you for the feedback and gist, I will take it into consideration.

We use the 'happy path' style at work. It is OK. I find it has its own set of disadvantages as well. I am also not a fan of negative/negating conditions.

Whenever possible, I try to write the code the way I would explain it in plain language. This may be antithetical to the majority of modern programming, but I am OK with that.

Re:Show HN: A 2D game engine in under 1000 lines of C on Sunday February 02, 2020 @02:05AM (#22215602)
I don't want to add #pragma once until I am ready to ship the game. This way I will know right away if I do any redundant includes.
'The CS Detective' is the most well written introduction to Computer Science theories I have ever come across: https://nostarch.com/csdetective

It is approachable, fun, and engaging. It frames concepts inside a 'detective' story, making the explanations less abstract and more practical.

Re:Senate votes to reinstate net neutrality on Thursday May 17, 2018 @01:34PM (#17093436)
A lot of Republicans support Net Neutrality, including the stalwart conservative Scalia. The main reason so many current Republicans oppose it, is the association with Obama, and the piles of money Telecom is floating their way.
Re:Senate votes to reinstate net neutrality on Wednesday May 16, 2018 @05:26PM (#17086643)
I am surprised this even passed the Senate. It is almost as if Senators want to get re-elected.
This is 100% about ISP regulation.
I am yet to hear anyone who is anti Net Neutrality arguing for electricity or other utilities not to be regulated ...
Good find! Looks like he said something similar, but never those exact words.
Re:The Senate has forced a vote to restore net neutrality on Thursday May 10, 2018 @01:24PM (#17040969)
Slippery slope? Haha.
Re:The Senate has forced a vote to restore net neutrality on Thursday May 10, 2018 @01:23PM (#17040959)
In my experience in discussing these issues with people who were pro-FOSTA, this argument has helped them realize that it is violating the first amendment, and an example of government controlling the internet. So I have to respectfully disagree with your conclusion.
Re:The Senate has forced a vote to restore net neutrality on Thursday May 10, 2018 @06:33AM (#17037682)
I made no mention of it 'not being as bad' as other bills. I stand by my statement. Net Neutrality is government regulating ISPs. ISPs are not the internet.

And I think it could convert those in the anti camp. Some are against Net Neutrality because they see it as government control of the internet (it is not). They need to recognize that FOSTA is directly what they perceive Net Neutrality to be (at least in terms of results).

Re:The Senate has forced a vote to restore net neutrality on Thursday May 10, 2018 @06:27AM (#17037656)
Controlling ISPs !== controlling the internet.
Thank goodness for Slackware and Devuan.
Re:A Year Using Matrix and Riot on Thursday May 10, 2018 @12:45AM (#17036454)
Thank you for fighting the good fight!
Re:The Senate has forced a vote to restore net neutrality on Thursday May 10, 2018 @12:43AM (#17036447)
I find it funny that some people still see Net Neutrality as 'government controlling the internet'. They should take a look at FOSTA if they want to know what government controlling the internet really looks like.
Re:You can now run Linux apps on Chrome OS on Tuesday May 08, 2018 @05:53PM (#17025553)
This is a great and unexpected move by Google.
Re:Write Emails Faster with Smart Compose in Gmail on Tuesday May 08, 2018 @02:02PM (#17023094)
Yet another reason to avoid Gmail.
"If you can't explain it simply, you don't understand it well enough." - Albert Einstein

Brent definitely understands it well enough.

Re:Impact – HTML5 Game Engine on Thursday May 03, 2018 @02:20PM (#16988371)
I have seen those, most of them seem abandoned.
Re:Impact – HTML5 Game Engine on Thursday May 03, 2018 @01:26PM (#16987882)
I hope someone gets Weltmeister running client side now (without PHP). Then you could hack on Impact using a Chromebook!
Re:Cracking the Crypto War on Friday April 27, 2018 @03:21PM (#16943546)
I would love to hear more about Tromer's exploit. Anyone aware of where I can find more about it?
Buried treasure makes the world seem so magical.
Re:Keep VS Code from Becoming an IDE on Friday April 27, 2018 @12:34PM (#16942091)
Org mode is ridiculously good. It made me love Emacs.
Re:Keep VS Code from Becoming an IDE on Friday April 27, 2018 @12:31PM (#16942062)
The irony is, that this article is very short.
Re:Keep VS Code from Becoming an IDE on Friday April 27, 2018 @12:29PM (#16942044)
I always struggle with extensions. Often I just want to go completely extension free (as I do with Vim and Emacs). But some extensions are too good. A few that come to mind for VS Code are:

- Prettier

- Regex preview

Stack Overflow is a reflection of most internet communities, which show that many people are assholes.

Older »