Forum Topic: My First (working) 3d Engine

(6,990 views • 241 replies)

This topic is 9 pages long. [ 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 ]

<< < > >>
None

Mr-Money

Reply To Post Reply & Quote

Posted at: 2/3/09 05:25 PM

Mr-Money NEUTRAL LEVEL 16

Sign-Up: 11/05/05

Posts: 2,782

I don't see any reason why you shouldn't make it open source now. It would really speed up development.


None

zuperxtreme

Reply To Post Reply & Quote

Posted at: 2/3/09 05:26 PM

zuperxtreme NEUTRAL LEVEL 08

Sign-Up: 01/02/05

Posts: 1,629

Don't get me wrong, I'm not criticizing you. You're doing a great job, I only meant to say that you shouldn't worry about people decompiling and going through your code. No one is going to steal anything.


None

StaliN98

Reply To Post Reply & Quote

Posted at: 2/3/09 05:49 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

At 2/3/09 05:26 PM, zuperxtreme wrote: Don't get me wrong, I'm not criticizing you. You're doing a great job, I only meant to say that you shouldn't worry about people decompiling and going through your code. No one is going to steal anything.

I really want to imagine that, but I'm just too paranoid :).
Anyway, spent my time when I got home on a new plan for texture mapping. Failed spectacularly in a mess of low FPS and random coloured walls. So I spent the last half an hour adding a depth based shadow, enjoy! As always, needs criticism (and I know the wall clipping is shite, going to fix that tomorrow).

WASD move
MOUSE turn
SPACE jump
CTRL crouch
SHIFT detach mouse

http://spamtheweb.com/ul/upload/030209/8 2123_main.php


Elated

pawlakt

Reply To Post Reply & Quote

Posted at: 2/3/09 05:51 PM

pawlakt DARK LEVEL 09

Sign-Up: 04/04/08

Posts: 130

holy crap this is amazing!

BBS Signature

None

ColdLogic

Reply To Post Reply & Quote

Posted at: 2/3/09 06:02 PM

ColdLogic EVIL LEVEL 19

Sign-Up: 11/12/03

Posts: 524

its looking cooler everytime i see it, cant wait to see what you improove next. every once and a while i get a wall pop into view out of nowhere for a frame or so.


None

StaliN98

Reply To Post Reply & Quote

Posted at: 2/3/09 06:39 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

Yeah, me too. It will probably be something to do with me using ints all the time. I'll look into fixing it tomorrow.


None

kris008

Reply To Post Reply & Quote

Posted at: 2/3/09 06:48 PM

kris008 DARK LEVEL 10

Sign-Up: 05/11/07

Posts: 587

i got stuck in the wall :( dun like it in there.
really awsome tho...be incred if u cud make it a multiplayer server so you see other ppl walkin around, could just be a social hangout if you added a place to chat...then u can play hide and seek and stuffs heh. orrrrr just shoot eachother which 99% of the ppl who use this to make somthing will prob do.


None

Nuttro

Reply To Post Reply & Quote

Posted at: 2/4/09 12:35 AM

Nuttro LIGHT LEVEL 22

Sign-Up: 04/26/07

Posts: 848

I think you need to fix the double jump or something (I think it should be a single jump anyway).


None

Nano256

Reply To Post Reply & Quote

Posted at: 2/4/09 01:02 AM

Nano256 DARK LEVEL 13

Sign-Up: 02/12/05

Posts: 1,473

At 2/3/09 05:49 PM, StaliN98 wrote:
At 2/3/09 05:26 PM, zuperxtreme wrote: Don't get me wrong, I'm not criticizing you. You're doing a great job, I only meant to say that you shouldn't worry about people decompiling and going through your code. No one is going to steal anything.
I really want to imagine that, but I'm just too paranoid :).
Anyway, spent my time when I got home on a new plan for texture mapping. Failed spectacularly in a mess of low FPS and random coloured walls. So I spent the last half an hour adding a depth based shadow, enjoy! As always, needs criticism (and I know the wall clipping is shite, going to fix that tomorrow).

WASD move
MOUSE turn
SPACE jump
CTRL crouch
SHIFT detach mouse

http://spamtheweb.com/ul/upload/030209/8 2123_main.php

Clipping needs a lot more work before you do anything else with graphics in my opinion. The engine looks great so far, but the collision with walls is completely unacceptable.

Move on to ActionScript 3.0 already!
The third post below this one is a lie.

BBS Signature

None

cowboyneok

Reply To Post Reply & Quote

Posted at: 2/6/09 05:10 PM

cowboyneok NEUTRAL LEVEL 02

Sign-Up: 02/06/09

Posts: 1

Definitely looking good, Ken! 3D rocks...

-Tim


None

Nuttro

Reply To Post Reply & Quote

Posted at: 2/7/09 07:36 PM

Nuttro LIGHT LEVEL 22

Sign-Up: 04/26/07

Posts: 848

Updates please


None

Super-Yombario

Reply To Post Reply & Quote

Posted at: 2/7/09 07:48 PM

Super-Yombario FAB LEVEL 06

Sign-Up: 03/16/07

Posts: 1,183

Don't ask for an update unless you can help with one please, it's rude

RIP Ed McMahon - RIP Farrah Fawcett - RIP Michael Jackson
But wait, there's more...
RIP Billy Mays


None

StaliN98

Reply To Post Reply & Quote

Posted at: 2/7/09 08:58 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

Sorry, been focusing on fixing texture mapping. There will be an update when that is done.


None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/7/09 05:30 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

/Ressurection

I started the engine completely from scratch today, using tile based raycasting instead. I now have textures working, and each tile can be different heights (it can do transparent walls too). Goals for tomorrow: floor texture mapping and the player ascending / descending (from jumping or walking up steps). Oh, and I have an idea to speed it up (theres some lag when you approach a high wall). Wolfenstein 3D textures for now.

WS Forward / Back
AD Turn Left / Right

http://spamtheweb.com/ul/upload/070309/8 0292_main.php


None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/8/09 08:39 AM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

Hmm, I'm, using solid pink (0xFF00FF) as my masking colour, so if a wall texture's pixels are 0xFF00FF, they won't be drawn and you can see behind them. But when I save the pictures, they lose the exact colour 0xFF00FF, even when on high quality. The transparency works when the masking colour is set to black, because that colour is not lost. Is there a way to 100% keep colour when saving the image? Better yet is there a way of seeing is a colour is approximately 0xFF00FF, with a small margin?


None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/8/09 12:11 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

New question:

var oneArray:Array = new Array("a", "b", "c");
var twoArray:Array = oneArray; // Both array variables refer to the same array.
twoArray[0] = "z";             
trace(oneArray);               // Output: z,b,c.

How do I bypass this so that oneArray isn't sharing values with twoArray?


Happy

evan210

Reply To Post Reply & Quote

Posted at: 3/8/09 01:15 PM

evan210 FAB LEVEL 25

Sign-Up: 05/14/07

Posts: 3,660

omg you're epic.
you almost have an FPS in Flash.


None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/8/09 01:18 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

A fellow pastafarian I see!
I'll have another update soon, just need to fix the problems above. And an FPS is exactly the game I want to make. Or a First Person RPG, like Arena.


None

ColdLogic

Reply To Post Reply & Quote

Posted at: 3/8/09 01:48 PM

ColdLogic EVIL LEVEL 19

Sign-Up: 11/12/03

Posts: 524

wow that lots alot better then the old one, the only thing i get is it starts to go really slow when im close to a wall. anyway thats awsome, this looks wayyy better.


None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/8/09 01:54 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

Thanks. I can make it much faster if I can find a faster way to clear an array than making it and all 160*120*2 of its directories. See my latter problem above (please, someone help!).


None

Yambanshee

Reply To Post Reply & Quote

Posted at: 3/8/09 02:28 PM

Yambanshee DARK LEVEL 11

Sign-Up: 10/05/08

Posts: 1,607

LOOKING AWESOME! You should get a counter strike like thing with that!

please sir, would you mind if i have sex with that?

AS2||AS3||Motox
Thanks to hdxmike for the sig :]

BBS Signature

None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/8/09 02:50 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

At 3/8/09 02:28 PM, Yambanshee wrote: please sir, would you mind if i have sex with that?

Please clean it up afterward. Oh, and thanks I guess.


Elated

flaminggranny

Reply To Post Reply & Quote

Posted at: 3/8/09 03:54 PM

flaminggranny FAB LEVEL 10

Sign-Up: 09/12/08

Posts: 288

I noticed the frame rate was already starting to tank once you added textures. Now would probably be a good time to go through you're code and see where you can do things more efficiently before it gets too big to do so.

Keep up the good work!

BBS Signature

None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/8/09 03:58 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

I've just implemented a more efficient method of drawing the display and z-buffering, now I'm going to use calculation tables to do all the predictable maths beforehand. It should be much faster next update.


None

IWasBanned

Reply To Post Reply & Quote

Posted at: 3/8/09 04:01 PM

IWasBanned LIGHT LEVEL 02

Sign-Up: 03/03/09

Posts: 241

The game is too dark, i can't see farther than 5 feet.
U probally did that for framerate issues...

<3Columbian Roastmasters <3
Each time someone uses hitTest, God kills a kitten. Please, learn real collision testing. - henke37


None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/8/09 04:22 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

I tested it with a drawDistance of 64 (a wall has dimentions 1*1), and it loses no speed compared to a drawDistance of 8 (what you have seen). Update coming soon.


None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/8/09 05:37 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

OK, here's an update before I go. Increased draw distance, (hopefully) increased speed, and masked textures. Expect floorcasting in the next update and clipping.
http://spamtheweb.com/ul/upload/080309/7 7778_main.php


None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/9/09 01:40 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

Hmm, some questions for optemisation:
is

var a:Number = b / c;

Any slower than

var a:Number = b;
a /= c;

is

var a:Number = b>1?1:b;

Any fater than

var a:Number = b;
if(a > 1){
a = 1;
}

is

var a:Number = b;

Any fater than

var a:Number = new Number(b);

or

var a:Number = new Number();
a = b;

None

Yambanshee

Reply To Post Reply & Quote

Posted at: 3/9/09 01:59 PM

Yambanshee DARK LEVEL 11

Sign-Up: 10/05/08

Posts: 1,607

my 2 cents

http://spamtheweb.com/ul/upload/070309/8 0292_main.php
this one ran on a avrage of 48 FPS for me (not sure what the max should be...
Actually prefered the texture

http://spamtheweb.com/ul/upload/080309/7 7778_main.php
this ran at about 30 fps

AS2||AS3||Motox
Thanks to hdxmike for the sig :]

BBS Signature

None

StaliN98

Reply To Post Reply & Quote

Posted at: 3/9/09 02:26 PM

StaliN98 LIGHT LEVEL 10

Sign-Up: 07/27/07

Posts: 690

That will be because I changed the max framerate to 32 on the second one.


All times are Eastern Standard Time (GMT -5) | Current Time: 04:31 PM

<< Back

This topic is 9 pages long. [ 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 ]

<< < > >>
You need a Grounds Gold Account to post on the NG BBS! If you don't have one, click here to sign up now! It's fast, free, and easy — and opens up tons of great NG features!