Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - jaked122

Pages: 1 ... 19 20 [21] 22 23 ... 73
301
A computer virus that... acts like a vaccine?
I was wondering when something like this would happen. Isn't it great?

302
General Discussion / Re: if self.isCoder(): post() #Programming Thread
« on: October 03, 2015, 03:46:58 pm »
Yeah, git is great once you get used to it and I recommend anybody who can't use it to learn to use it.
It's been so long since I started using it that I just know how to look everything up. I can't remember having issues. It's a lot better than svn. That's not hard. Fossil is better than SVN, as is DARCS, Mercurial(hg) or any other distributed scm.

Also github just looks good. That's why I prefer it to the alternatives like bitbucket or sourceforge(do they still host code?).

303
General Discussion / Re: if self.isCoder(): post() #Programming Thread
« on: October 03, 2015, 02:53:38 pm »
Not so much a programming question but where would be a good place to keep all of my programming projects for possible employers/curious individuals to see?
I've heard that it is pretty much industry standard to examine github pages. Those are generally better looking and have the upside of not requiring a curious programmer to deal with archives if they have git installed. Which they should.

Git is the best.

I should make a tutorial on git actually. That could be useful here.

304
General Discussion / Re: if self.isCoder(): post() #Programming Thread
« on: September 27, 2015, 02:07:25 pm »
SFML is a library that I'm a bit familiar with, but the one thing that surprises me is that some people on stackoverflow recommend it for typical gui programming. I have to wonder if they don't understand the question, or perhaps are advocating fluid uis coded from scratch out of more primitive SFML primitives. Which has ups and downs, but mostly a lot more code than most people would like to implement for themselves.

I hope that's what they're doing, rather than misunderstanding the question.

305
General Discussion / Re: Nitpicks that Ruined Movies
« on: September 26, 2015, 07:54:22 pm »
This thread started 3 years ago. The majority of criticisms seem to be about Avatar. None of them mention how it's Pocahontas in space.

Tell me how it isn't.
Spoiler (click to show/hide)

306
General Discussion / Re: if self.isCoder(): post() #Programming Thread
« on: September 26, 2015, 04:14:30 pm »
I'll decompile some C/C++ code and post what comes out and try to figure it out. Pointers as well. Char arrays. Pointer manipulation and what happens. I figure someone will find it interesting-- I know I did years ago when I first saw the machine code and assembly output on my screen and went 'wooooah... wait wtf is this crap?'
don't bother disassembling C or C++, it's only worth it for languages like java, c#, visual basic, or managed c++, but not often then.

Just download some C++ code, randomly, find the most obscure program with open source code, and poke around it, wondering why the person made that program, then how it works. Or start writing code for CataclysmDDA, which is what I did most recently. That was fun.

Added working street sweepers to a zombie roguelike. That makes sense, right?

307
General Discussion / Re: if self.isCoder(): post() #Programming Thread
« on: September 26, 2015, 03:59:04 pm »

Something else to keep in mind: when using C++, you should generally avoid this sort of multidimensional array. Calls to malloc are expensive.
--snip
Or you can get a different memory allocation scheme such as the one discussed here, http://goog-perftools.sourceforge.net/doc/tcmalloc.html,
 which looks quite fast. Ultimately you have to understand that you don't want to allocate this kind of thing once, generally. You can reuse the addresses returned as much as you want.

Alternately you can reimplement something like the std::array class and build a custom addressing mechanism. It would look something like
Code: [Select]
template<int N> class m_array_addr{
   size_t args[N];
   public:
     m_array_addr(size_t *args){
        this->args = new size_t[N];
        for(int i=0;i<N;i++)
             this->args[i]=args[i];
    }
};
template<typename T, int N> class multi_array{
 private:
   T *data;
   size_t rank[N];//the number of elements in each dimension
 public:
   T& operator[](const m_array_addr<N>& indx)const{
       size_t index=0;
       for(int i=0;i<N;i++)
           index= indx.args[i]+index*rank[i];
       return data[index];
   }
   
};

I think that's right. It has been a while since I did something akin to this, and that indexing thing is horner's rule, so it ought to work with efficiency about as good as you'll get with machine sized words.

This isn't relevant but  const_cast, reinterpret_cast and static_cast are the most delightful way to smash reference control and make things mutable inside of const methods.

308
DF Modding / Re: Furry Fortress 2 - Baby Snatchers, Baby!
« on: September 23, 2015, 02:22:50 pm »
Just for clarification, my fortress of komodos is starving despite having a full stockpile of cooked fish. Do they prefer to eat raw corpses?

 They certainly don't eat the various plants that they've found.

309
Quote
You would be a infamous necromancer who would live on the roads, and you would die in the canyons of Purplecry, during an ambush.


Hmm, perhaps I should cancel my vacation there.

310
DF Dwarf Mode Discussion / Re: What's going on in your fort?
« on: March 17, 2015, 01:02:44 pm »
Its been a while, but I was surprised by the dwarves' choice in leadership.
Spoiler (click to show/hide)

311
Good job on getting these things out so quickly.

312
Utilities and 3rd Party Applications / [idea] Dancefortress
« on: July 19, 2014, 10:33:30 am »
Hi people of the forum, I'm at a hackathon today, they happen to be bringing ddr pads with usb adapters(or something similar), and I had this wonderful, awful, terrible idea,  Why not control dwarf fortress with a ddr pad? It can't be that bad right?

Is there any interest in this utility?

313
DF Modding / Re: [MODDING] 0.40.x QUESTIONS THREAD
« on: July 08, 2014, 09:21:21 pm »
I'm back with information, if you want to have your dwarves be obnoxiously fast, add the tag
[APPLY_CREATURE_VARIATION:STANDARD_BIPED_GAITS:1:1:1:1:1:0]

to dwarves. This is useful to know...

314
DF Modding / Re: [MODDING] 0.40.x QUESTIONS THREAD
« on: July 07, 2014, 10:55:16 pm »
Hey guys, can anyone get the SPEED tag to work? I can't cheat like I used to.
 :'(

Anyway, not terribly important, but I'd like to know if it still works.

EDIT: Welp, now that I can't use SPEED, is there an alternative?
It appears that the more complex [GAIT] is now used.

I'm looking forwards to a more extensive explaination.

315
DF Modding / Re: [MODDING] 0.40.x QUESTIONS THREAD
« on: July 07, 2014, 10:48:39 pm »
Hey guys, can anyone get the SPEED tag to work? I can't cheat like I used to.
 :'(

Anyway, not terribly important, but I'd like to know if it still works.

EDIT: Welp, now that I can't use SPEED, is there an alternative?

Pages: 1 ... 19 20 [21] 22 23 ... 73