Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 2 [3] 4 5

Author Topic: Learning to code - what, why and how.  (Read 6506 times)

SolarShado

  • Bay Watcher
  • Psi-Blade => Your Back
    • View Profile
Re: Learning to code - what, why and how.
« Reply #30 on: June 12, 2009, 04:38:11 pm »

Use Netbeans IDE if you are interested in Java programming.
http://www.netbeans.org/
It will make your life easier.

BAH, young people! I always compile from the comand line! I use vi even on Windows! (cygwin) I'm actually only 17, whatever.

If you're using windows, i can give you a regestry tweak that'll make command-prompt-ing easier. It adds an item to the right-click menu for folders, "Open CMD here".

It's not hard to learn some basic command prompt skillz, and it can come in handy.
Logged
Avid (rabid?) Linux user. Preferred flavor: Arch

cowofdoom78963

  • Bay Watcher
  • check
    • View Profile
Re: Learning to code - what, why and how.
« Reply #31 on: June 12, 2009, 06:37:40 pm »

Use Netbeans IDE if you are interested in Java programming.
http://www.netbeans.org/
It will make your life easier.

BAH, young people! I always compile from the comand line!
Eww, I tried that once. It was a pain in my ass. Pointless suffering for less then satisfactory results.
Logged

SolarShado

  • Bay Watcher
  • Psi-Blade => Your Back
    • View Profile
Re: Learning to code - what, why and how.
« Reply #32 on: June 12, 2009, 07:01:47 pm »

I can see how some compilers can be headache-inducing to use from the command line. Like C(C++, too?), what with the pre-processor, compiler, and linker (i am aware that some commands will do the whole think for you)... for carp's sake, that's why the "make" program was created AFAIK.

Java? just type "javac >source file to compile<". It even auto-re-compiles anything that needs it!

Admittedly, getting your PATH set can be a pain in the a$$ in windows XP/Vista... but it's not that hard.

EDIT: I don't mean to come across as argumentative or snobish... But I feel strongly that everyone who uses a computer, especially if they're trying something as "advanced" as programming, should have, at least, a basic knowledge of how to use a command prompt.
« Last Edit: June 12, 2009, 07:05:11 pm by SolarShado »
Logged
Avid (rabid?) Linux user. Preferred flavor: Arch

qwertyuiopas

  • Bay Watcher
  • Photoshop is for elves who cannot use MSPaint.
    • View Profile
    • uristqwerty.ca, my current (barren) site.
Re: Learning to code - what, why and how.
« Reply #33 on: June 12, 2009, 08:52:27 pm »

I use mingw.
When I compile stuff, I write the command to a batch file.
G:\MinGW\bin\gcc -o programName.exe main.c
Usually I use -lopengl32 and -lglu32, and I have started considering a second .bat that also uses -Wall for when I feel like it.

One double-click. Thats all it takes.
Learn it once then copy-paste.

You do NOT need to open some IDE, you do NOT need to know the command-line, as long as you keep each project in it's own folder and only use main.c, you don't even need to change compile.bat for new projects!

One call to gcc runs it through the preprocessor, the compiler, tthe assembler, and the linker. I didn't even need to know that the preprocessor can be called individually on a file(there is a flag to halt compiling after each of those steps, so you only ever need to call gcc!) to compile a C program. Oh, and it automatically routes .cpp files through g++, among the rest.

If working from the command-line, do yourself a favour and write it to batch.

Code: (compile -Wall.bat) [Select]
G:\mingw\bin\gcc -o game main.c -mwindows -lopengl32 -lglu32 -Wall
pause
Logged
Eh?
Eh!

cowofdoom78963

  • Bay Watcher
  • check
    • View Profile
Re: Learning to code - what, why and how.
« Reply #34 on: June 12, 2009, 10:28:59 pm »

EDIT: I don't mean to come across as argumentative or snobish... But I feel strongly that everyone who uses a computer, especially if they're trying something as "advanced" as programming, should have, at least, a basic knowledge of how to use a command prompt.
Basic knowledge is what I have, patience is what I dont.
Logged

Muz

  • Bay Watcher
    • View Profile
Re: Learning to code - what, why and how.
« Reply #35 on: June 13, 2009, 12:43:51 am »

Yes, cygwin comes in very handy. And Notepad++. So much easier once you get used to it and saves you a lot of time in the future.
Logged
Disclaimer: Any sarcasm in my posts will not be mentioned as that would ruin the purpose. It is assumed that the reader is intelligent enough to tell the difference between what is sarcasm and what is not.

AxelDominatoR

  • Bay Watcher
    • View Profile
Re: Learning to code - what, why and how.
« Reply #36 on: June 13, 2009, 02:47:09 am »

EDIT: I don't mean to come across as argumentative or snobish... But I feel strongly that everyone who uses a computer, especially if they're trying something as "advanced" as programming, should have, at least, a basic knowledge of how to use a command prompt.

I personally am fluent in programming with Assembly ( both m68k-Amiga and x86 ). I have about 10 years of experience programming asm and C so I'm not that "young", programming-side.
I program in C#, C++, Python, PHP and Java for work, but my preferred language is still Assembly ( with a bit of C ).
Same here for me: I don't want to be argumentative or snobish either, just using my experience ( and surely there are people around here with more than double such experience of mine ) to please a first approach with a language.

I'm all for the "bare-bone" style, but not everyone agrees on the subject. Chaoticag asked for a simpler way to compile java programs, so I suggested an IDE. Let him try and judge by himself.
Logged
Axel DominatoR ^^^ HC

Ampersand

  • Bay Watcher
    • View Profile
Re: Learning to code - what, why and how.
« Reply #37 on: June 13, 2009, 03:12:41 am »

My advice for anyone who wants to program a roguelike:

Read up on C and C++, download the source code for Nethack, and pick it apart. Play with it. Screw with it.
Logged
!!&!!

IndonesiaWarMinister

  • Bay Watcher
    • View Profile
Re: Learning to code - what, why and how.
« Reply #38 on: June 15, 2009, 12:31:09 am »

Emm...
Anyone know a better IDE for Python 3.0 (or 2.6) than IDLE?

Preferably free...

Logged

AxelDominatoR

  • Bay Watcher
    • View Profile
Re: Learning to code - what, why and how.
« Reply #39 on: June 15, 2009, 02:08:42 am »

PyDEV is slightly better than IDLE and free. It is based on Eclipse, tough, so it's not the fastest IDE out there. Wing IDE is way better, but unfortunately is commercial ( there is an evaluation version you can try ).
Logged
Axel DominatoR ^^^ HC

IndonesiaWarMinister

  • Bay Watcher
    • View Profile
Re: Learning to code - what, why and how.
« Reply #40 on: June 15, 2009, 10:01:53 am »

Whoa, thanks man!
So this IDE is based on Java? Hmm...

Well, I'll try this first! If this could help a n00b...
Logged

eerr

  • Bay Watcher
    • View Profile
Re: Learning to code - what, why and how.
« Reply #41 on: June 15, 2009, 11:37:13 pm »

Eclipse is java based for cross platform compatability.
That is the only reason.

You can also write java using eclipse, which means you already have an editor which can edit itself(plugins anybody?).
Logged

Sergius

  • Bay Watcher
    • View Profile
Re: Learning to code - what, why and how.
« Reply #42 on: June 17, 2009, 12:05:41 pm »

Use Netbeans IDE if you are interested in Java programming.
http://www.netbeans.org/
It will make your life easier.

Alternatively try Eclipse. I can't say which one is better, I think they have more similarities than differences.

Eclipse has a ton of pluggable stuff, for instance you can add a toolchain for C, C++, Objective-C besides Java.
Logged

AxelDominatoR

  • Bay Watcher
    • View Profile
Re: Learning to code - what, why and how.
« Reply #43 on: June 17, 2009, 12:46:15 pm »

Netbeans has a better autocompletion and GUI designer, but except for that is almost identical to Eclipse. Yeah, Eclipse would be better for a programmer that works with many languages or needs strange plugins. Netbeans has a lot of plugins, too, but mostly dedicated to Java.
Logged
Axel DominatoR ^^^ HC

Alexhans

  • Bay Watcher
  • This is toodamn shortto write something meaningful
    • View Profile
    • Osteopatia y Neurotonia
Re: Learning to code - what, why and how.
« Reply #44 on: June 18, 2009, 08:40:09 am »

Look... c++ is a GREAT and very popular language... Once you learn it it's fairly easy to use.

Then you can use the PDCurses library to make a roguelike game.  (I started a roguelike when I was learning that I intend to pick up or rewrite when I have more time, maybe even call for a project partner, but not now).

Anyway... I learned with C++ Ripped Appart and other tutorials.  You will have to research, google a lot, use help a lot (msdn), etc.  But if you like programming you will find it a fun ride.

There's also lots of places with c++ sample code.

New Version of C++ Ripped Appart:
http://www.mikeware.us/cpp/  (highly recommended)

Check the roguelike development megathread links for other great roguelike tutorials.
Logged
“Eight years was awesome and I was famous and I was powerful" - George W. Bush.
Pages: 1 2 [3] 4 5