anyone wanna make an UGH! remake?

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

User avatar
avansc
Respected Programmer
Respected Programmer
Posts: 1708
Joined: Sun Nov 02, 2008 6:29 pm

Re: anyone wanna make an UGH! remake?

Post by avansc »

http://download352.mediafire.com/nn9dem ... 4y/UGH.rar

in all its glory.

PixelP made this game!
Some person, "I have a black belt in karate"
Dad, "Yea well I have a fan belt in street fighting"
User avatar
PixelP
Chaos Rift Regular
Chaos Rift Regular
Posts: 153
Joined: Tue Oct 07, 2008 12:23 pm
Programming Language of Choice: c/c++
Location: sweden
Contact:

Re: anyone wanna make an UGH! remake?

Post by PixelP »

avansc wrote:http://download352.mediafire.com/nn9dem ... 4y/UGH.rar

in all its glory.

PixelP made this game!
Man, that's great! You can't say that I made the game.
User avatar
PixelP
Chaos Rift Regular
Chaos Rift Regular
Posts: 153
Joined: Tue Oct 07, 2008 12:23 pm
Programming Language of Choice: c/c++
Location: sweden
Contact:

Re: anyone wanna make an UGH! remake?

Post by PixelP »

It's 5:40 here and I'm going to bed...
User avatar
trufun202
Game Developer
Game Developer
Posts: 1105
Joined: Sun Sep 21, 2008 12:27 am
Location: Dallas, TX
Contact:

Re: anyone wanna make an UGH! remake?

Post by trufun202 »

avansc wrote:http://download352.mediafire.com/nn9dem ... 4y/UGH.rar

in all its glory.

PixelP made this game!
Well damn, I was gonna check it out, but a spyware install popped up when I tried to download it. :(
-Chris

YouTube | Twitter | Rad Raygun

“REAL ARTISTS SHIP” - Steve Jobs
User avatar
avansc
Respected Programmer
Respected Programmer
Posts: 1708
Joined: Sun Nov 02, 2008 6:29 pm

Re: anyone wanna make an UGH! remake?

Post by avansc »

PixelP wrote:It's 5:40 here and I'm going to bed...

yeah i can, you gave the design ideas. the collision code. i just implimented it for you.
tomorrow we will make a level saver and loader, so that sohuld eb fun.
Some person, "I have a black belt in karate"
Dad, "Yea well I have a fan belt in street fighting"
MakazeGamer
Chaos Rift Newbie
Chaos Rift Newbie
Posts: 26
Joined: Wed Oct 29, 2008 10:48 pm

Re: anyone wanna make an UGH! remake?

Post by MakazeGamer »

This is really really cool lol, I like how you guys document it sorta here so that way everybody can see it.
User avatar
PixelP
Chaos Rift Regular
Chaos Rift Regular
Posts: 153
Joined: Tue Oct 07, 2008 12:23 pm
Programming Language of Choice: c/c++
Location: sweden
Contact:

Re: anyone wanna make an UGH! remake?

Post by PixelP »

avansc wrote:
PixelP wrote:It's 5:40 here and I'm going to bed...

yeah i can, you gave the design ideas. the collision code. i just implimented it for you.
tomorrow we will make a level saver and loader, so that sohuld eb fun.
I've been reading trough all the code and I get everything but the update_Player function...

Code: Select all

void physics::update_Player(player *p)
{
	float g = 9.8;
	g *= p->weight;
	g *= 0.0001;
	p->yA += g;

	p->x += p->xA;
	p->y += p->yA;

	for(int a = 0;a < this->temp->object_Count;a++)
	{
		if(this->col(&this->temp->data[a], p))
		{
			p->x -= p->xA;
			p->y -= p->yA;
			p->yA = 0;
			p->xA = 0;
			return;
		}
	}

}
Can you comment it up?
User avatar
PixelP
Chaos Rift Regular
Chaos Rift Regular
Posts: 153
Joined: Tue Oct 07, 2008 12:23 pm
Programming Language of Choice: c/c++
Location: sweden
Contact:

Re: anyone wanna make an UGH! remake?

Post by PixelP »

The collision is not perfect, I think... http://willhostforfood.com/files3/7821061/col.wmv
Looks like objects can't be smaller then the player...
User avatar
PixelP
Chaos Rift Regular
Chaos Rift Regular
Posts: 153
Joined: Tue Oct 07, 2008 12:23 pm
Programming Language of Choice: c/c++
Location: sweden
Contact:

Re: anyone wanna make an UGH! remake?

Post by PixelP »

I've made some changes so you can add color to your objects...

Code: Select all

#include "object.h"

#ifndef _level_h
#define _level_h

class level
{
public:
	level();
	void add_Object(int x, int y, int w, int h, int r, int g, int b);
	object data[10];
	int object_Count;
private:
};

#endif

Code: Select all

#include "level.h"

level::level()
{
	this->object_Count = 0;
}

void level::add_Object(int x, int y, int w, int h, int r, int g, int b)
{
	if(this->object_Count < 9)
	{
		this->data[this->object_Count] = object(x, y, w, h, r, g, b);
		this->object_Count++;
	}

}

Code: Select all

#ifndef _object_h
#define _object_h

class object
{
public:
	object();
	object(int x, int y, int w, int h, int r, int g, int b);
	int x;
	int y;
	int w;
	int h;
	int r;
	int g;
	int b;
private:
};

#endif

Code: Select all

#include "object.h"

object::object()
{
	this->x = 0;
	this->y = 0;
	this->w = 0;
	this->h = 0;
	this->r = 255;
	this->g = 255;
	this->b = 255;
}

object::object(int x, int y, int w, int h, int r, int g, int b)
{
	this->x = x;
	this->y = y;
	this->w = w;
	this->h = h;
	this->r = r;
	this->g = g;
	this->b = b;
}

Code: Select all

void GFX::draw_Object(object *obj)
{
	rectangleRGBA(this->screen, obj->x, obj->y, obj->x+obj->w, obj->y+obj->h, obj->r, obj->g, obj->b, 255);
}
User avatar
avansc
Respected Programmer
Respected Programmer
Posts: 1708
Joined: Sun Nov 02, 2008 6:29 pm

Re: anyone wanna make an UGH! remake?

Post by avansc »

PixelP wrote:The collision is not perfect, I think... http://willhostforfood.com/files3/7821061/col.wmv
Looks like objects can't be smaller then the player...

yeah i saw that last night. its an easy fix tho.
Some person, "I have a black belt in karate"
Dad, "Yea well I have a fan belt in street fighting"
User avatar
PixelP
Chaos Rift Regular
Chaos Rift Regular
Posts: 153
Joined: Tue Oct 07, 2008 12:23 pm
Programming Language of Choice: c/c++
Location: sweden
Contact:

Re: anyone wanna make an UGH! remake?

Post by PixelP »

avansc wrote:
PixelP wrote:The collision is not perfect, I think... http://willhostforfood.com/files3/7821061/col.wmv
Looks like objects can't be smaller then the player...

yeah i saw that last night. its an easy fix tho.
Good.
User avatar
avansc
Respected Programmer
Respected Programmer
Posts: 1708
Joined: Sun Nov 02, 2008 6:29 pm

Re: anyone wanna make an UGH! remake?

Post by avansc »

so pixelp, do you wanna make a level loader and saver for our game?
Some person, "I have a black belt in karate"
Dad, "Yea well I have a fan belt in street fighting"
User avatar
PixelP
Chaos Rift Regular
Chaos Rift Regular
Posts: 153
Joined: Tue Oct 07, 2008 12:23 pm
Programming Language of Choice: c/c++
Location: sweden
Contact:

Re: anyone wanna make an UGH! remake?

Post by PixelP »

avansc wrote:so pixelp, do you wanna make a level loader and saver for our game?
Hell yeah!
User avatar
avansc
Respected Programmer
Respected Programmer
Posts: 1708
Joined: Sun Nov 02, 2008 6:29 pm

Re: anyone wanna make an UGH! remake?

Post by avansc »

PixelP wrote:
avansc wrote:so pixelp, do you wanna make a level loader and saver for our game?
Hell yeah!

okay buddy. im just gonna go out to supper. i'll be back in 45 min. then we will get cracking.
Some person, "I have a black belt in karate"
Dad, "Yea well I have a fan belt in street fighting"
User avatar
PixelP
Chaos Rift Regular
Chaos Rift Regular
Posts: 153
Joined: Tue Oct 07, 2008 12:23 pm
Programming Language of Choice: c/c++
Location: sweden
Contact:

Re: anyone wanna make an UGH! remake?

Post by PixelP »

avansc wrote:
PixelP wrote:
avansc wrote:so pixelp, do you wanna make a level loader and saver for our game?
Hell yeah!

okay buddy. im just gonna go out to supper. i'll be back in 45 min. then we will get cracking.
Sounds good... have a nice meal.
Post Reply