Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 79 80 [81] 82 83 ... 796

Author Topic: if self.isCoder(): post() #Programming Thread  (Read 909060 times)

Vector

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1200 on: February 03, 2012, 12:15:25 am »

Still rolln with pigs?
How much functionality can you possibly be giving this game?

It's kind of evolved into a tournament-style game which I'm going to write one of those horrible old-fashioned video game plots for.  I'm not sure quite what the plan is, though, so I'm going to spend some time thinking and designing, and then I'm going to get programming.  I have two conflicting ideas right now.

Booyaka!
Logged
"The question of the usefulness of poetry arises only in periods of its decline, while in periods of its flowering, no one doubts its total uselessness." - Boris Pasternak

nonbinary/genderfluid/genderqueer renegade mathematician and mafia subforum limpet. please avoid quoting me.

pronouns: prefer neutral ones, others are fine. height: 5'3".

GlyphGryph

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1201 on: February 03, 2012, 12:53:15 am »

Is any of that... actually... relevant, to the assignment? Not to say you shouldn't have fun with it, of course. :P

Not that its terribly uncommon for good programming students to go way above and beyond the call of duty. Just remember that there is value in focus as well.
« Last Edit: February 03, 2012, 12:55:02 am by GlyphGryph »
Logged

Vector

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1202 on: February 03, 2012, 01:03:27 am »

It's not relevant, but I'm an angry math student who works out her frustrations with other people's stupidity via overdoing stuff... and right now, the sheer blinding stupidity of my fellow students is rage-making.
Logged
"The question of the usefulness of poetry arises only in periods of its decline, while in periods of its flowering, no one doubts its total uselessness." - Boris Pasternak

nonbinary/genderfluid/genderqueer renegade mathematician and mafia subforum limpet. please avoid quoting me.

pronouns: prefer neutral ones, others are fine. height: 5'3".

GlyphGryph

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1203 on: February 03, 2012, 01:08:10 am »

* GlyphGryph gives Vector a comforting look.

There there, it could be worse. You could be the TA.

Here's a quote from my friends TA experiences in a programming class today:
Quote
Grading makes me sad.
1+2+3+4 does not equal 8, nor does it equal 12.
...[later]...
Additionally, 2+3 does not equal 6. :(
...[responding to questions]...
For a Quiz. CSC211. No binary. Just adding numbers. Poorly.
For the first one, two instances of 8, and one of 12. For the second, two people had 6. I'm actually weeping coffee right now.
The first is *literally* add: evaluate 1 + 2 + 3 + 4
The second is evaluate "1" + (2 + 3) + 4


Edit
Oh my god, IRC commands fucking work on the message board?
Mind=blown
Logged

alway

  • Bay Watcher
  • 🏳️‍⚧️
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1204 on: February 03, 2012, 01:59:26 am »

Just be sure to create a backup of the work which satisfies the assignment parameters. Going above them is fine, but can go terribly wrong if doing so ends up taking too much time and results in having no working code to hand in. Debugging always takes twice as long as you expect it to, even if you take this sentence into account for your estimate.
Logged

Max White

  • Bay Watcher
  • Still not hollowed!
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1205 on: February 03, 2012, 02:22:51 am »

It's not relevant, but I'm an angry math student who works out her frustrations with other people's stupidity via overdoing stuff... and right now, the sheer blinding stupidity of my fellow students is rage-making.

They are software students, most of them are going to be pathetic little script kiddies that think understanding language syntax means understanding logical structure. They are incorrect. Given the proper amount of ass kicking over time once they are required to make larger programs, they will grow up, or drown.
Just don't let them get you down.

EDIT:
Is it considered cheating to use a basic library for stuff like drawing windows, by the way?  As a math student, I feel enormously... underhanded using less rudimentary stuff without knowing how it works.
Not by software standards. Hell, that is basically what SDL is for! Well other stuff too, but I wouldn't make a graphical application without one. Why reinvent the wheel, when the current design is very carefully thought out.
No idea what your professor Fruitloops would make of it, email him? Ask if it is ok? Include the name of the specific library.

Siquo

  • Bay Watcher
  • Procedurally generated
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1206 on: February 03, 2012, 03:49:13 am »

What's people's opinions of SDL? It sounds like a higher level version of what libctod is about, handling input, graphics, events, ect. Thoughts?
SDL can actually be used to base a real 3D-graphics-multiplayer-and-everything game on. Personally, I dropped it in favour of SFML. On the subject of rogue-likes and 2d spritestuff I'm not that knowledgeable, but SDL is more powerful in a quite a few aspects, while libtcod saves you lots of time by doing stuff for you (never exactly the way you want it, but it's still pretty good at what it does).

So if you're making something roguelikeish, I'd go for libtcod until you reach a tipping point where libtcod starts to annoy you more than that it's helping.
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))

Max White

  • Bay Watcher
  • Still not hollowed!
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1207 on: February 03, 2012, 04:11:48 am »

So if you're making something roguelikeish, I'd go for libtcod until you reach a tipping point where libtcod starts to annoy you more than that it's helping.
We call this point keyboard input. It comes right between the hard work of building a good level gen, and the reward of being able to use it.
Murphy strikes again!

Siquo

  • Bay Watcher
  • Procedurally generated
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1208 on: February 03, 2012, 04:35:57 am »

Well, it works okay for nethack-one-char-at-a-time-entry. Actually holding a button is crap, indeed.
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))

Max White

  • Bay Watcher
  • Still not hollowed!
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1209 on: February 03, 2012, 04:38:48 am »

*Making a multi player roguelike*
*Real time required*
*Pressing the button over and over is annoying as fuck in real time*

Good sir, while I respect your opinion, I am prone to disagree.

Siquo

  • Bay Watcher
  • Procedurally generated
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1210 on: February 03, 2012, 04:50:56 am »

I don't think we disagree. As I said, it works fin for turn-based, one-button-at-a-time, nethack/rogue-like stuff. Having made my own real-time thing in libtcod I know its limitations, and agree that it's crap for that specific purpose. It's even more annoying that there's no way around it in libtcod, even though it's as simple as adding a keydown/keyup instead of keypress... Being able to use SDL for the input is actually a pretty good solution, as SDL does that stuff right.

I had some really nice SDL tutorials but can't find them with google anymore. Its input-handling, gameloop and gamestate were very well done. Myabe I've got some bookmarks at home, I'll try and find them.
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))

Max White

  • Bay Watcher
  • Still not hollowed!
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1211 on: February 03, 2012, 04:55:37 am »

If you could find them, I would be forever grateful... And if you can find them in c#? My god I would feel spoilt!

Edit: In other news, getting well acquainted with old python again. As far as I can recall nobody else here is fluent in it, so might be useful for tec support. Why does everything about this language bring out the worst practices in me? Making things private? Na, too much effort for too little gain.

Aqizzar

  • Bay Watcher
  • There is no 'U'.
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1212 on: February 03, 2012, 05:31:50 am »

While I continue to truck with implementing Libtcod (I don't even know what all this gnashing of teeth about keyboard input is yet), I'm trying to at least get the window to display the right ASCII characters.  The "terminal.png" provided with the package is obviously ASCII_INCOL, but it appears to be displaying with the TCOD limited set.  Trying to tell it to use "terminal.png" is not going well.  Setting it to anything but the exact filename is instacrash (not finding the file I think), and "terminal.png" still displays as if it were TCOD even though it's not.  That, or the numerical ASCII mapping has nothing to do with the actual ASCII mapping, since Dwarf Fortress uses the exact same set.

What the heck is wrong with this library...
Logged
And here is where my beef pops up like a looming awkward boner.
Please amplify your relaxed states.
Quote from: PTTG??
The ancients built these quote pyramids to forever store vast quantities of rage.

Max White

  • Bay Watcher
  • Still not hollowed!
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1213 on: February 03, 2012, 05:35:36 am »

It is a construct of convenience, not elegance.
One day I will pull my ass into gear and give you something better... Just gotta get things to print in color, and get the keyboard working a little better.

Xegeth

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #1214 on: February 03, 2012, 06:14:45 am »

Why not just ignore the libtcod input functions and use SDL directly? As a quick test I replaced my old code which looked like this:

Code: [Select]
TCOD_key_t key = TCODConsole::checkForKeypress(TCOD_KEY_PRESSED);
if(TCODConsole::isWindowClosed())
exit(0);
DoStuffWithKey(key);

with this:

Code: [Select]
#include "SDL/SDL.h"

...

SDL_Event event;
while(SDL_PollEvent(&event))
{
switch(event.type)
{
case SDL_KEYDOWN:
DoStuffWithEvent(event);
break;
case SDL_QUIT:
exit(0);
break;
}
}

There didn't seem to be any real problems with doing it like that, and you don't even need to initialize sdl because libtcod does everything for you. There is a chance I missed something though because I didn't test it much once I got the character walking around, and since it was in C++, C# may do things differently
« Last Edit: February 03, 2012, 06:17:38 am by Xegeth »
Logged
Pages: 1 ... 79 80 [81] 82 83 ... 796