Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Poll

What programming topic would you want the next challenge to be about?  (It might be a good opportunity to focus on a subject you're not familiar with or to reinforce knowledge on one that you already know)

Control Flow
- 2 (2.2%)
Arrays, Strings, Pointers, and References
- 8 (9%)
Functions
- 4 (4.5%)
Basic object-oriented programming
- 30 (33.7%)
A bit more advanced OOP (Composition, Operator overloading, Inheritance, Virtual Functions)
- 18 (20.2%)
Templates
- 8 (9%)
Other (Explain)
- 4 (4.5%)
Working with files?  (Streams)
- 15 (16.9%)

Total Members Voted: 89


Pages: 1 ... 76 77 [78]

Author Topic: Programming Challenges & Resources (#bay12prog) Initiative  (Read 97507 times)

Siquo

  • Bay Watcher
  • Procedurally generated
    • View Profile
Re: Programming Challenges & Resources (#bay12prog) Initiative
« Reply #1155 on: October 18, 2011, 12:57:23 pm »

Yep, that's it.

Changing it to this fixed everything:
Code: [Select]
    public void centerViewPort(GamePhysical gp){
        Vec3 p = getScreenLoc(gp);
        if(p.x < viewWidth /3){
        viewPortX += ((int)p.x - viewWidth/3);
        }
        if(p.x > viewWidth * 2/3){
        viewPortX += ((int)p.x - viewWidth*2/3);
        }
        if(p.y < viewHeight /3){
        viewPortY += ((int)p.y -viewHeight/3);
        }
        if(p.y > viewHeight * 2/3){
        viewPortY += ((int)p.y - viewHeight*2/3);
        }
    }
Too easy. My mental energy is fluctuating so hard I go from dumb to genious in a day. ;)
Logged

This one thread is mine. MIIIIINE!!! And it will remain a happy, friendly, encouraging place, whether you lot like it or not. 
will rena,eme sique to sique sxds-- siquo if sucessufil
(cant spel siqou a. every speling looks wroing (hate this))

Ghills

  • Bay Watcher
    • View Profile
Re: Programming Challenges & Resources (#bay12prog) Initiative
« Reply #1156 on: January 19, 2012, 09:59:51 am »

Just stumbled onto this: http://projecteuler.net/

It's a collection of mathematical programming challenges.  The challenges are a interesting and a good way to brush up on skills or try a new language out.
Logged
I AM POINTY DEATH INCARNATE
Ye know, being an usurper overseer gone mad with power isn't too bad. It's honestly not that different from being a normal overseer.
To summarize:
They do an epic face. If that fails, they beat said object to death with their beard.

SolarShado

  • Bay Watcher
  • Psi-Blade => Your Back
    • View Profile
Re: Programming Challenges & Resources (#bay12prog) Initiative
« Reply #1157 on: January 19, 2012, 06:03:42 pm »

Just stumbled onto this: http://projecteuler.net/

It's a collection of mathematical programming challenges.  The challenges are a interesting and a good way to brush up on skills or try a new language out.

Interesting... definitely gonna look into this.
Logged
Avid (rabid?) Linux user. Preferred flavor: Arch

Thendash

  • Bay Watcher
    • View Profile
Re: Programming Challenges & Resources (#bay12prog) Initiative
« Reply #1158 on: April 26, 2012, 09:59:25 pm »

I've recently gotten the itch to program. I'm using XNA 4.0 and I couldn't help but notice it doesn't have a section on the op even though I believe it to be very easy to use in making games. I'd recommend XNA Game Studio 4.0 Refresh for your reference needs.
Logged
Thendash's Livestream

This game could honestly give out hand jobs for free and people would still bitch.

Valid_Dark

  • Bay Watcher
  • If you wont let me Dream, I wont let you sleep.
    • View Profile
Re: Programming Challenges & Resources (#bay12prog) Initiative
« Reply #1159 on: July 05, 2012, 06:14:04 pm »

I haven't touched programming in a few months, but last night I decided to do another projecteuler problem, I was on problem 12 so I did that one, cuz I don't like to jump around.
anyways,
I started off with a brute force attempt, took my program 30 minutes to find the answer, then some optimization, then took 11 minutes, then took 5 minutes, and my finished program was able to find the answer in 0.19 seconds.
took me like 4 hours though >_<  oohhhh and I did it all without looking at my notes or anything.
I rather enjoy project Euler, 
I'm spending today going over my old notes (have about 100 pages of notes so far)  then tomorrow going to continue my learning.
sry for random post, wanted to tell someone about my Euler adventure, and this seemed like an appropriate place.
Logged
There are 10 types of people in this world. Those that understand binary and those that don't


Quote
My milkshake brings all the criminals to justice.

TolyK

  • Bay Watcher
  • Nowan Ilfideme
    • View Profile
Re: Programming Challenges & Resources (#bay12prog) Initiative
« Reply #1160 on: July 06, 2012, 12:56:07 pm »

Neat! Also, thanks for reviving this thread...

Can anyone help me (hopefully in Visual Basic, though psuedocode or just pointers) how to dissect the raws of DF into objects? I'm trying this myself, but the creatures are just giving me HEADACHES. Maybe I should do a tree-like thing, or...?
Logged
My Mafia Stats
just do whatevery tolyK and blame it as a bastard mod
Shakerag: Who are you personally suspicious of?
At this point?  TolyK.
Pages: 1 ... 76 77 [78]