I need to update Kos or something...

Whether you're a newbie or an experienced programmer, any questions, help, or just talk of any language will be welcomed here.

Moderator: Coders of Rage

Post Reply
User avatar
JS Lemming
Game Developer
Game Developer
Posts: 2383
Joined: Fri May 21, 2004 4:09 pm
Location: C:\CON\CON

I need to update Kos or something...

Post by JS Lemming »

Hey Gyrovorbis, have you had to update your Dc development files ever? I couldn't get the STD <list> to work and peeps at DCemulation.com say I need to upgrade. How did you go about doing this? And if you didn't, what technique did you use for the blood spray demo, linked list speaking?

Do you know anything about this either Tvspelsfreak?
Small girl at the harbor wrote:Look Brandon, that crab's got ham!
User avatar
Falco Girgis
Elysian Shadows Team
Elysian Shadows Team
Posts: 10294
Joined: Thu May 20, 2004 2:04 pm
Current Project: Elysian Shadows
Favorite Gaming Platforms: Dreamcast, SNES, NES
Programming Language of Choice: C/++
Location: Studio Vorbis, AL
Contact:

Post by Falco Girgis »

Yes, my friend, sadly, it is time for an upgrade.

Tvspelsfreak and I have both upgraded our devving environments to the latest 'n' greatest.

First of all, you're going to need a lot of space on your hard drive. You need a Linux shell (Cygwin) to build to Dreamcast executable.

The very best method is going to be using the DC Dev ISO. It's an ISO that you burn to a CD and run the wizard. It pretty much sets the whole thing up.

You're going to have to learn to use makefiles from now on, and alot of stuff is much harder with this setup, but it's alot easier.

If you need any help, we're both here. I'm going to be getting back into DC Devving shortly (read the topic in General/Off-topic and you'll know what I mean).

On the subject of linked lists, I didn't use the standard template library with templates or vectors, just straight up linked lists.

I'll show you some code.

Particlez.h

Code: Select all

void CreatePart(int x, int y, double angle, int intensity, uint8 max_partlife, uint16 size, uint8 color, uint8 a, uint8 r, uint8 g, uint8 b, uint32 &onscreen);
void UpdatePart(float gravity, uint32 &onscreen); //Updates particle physics
void DrawPart(uint8 max_partlife); //Draws particles
void CleanupPart();

class Part {
public:
	Part() {
		next = NULL;
		prev = NULL;
	}
	
	void Draw();
	void Update();

	float x, y;
    float xvel, yvel;
    int life, size;
	uint8 color, a, r, g, b;

    Part *next;
	Part *prev;
};

Part *first_part, *last_part;
Particlez.cpp

Code: Select all

void CreatePart(int x, int y, double angle, int intensity, uint8 max_partlife, uint16 size, uint8 color, uint8 a, uint8 r, uint8 g, uint8 b, uint32 &onscreen) {
	Part *part;
	double relative_angle;

	for(int i = 0; i < intensity; i++) {
		part = NULL;
		part = new Part;
        
		if(!first_part) {
		    first_part = part;
			part->prev = NULL;
		} else {
            last_part->next = part;
			part->prev = last_part;
		}
        
		last_part = part;
		part->next = NULL;
    }
}



void UpdatePart(float gravity, uint32 &onscreen) {
	Part *part;
	Part *nextpart;

	for(part = first_part; part;) {
		
		if(!part) break;
		
		nextpart = part->next;

		if(part->life <= 0) {
			if (part == first_part && part == last_part) {
				first_part = NULL;
				last_part = NULL;
			} else {
				if (part == first_part) {
					first_part = part->next;
				} else if(part == last_part) {
					last_part = part->prev;
				}
			}

			if(part->prev) part->prev->next = part->next;
			if(part->next) part->next->prev = part->prev;			
			part->next = NULL;
			part->prev = NULL;
			
			
			delete part;
			part = NULL;
			onscreen--;
		} else {

                     //Update the particle, it's still alive

		}
	part = nextpart;
	}
}
I tried to not post the irrelevent crap. I'm sure that's really hard to understand as is, because it isn't really commented or anything. But that is the particle engine (minus the draw function, cleanup function, and "particle" related things like adjusting velocities, setting colors and crap).
User avatar
Falco Girgis
Elysian Shadows Team
Elysian Shadows Team
Posts: 10294
Joined: Thu May 20, 2004 2:04 pm
Current Project: Elysian Shadows
Favorite Gaming Platforms: Dreamcast, SNES, NES
Programming Language of Choice: C/++
Location: Studio Vorbis, AL
Contact:

Post by Falco Girgis »

Sorry, but I just had to come back and recommend that you get on MSN some time.

You really do need to update your DC toolchain completely and this new setup will be completely different and especially intimidating if you haven't done this kind of crap before.

It's a pretty big deal as the installation is around 1 gigabyte. I wouldn't want you to screw it up. But when you're ready just meet me on MSN (I should be on to walk you through it).

The only problem with our current setup is that it only works with an outdated version of KOS (which until recently wasn't a problem for me). That old KOS has crappy C++ support and no STL for you!

Trust me, you'll be happy you switched when it's all over with.
User avatar
JS Lemming
Game Developer
Game Developer
Posts: 2383
Joined: Fri May 21, 2004 4:09 pm
Location: C:\CON\CON

Post by JS Lemming »

Wha! Have I been saying "Std" this hole time!!! :lol:

Anyway...
Gyrovorbis wrote:The only problem with our current setup is that it only works with an outdated version of KOS (which until recently wasn't a problem for me). That old KOS has crappy C++ support and no STL for you!
Are you reffering to the setup I currently have or the one I'm about to upgrade to that doesn't support stl?

Okay another thing... I have 11 gig left on my drive, but I think the real problem is how do I obtain a 1 gig ISO with dial-up? Impossible. Unless its heavily compressed or something.

I really want to upgrade this mug.
Small girl at the harbor wrote:Look Brandon, that crab's got ham!
Tvspelsfreak
Chaos Rift Junior
Chaos Rift Junior
Posts: 272
Joined: Wed Sep 29, 2004 5:53 pm
Favorite Gaming Platforms: NES, SNES
Programming Language of Choice: C/C++
Location: Umeå, Sweden
Contact:

Post by Tvspelsfreak »

217MB. It's still pretty insane considering you're on dial-up.
User avatar
Falco Girgis
Elysian Shadows Team
Elysian Shadows Team
Posts: 10294
Joined: Thu May 20, 2004 2:04 pm
Current Project: Elysian Shadows
Favorite Gaming Platforms: Dreamcast, SNES, NES
Programming Language of Choice: C/++
Location: Studio Vorbis, AL
Contact:

Post by Falco Girgis »

Tvspelsfreak wrote:217MB. It's still pretty insane considering you're on dial-up.
Yeah, he got to around 1% after 10 minutes... XD
quarn
Dreamcast Developer
Dreamcast Developer
Posts: 9
Joined: Wed Feb 02, 2005 10:33 am

Post by quarn »

You could always burn a cd and snail mail it...
User avatar
Falco Girgis
Elysian Shadows Team
Elysian Shadows Team
Posts: 10294
Joined: Thu May 20, 2004 2:04 pm
Current Project: Elysian Shadows
Favorite Gaming Platforms: Dreamcast, SNES, NES
Programming Language of Choice: C/++
Location: Studio Vorbis, AL
Contact:

Post by Falco Girgis »

quarn wrote:You could always burn a cd and snail mail it...
:lol:

quarn is right, I should do that. JSL, I'm going to assume that you never got it downloaded, as you never got back to me so that I could help you set it up.

Man, it's like Tvspels said the other day, I can't believe people are still on dial up. I wish it would just become obsolete...
User avatar
JS Lemming
Game Developer
Game Developer
Posts: 2383
Joined: Fri May 21, 2004 4:09 pm
Location: C:\CON\CON

Post by JS Lemming »

ArG! This is disgusting.... Today is the begining of day 3 of the massive download... Guess what percentage it is at right now...... 48%. Maddness I tell you.

Well, Wutai (the neighbor of me) has just recently picked up a cd burner, so maybe I can ask him to download the mug with his new fangle fast internet. I'm with you Gyrovorbis... Ban dial-up!
Small girl at the harbor wrote:Look Brandon, that crab's got ham!
Post Reply