Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 22 23 [24] 25 26 ... 57

Author Topic: Back to the dwarf game...  (Read 197065 times)

Toady One

  • The Great
    • View Profile
    • http://www.bay12games.com
Re: Back to the dwarf game...
« Reply #345 on: September 21, 2005, 09:51:00 am »

I haven't been posting those kinds of dwarf movies!
Logged
The Toad, a Natural Resource:  Preserve yours today!

Toady One

  • The Great
    • View Profile
    • http://www.bay12games.com
Re: Back to the dwarf game...
« Reply #346 on: September 21, 2005, 12:13:00 pm »

I finally found a memory leak detection program that works well for me.  When I quit dwarves, it highlights all of the memory allocations that went bad.  For instance, we had one:

if(pointer==NULL)delete pointer;

this should be

if(pointer!=NULL)delete pointer;

I have a few more of those to clean up, and then it'll be going by the numbers again.

Logged
The Toad, a Natural Resource:  Preserve yours today!

Gezol

  • Bay Watcher
    • View Profile
Re: Back to the dwarf game...
« Reply #347 on: September 21, 2005, 08:36:00 pm »

About the smaller projects- I think any game that involves a random 80s song generator is likely to be a work of pure genius, so I vote you do that one. Or the forest spirit one. That's an idea I don't think I've seen before in a game, and it appeals to me, tree-hugging bleeding-heart environmentalist wacko that I am...

Anyway, Toady, I just sent you a private message with my easter egg guess.

Logged

Toady One

  • The Great
    • View Profile
    • http://www.bay12games.com
Re: Back to the dwarf game...
« Reply #348 on: September 21, 2005, 09:05:00 pm »

I have responded to your message.

If it helps, the working titles for the 80s game and the forest game, respectively, are:

Star Team:  Turbo Fleet Nation

and

Little Lord Animals:  Child Forest Apocalypse

Logged
The Toad, a Natural Resource:  Preserve yours today!

Svirfneblim

  • Bay Watcher
    • View Profile
Re: Back to the dwarf game...
« Reply #349 on: September 22, 2005, 08:34:00 am »

Toady, i'm dabbling(amateurish) in c++ and would be grateful for your advice.
What exactly is a way that the new and delete functions should be used?
I know that they assign memory, but when i should assign that memory to something?
I just declare all the variables i need in the code, map is loaded from a .txt file and that's it.
Summing it up: i don't use new and delete, but should i?
Can allocating memory speed up something?
Logged

Toady One

  • The Great
    • View Profile
    • http://www.bay12games.com
Re: Back to the dwarf game...
« Reply #350 on: September 22, 2005, 10:02:00 am »

In a larger project, you'd want to allocate things as they are needed, and free them as they aren't needed -- even though there is a lot of memory on computers these days, people also run a lot of applications, so you shouldn't go overboard.

It's also convenient to use new/delete if you want to get rid of something when it is dead, and not have to worry about "is_dead" flags and things like that.

In addition, if you are really doing C++ as opposed to C, the new operator lets you allocate a derived class object, use the base class for it in very general functions, and then delete it when you are done (possibly using a base class pointer again and "new" to create a different derived class object).  Having pre-declared variables around won't let you do that, unless you actually declare the derived class objects everywhere in advance, which sort of defeats the purpose of OO programming.

[ September 22, 2005: Message edited by: Toady One ]

Logged
The Toad, a Natural Resource:  Preserve yours today!

Toady One

  • The Great
    • View Profile
    • http://www.bay12games.com
Re: Back to the dwarf game...
« Reply #351 on: September 22, 2005, 02:10:00 pm »

All mem leaks that the program found have been cleaned.
Logged
The Toad, a Natural Resource:  Preserve yours today!

Gezol

  • Bay Watcher
    • View Profile
Re: Back to the dwarf game...
« Reply #352 on: September 22, 2005, 10:25:00 pm »

I replied to your reply, but I'm not quite sure it went through...

Say, Toady, am I right in remembering that you're in Texas? I assume you're out of the way of the hurricane, as I doubt you'd be spending time today working on the game if you were in its path- but I was just wondering. Stay safe...

Logged

Toady One

  • The Great
    • View Profile
    • http://www.bay12games.com
Re: Back to the dwarf game...
« Reply #353 on: September 22, 2005, 11:04:00 pm »

Actually, I'm in Bryan, which is not too far north of Houston, right in the projected path.  Dead toads.  I see them on the road.  Now they'll be in my home.  Classes are cancelled tomorrow.  It should weaken a bit before it gets here, but people are stocking up.  What else am I going to do though?  Programming is fun.  I'll get some water together in case the power goes out I guess.

Reply came through.  I'll read it after this -- the private message system is kind of weird.  It sort of seems like everything is erased when you send.

Logged
The Toad, a Natural Resource:  Preserve yours today!

Gezol

  • Bay Watcher
    • View Profile
Re: Back to the dwarf game...
« Reply #354 on: September 23, 2005, 12:13:00 am »

Well, I figured that if you were in too much danger from it you would be leaving. Though from what I heard about that traffic jam, staying put might actually be the wiser course of action...
Sounds like you aren't in the most dangerous part, but... man. Be careful. I'm hoping everything turns out OK.

Yeah, the message erasing thing is why I wasn't sure if it had gone through...

Logged

Toady One

  • The Great
    • View Profile
    • http://www.bay12games.com
Re: Back to the dwarf game...
« Reply #355 on: September 23, 2005, 09:49:00 am »

TOAD IS HERE

Rita has been veering east a bit, so as it stands, I'll be catching more of the western part of it rather than the eye wall, hopefully.

Edit:  We've been advised that power will probably go out, so if I'm away for a few days, well...  I won't be programming then either.

[ September 23, 2005: Message edited by: Toady One ]

Logged
The Toad, a Natural Resource:  Preserve yours today!

Aquillion

  • Bay Watcher
    • View Profile
Re: Back to the dwarf game...
« Reply #356 on: September 23, 2005, 12:57:00 pm »

Just remember:  You need a line of floodgates to stop a flood, not just one.  Don't share poor Norndarnòrn's fate.

...hrm, are there hurricanes and similar dangerous weather conditions in Dwarf Fortress?

Logged
We don't want another cheap fantasy universe, we want a cheap fantasy universe generator. --Toady One

Toady One

  • The Great
    • View Profile
    • http://www.bay12games.com
Re: Back to the dwarf game...
« Reply #357 on: September 23, 2005, 01:18:00 pm »

Right now, bad weather just makes people bitter if they have to work outside (unless they have the right personality for it).  Well...  thin river ice is to be avoided, and that's seasonal at least.  They'll avoid it on their own, but if you station soldiers there, I think they might go for it.

You know, thinking about frost-bite, even though they are shorter, I kind of imagine dwarves having larger toes.  Would that mean they wouldn't suffer from it as quickly?

Logged
The Toad, a Natural Resource:  Preserve yours today!

Demon

  • Bay Watcher
  • From a time before a time before time
    • View Profile
Re: Back to the dwarf game...
« Reply #358 on: September 23, 2005, 06:33:00 pm »

Dwarves are way too tough for wussy frostbite!  Weather in general probably shouldn't be of much concern to them, with the exception of tunnel flooding.  (If that can even be counted...)

Remember taking your GREs Toad?  I took the general exam already (perfect math score, w00t) but I have the nasty subject exam next month.

Logged

Toady One

  • The Great
    • View Profile
    • http://www.bay12games.com
Re: Back to the dwarf game...
« Reply #359 on: September 23, 2005, 06:45:00 pm »

I vaguely remember -- there was a englishy section, and quantitative, and something else.   It was disconcerting how it just spit the score out on the computer right when you finish.  Then there's the subject test.  I got something like 45/66 on mine (screw all that probability!), but I got a perfect 990.  Must have been a hard year?  Dunno.  What are you planning to do with yourself anyway?  Applications going on now or next year?
Logged
The Toad, a Natural Resource:  Preserve yours today!
Pages: 1 ... 22 23 [24] 25 26 ... 57