Homebrew Question What would be the ideal coding language to make homebrew apps when the Switch gets hacked?

Pleng

Custom Title
Member
Joined
Sep 14, 2011
Messages
2,439
Trophies
2
XP
2,810
Country
Thailand
And regarding memory leaks, Java IS a memory leak. I remember having a whole project done in C++/Qt by me, it used around 10MB of RAM, and the same thing ported to Java by someone else... 960MB of RAM... and it slowed down whenever it felt like, yey garbage collection!

Yea... You don't think that maybe this "somebody else" just did a really piss-poor job of the port?
 
D

Deleted User

Guest
C. Translatable skills that will do you wonders later on. Learn C.

As to other's users comments and suggestions on languages. Don't listen to them, since most of them are talking out of their ass and just repeating what they heard through the grapevine and oft repeated seldom correct opinions.

Python: good for little stuff, but not great for scaling to a larger program. Excellent as glue between things and writing demos. Can you write applications in Python that are structured well, scale well, and is pleasing to use? Sure. But why bother when there's better options?

Java: It's fine. Despite what the users around here say, you can write good Java. Android apps run with it just fine. It's a garbage collected language sure, but that doesn't imply you should willy nilly allocate large chunks instead of thinking how to produce efficient code with small memory footprint (something many amateur devs tend to do in Java then complain about performance issues). Debugging intern Java code where they don't understand recursion and instead have loops within loops within loops of iteration still gives me nightmares.

Javascript: Protip: This language is excellent for telling the difference between a wannabe dev who took a computing class in community college one time and people that use the tools that fit the job. Pure javascript sucks, so does npm (often), but the creative freedom that node and (good) packages give you makes for a creative sandbox extremely useful for prototyping or web apps. The negativeassociation often comes from people most familiar with statically typed languages, try js a couple times, can't wrap their minds around it, and quit. The ecosystem of web dev moves too fast sure, but that's technology and web dev.

ASM: Anyone who ever says the words "I'll write it in assembler and it'll run faster cause low level" (It's usually called assembly by the way) is talking out of their ass. GCC compiles C into much better ASM than people can realistically write by hand, and has been true since the 1990's. Is it useful to know? Absofuckinlutely. Many colleges force CS students to complete a "binary bomb" assignment to RE an application and "defuse" the "bomb". Knowing gdb and what your higher level code is actually doing in memory is a daily useable skill, otherwise you're "that guy" that uses printf statements to debug.

C: Are you doing systems or OS work? Do you need pipes in linux, or easy executing of and intercommunication between linux binaries? Are you writing some firmware? Great, C is for you. ASCII games? Cool! C is great. C is great for many things. Making visual games however, is not its forte.

C++: All the benefits of C, with more annoyances but better scalability and proper OOP. Once comfortable with C, learn C++. For any software engineering job you'll probably need it anyways. Better for graphics. But do it in linux, learning it with visual C++ forces useless skills often irrelevant later (fuck the MS build system)

Lastly: Learn C first. C++ is a good next up. But learn a dynamically typed language early on, as it's common for devs to have issues transitioning between the two.
 
  • Like
Reactions: facundoj

machinoman

Well-Known Member
Member
Joined
Feb 12, 2011
Messages
322
Trophies
0
XP
611
Country
United States
C. Translatable skills that will do you wonders later on. Learn C.

As to other's users comments and suggestions on languages. Don't listen to them, since most of them are talking out of their ass and just repeating what they heard through the grapevine and oft repeated seldom correct opinions.

Python: good for little stuff, but not great for scaling to a larger program. Excellent as glue between things and writing demos. Can you write applications in Python that are structured well, scale well, and is pleasing to use? Sure. But why bother when there's better options?

Java: It's fine. Despite what the users around here say, you can write good Java. Android apps run with it just fine. It's a garbage collected language sure, but that doesn't imply you should willy nilly allocate large chunks instead of thinking how to produce efficient code with small memory footprint (something many amateur devs tend to do in Java then complain about performance issues). Debugging intern Java code where they don't understand recursion and instead have loops within loops within loops of iteration still gives me nightmares.

Javascript: Protip: This language is excellent for telling the difference between a wannabe dev who took a computing class in community college one time and people that use the tools that fit the job. Pure javascript sucks, so does npm (often), but the creative freedom that node and (good) packages give you makes for a creative sandbox extremely useful for prototyping or web apps. The negativeassociation often comes from people most familiar with statically typed languages, try js a couple times, can't wrap their minds around it, and quit. The ecosystem of web dev moves too fast sure, but that's technology and web dev.

ASM: Anyone who ever says the words "I'll write it in assembler and it'll run faster cause low level" (It's usually called assembly by the way) is talking out of their ass. GCC compiles C into much better ASM than people can realistically write by hand, and has been true since the 1990's. Is it useful to know? Absofuckinlutely. Many colleges force CS students to complete a "binary bomb" assignment to RE an application and "defuse" the "bomb". Knowing gdb and what your higher level code is actually doing in memory is a daily useable skill, otherwise you're "that guy" that uses printf statements to debug.

C: Are you doing systems or OS work? Do you need pipes in linux, or easy executing of and intercommunication between linux binaries? Are you writing some firmware? Great, C is for you. ASCII games? Cool! C is great. C is great for many things. Making visual games however, is not its forte.

C++: All the benefits of C, with more annoyances but better scalability and proper OOP. Once comfortable with C, learn C++. For any software engineering job you'll probably need it anyways. Better for graphics. But do it in linux, learning it with visual C++ forces useless skills often irrelevant later (fuck the MS build system)

Lastly: Learn C first. C++ is a good next up. But learn a dynamically typed language early on, as it's common for devs to have issues transitioning between the two.
Dont forget HolyC, used to develop TempleOS.
 

Captain_N

Well-Known Member
Member
Joined
Mar 29, 2010
Messages
1,903
Trophies
2
XP
2,023
Country
United States
Only answer I can think off... Because you can?

True bosses program in assembly. Look what was done on the SNES. Thats all assembly. even the music. Them bosses back in the day are so bad ass, the modern devs dont even know how they made games that way. The only ones that got it was shovel night. However id like to see if it could be programed on the NES... of course it requires work from scratch. There was also that guy that made a brand new nes game in modern times. His game is called Mystic Searches. He made it from scratch and had to learn NES assembly. Thats a boss. Not a noob that uses another engine and slaps crap on it like mighty no .9, Yeah im looking at you
 

linuxares

The inadequate, autocratic beast!
Global Moderator
Joined
Aug 5, 2007
Messages
13,302
Trophies
2
XP
18,145
Country
Sweden
True bosses program in assembly. Look what was done on the SNES. Thats all assembly. even the music. Them bosses back in the day are so bad ass, the modern devs dont even know how they made games that way. The only ones that got it was shovel night. However id like to see if it could be programed on the NES... of course it requires work from scratch. There was also that guy that made a brand new nes game in modern times. His game is called Mystic Searches. He made it from scratch and had to learn NES assembly. Thats a boss. Not a noob that uses another engine and slaps crap on it like mighty no .9, Yeah im looking at you
I can't for the love of me remember the music software, but when I was on a tour of a record studio. He showned a software that was programmed in Assembly and had full gui, graphics, and all kind of features. And I think the totalsize was like 10mbs and that was the images that took all the size. The programming itself was just a couple of Kb big. Assembly is so freaking awesome!
 

sarkwalvein

There's hope for a Xenosaga port.
Member
Joined
Jun 29, 2007
Messages
8,508
Trophies
2
Age
41
Location
Niedersachsen
XP
11,232
Country
Germany
Indeed. And I'm sure there's never been anybody calling themselves a "C professional" who has then gone on to do a bad port.
Sure. Perhaps I'm just tainted by my own experience, but I find it doesn't happen as often with C programmers, and I'm not the only one, <insert appropriate quote from Linus Torvalds here... too lazy to do it right now>
 
D

Deleted User

Guest
True bosses program in assembly. Look what was done on the SNES. Thats all assembly. even the music. Them bosses back in the day are so bad ass, the modern devs dont even know how they made games that way. The only ones that got it was shovel night. However id like to see if it could be programed on the NES... of course it requires work from scratch. There was also that guy that made a brand new nes game in modern times. His game is called Mystic Searches. He made it from scratch and had to learn NES assembly. Thats a boss. Not a noob that uses another engine and slaps crap on it like mighty no .9, Yeah im looking at you

See my post above to see why you're wrong. Writing in assembly, be it stack oriented or register transfer oriented, doesn't make your code better, nor does it unlock some mystical game of boundless skill. Is writing an NES game in assembly these days impressive? Sure. But that's a minor example. Writing modern desktop applications in assembly doesn't produce anything reuseable long term, and if you just wrote it in C GCC would emit better assembly than you could write anyhow. Please stop with this "1337 asm coder" nonsense as it's just beating a dead and incorrect horse.


Sure. Perhaps I'm just tainted by my own experience, but I find it doesn't happen as often with C programmers, and I'm not the only one, <insert appropriate quote from Linus Torvalds here... too lazy to do it right now>

You clearly haven't worked in the field long enough then. You'll find elitist pricks about any subset of a profession no matter if it's software dev or plumbing. I mean hell, there's elitist web devs all over the place, and they can't even claim experience on their side since their coding paradigms and frameworks change once every 6 months to a year.

If you really want to find an arrogant dickhead about C, go find the oldest looking dev on any of the teams. He'll be rocking 70's style glasses and a beard down to his chest in colors of black, grey, brown (and sometimes green depending on how gross they are). They'll be more than willing to tell you all about how devs these days are shit and how ADA and later C were the best options and everything should have stayed how it was in the "golden years". The reason you don't see as many is that most are retired/dead from solder fumes and high cholesterol.
 
Last edited by ,
  • Like
Reactions: sarkwalvein

grossaffe

Well-Known Member
Member
Joined
May 5, 2013
Messages
3,007
Trophies
0
XP
2,799
Country
United States
Sure. Perhaps I'm just tainted by my own experience, but I find it doesn't happen as often with C programmers, and I'm not the only one, <insert appropriate quote from Linus Torvalds here... too lazy to do it right now>
Are you referring to that delightful comment on the git mailing list where he told some scrub that he would have chosen C over C++ for git if, for nothing else, it prevented terrible C++ devs like him from contributing?
 
  • Like
Reactions: sarkwalvein

sarkwalvein

There's hope for a Xenosaga port.
Member
Joined
Jun 29, 2007
Messages
8,508
Trophies
2
Age
41
Location
Niedersachsen
XP
11,232
Country
Germany
Are you referring to that delightful comment on the git mailing list where he told some scrub that he would have chosen C over C++ for git if, for nothing else, it prevented terrible C++ devs like him from contributing?
Yeah, half joking, but that is what I was talking about.
Perhaps he is himself a git (as he himself jokes about), but sure there was some truth behind that.
 

grossaffe

Well-Known Member
Member
Joined
May 5, 2013
Messages
3,007
Trophies
0
XP
2,799
Country
United States
Yeah, half joking, but that is what I was talking about.
Perhaps he is himself a git (as he himself jokes about), but sure there was some truth behind that.
I love a good Torvalds rant. That one in particular is a favorite of mine as someone who prefers C to C++ and used to work with a bunch of C++ elitists. I'd always needle them from the other side with how much better C is in its simplicity.
 

DarkOrb

Well-Known Member
Member
Joined
Oct 11, 2013
Messages
290
Trophies
0
Age
31
XP
874
Country
Germany
I would kill (no, I wouldn't, but you get me) for a C# compiler for the Nintendo Switch. Yeah, I know that you will be able to code in C# for the Switch in Unity 3D, but you are not allowed to use the official Switch SDK for homebrew.
 

thmo_

Member
Newcomer
Joined
May 15, 2018
Messages
24
Trophies
0
Age
30
XP
117
Country
Switzerland
Hi there y'all

Was searching for a good starting point for homebrew and only found this thread, sorry for digging it out ^^
Alright, so then, to my question :D

I'm coming from some high level programming languages, the last time i looked at C or C++ was in school and I totally forgot anything about it. I solely develop in C# (with or without the framework) and Swift (without using Objective-C inside my projects at all). But I'd like to start experimenting and learning to develop homebrew for the Switch.
So, is there another way to develop homebrew for the Switch (I do know some scripting languages, but I think that's not gonna help for actual homebrew..)?

If not, do y'all have some good resources for learning C++ again lol? (I do understand the basics of computer science and development and so on, so I think i can skip the "learn C so you learn XY" or do you think there's more to it and I should start from the very beginning?)

Thanks (and sorry for any spelling/grammar errors, non native here)!
 

sarkwalvein

There's hope for a Xenosaga port.
Member
Joined
Jun 29, 2007
Messages
8,508
Trophies
2
Age
41
Location
Niedersachsen
XP
11,232
Country
Germany
Hi there y'all

Was searching for a good starting point for homebrew and only found this thread, sorry for digging it out ^^
Alright, so then, to my question :D

I'm coming from some high level programming languages, the last time i looked at C or C++ was in school and I totally forgot anything about it. I solely develop in C# (with or without the framework) and Swift (without using Objective-C inside my projects at all). But I'd like to start experimenting and learning to develop homebrew for the Switch.
So, is there another way to develop homebrew for the Switch (I do know some scripting languages, but I think that's not gonna help for actual homebrew..)?

If not, do y'all have some good resources for learning C++ again lol? (I do understand the basics of computer science and development and so on, so I think i can skip the "learn C so you learn XY" or do you think there's more to it and I should start from the very beginning?)

Thanks (and sorry for any spelling/grammar errors, non native here)!
Hmm...
Read a couple of books I guess?
I would suggest reading some books related to the STL, and also that book on patterns and metaprogramming from Alexandrescu?
If you do C#, then I guess you will hate a little memory management, but C++ using containers and types from the STL shouldn't be too hard.
 

thmo_

Member
Newcomer
Joined
May 15, 2018
Messages
24
Trophies
0
Age
30
XP
117
Country
Switzerland
Hmm...
Read a couple of books I guess?
I would suggest reading some books related to the STL, and also that book on patterns and metaprogramming from Alexandrescu?
If you do C#, then I guess you will hate a little memory management, but C++ using containers and types from the STL shouldn't be too hard.

Still got some books about the basics and using STL, guess I'll go search for them in all my mess then.
About the other book you mentioned, you mean this one? https://www.amazon.com/Modern-Design-Generic-Programming-Patterns/dp/0201704315

Also other books you recommend?
 
Last edited by thmo_,

sarkwalvein

There's hope for a Xenosaga port.
Member
Joined
Jun 29, 2007
Messages
8,508
Trophies
2
Age
41
Location
Niedersachsen
XP
11,232
Country
Germany
Still got some books about the basics and using STL, guess I'll go search for them in all my mess then.
About the other book you mentioned, you mean this one? https://www.amazon.com/Modern-Design-Generic-Programming-Patterns/dp/0201704315

Also other books you recommend?
Yeah. I like that one book.
Other than that... Hmmm, I am not sure what book would I recommend regarding specifically C++.
I mean, the ideas are the same.
I would suggests reading many books that are perhaps unrelated to C++ to learn more about programming that you can apply to C++ also, but perhaps you are already familiar with that kind of things.

E.g. for unit testing and so, I would recommend "The Art of Unit Testing", but probably you already read it and it is mostly C# anyway.
also I would recommend in general reading that book about patterns from the Gang of Four, but probably you already read that long ago.

I don't think you should read much C++ specifics other than some basic STL, patterns and metaprogramming.... But (even if I like the book) that last one from Alexandrescu might be a bit too complicated and not a real requirement for homebrew development (I still recommend it).

TBH, the best you could do after reading about the STL again is taking a look at the libraries that you would be using for homebrew.

I understand you already know the basics about pointers and mallocs from C, new and delete and in general what you have to deal with regarding memory. Also you seem to be used to OOP, constructors, destructors, algorithms and data structures; so just take a look how it is normally implemented in C++ (i.e. STL).
 
  • Like
Reactions: thmo_

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    K3Nv2 @ K3Nv2: 10 tabs open on chrome and no slow downs suck it low ram plebs lol