Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Work in Progress / Abnorm

Author
Message
C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 16:58 Edited at: 11th Nov 2007 17:00


A Soharix game
Made using Dark BASIC Professional 6.6, Deled LITE, MS Paint & Gimp
Game programming; Myself
Most of the textures and in-game images; Myself and Joeeigel
Music; Liam Bradbury
Modeling; Sam Hensel-Hunter

This is a WIP for a hopefully upcoming game from Soharix. This game is a major achievement in Soharix's gaming history being that it doesn't include the character John and doesn't suck beyond belief.

We have a major problem in the game which will be discussed at the end of this post.

But first a little about the game.
The game engine (code base) has been evolving over a number of predecesive projects that were all, at the time, "Soharix's best project" and they kept getting better. 4 of the 11 projects were FPSs and that is what Abnorm is. Prior to Abnorm we worked on a game called War Heart which was going well until I realised you could shoot through walls. I then started another project instead of working out how to stop this shooting through walls.

I soon got bored of the next 1, which was code-named Sk14 (simply because I couldn't think of a name) and because I had later figured out how to stop the character in War Heart shooting through walls, I decided to try making another FPS.

This FPS was called Sk15 to start off with but then was changed to Abnorm. The main theme of the game was similar to Quake (the first levels of each world (facility levels)), in that there are slipgates and facilities.

The FPS creation was going fine and everything was being made to plan being that over the years I'd done all the coding before so it was easy to get things to work. The maps consisted of object placement for generic boxes, health, ammo, enemies, keys and doors.

Here are some screenshots of the first level (reasons for having not made the second level yet will be at the end):


Pic 1^^^



Pic 2^^^



Pic 3^^^



Pic 4^^^

Problem
The primary problem with this game is as follows:
You may have noticed in those screenshots it says my FPS is around 20. Well it should be around 50-60 with that game, it is just that there are so many enemies on the level, well in actual fact there arent that many, 15 at max each with their own identity each working independantly all with animations and all with a lot of polygons. I asked Soharix's modeler to reduce the polys and he got them from about 750 odd to around 600. I wasn't too happy but it was better than it was before. I ran the game with cubes replacing the enemies and everything ran smoothly so I know it is either the animations or the polygons. (More likely the latar.)

I don't really know what to do though, because there are no human models with animations like that around on the forums and Soharix's modeler can't make us another one because he is inexperienced (and also can't reduce the polygons further because the animations distort.)

Can anyone help?


Roxas
18
Years of Service
User Offline
Joined: 11th Nov 2005
Location: http://forum.thegamecreators.com
Posted: 11th Nov 2007 17:00
If you are using dbpro own animation commands then they are likely reducing your fps like hell!

[center]

Click for details!
C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 17:01 Edited at: 11th Nov 2007 17:03
What do you mean?

I also turned the animtions for the objects off and the game runs just as slow.

Jeff032
17
Years of Service
User Offline
Joined: 13th Aug 2007
Location:
Posted: 11th Nov 2007 17:16 Edited at: 11th Nov 2007 17:17
I do not think that your game is going slow because you have 15x 600 poly models. That's only 9000 polys. I'm using 5000 poly spaceships without any slowness (might reduce that eventually though...)

C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 17:19 Edited at: 11th Nov 2007 17:20
My computer isn't old.

A picture of my rig is attatched because I can't copy the information:

It isn't just the enemys that have polygons, there is the map, and all the other objects in-game too.

Is there anyway to find out how many polygons is in a whole DBP scene?

EDIT:
An example of how good my PC is, it can run Doom3 and Quake4 in max graphics.

Attachments

Login to view attachments
Roxas
18
Years of Service
User Offline
Joined: 11th Nov 2005
Location: http://forum.thegamecreators.com
Posted: 11th Nov 2007 17:20
@Cowbox
Hmm thats weird then.. It isnt dbpro animation commands then..
The objects are bad modelled then or something i dunno.

How smooth it does work when you replace humans with boxes?

[center]

Click for details!
C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 17:21 Edited at: 11th Nov 2007 17:26
When I replace the objects with simple cubes (6 polys each obviously) I get an FPS of 60 (the normal for all my DBP projects).

But I will check one more time.

EDIT:
After checking I have some wierd results - can anyone make sense of them:

With the human objects and animation on or off (no difference in FPS) they are both around 20FPS.

With the humans replaced as cubes I get an FPS of around 30, this is still with all the animation commands in the game loop on, so it is still trying to loop an object that has no animation. (Another odd result on that one is that none of the cubes show up, they misteriously float off the map and you can see stars on the skysphere twinkling as the cubes pass infront of them.

With the gravity and movement of the objects turned off, as well as the animations I get a mixed result. Certain times or directions I look I get an FPS of around 45, others I get around 30.

I don't know is going on.

Roxas
18
Years of Service
User Offline
Joined: 11th Nov 2005
Location: http://forum.thegamecreators.com
Posted: 11th Nov 2007 17:24
Hmm its then in models.. Or math calculations cuz i get always too 60 fps because my comp is old!

But i think its in model.. Try using psionics Dwarf model and see if it works

Also you can check polygons in dbpro.. I just dont remember the command it was something like Statstics$(1) not sure tough..

[center]

Click for details!
C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 17:31 Edited at: 11th Nov 2007 17:41
Upon further inspection using the "Statistic" command, I found that the entire DBP scene has around 21216 polygons. I don't know how to reduce that but I shall have a look at some CSG for the map. I think it is the main problem infact.

EDIT:
Well again, that doesn't make sense - in the map editor, it says the scene is only 4000 odd polygons, so the bulk is made up of in-game objects.

Roxas
18
Years of Service
User Offline
Joined: 11th Nov 2005
Location: http://forum.thegamecreators.com
Posted: 11th Nov 2007 17:41 Edited at: 11th Nov 2007 17:42
Actually that isnt even recommended amount of polygons.. Your game should run smoothly..

Proplem isnt in polygon amount!

I think its in textures then..

[center]

Click for details!
C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 17:42
Then what is it?

I think it is, I think I have to many polygons in some of the normal objects, not just the enemies.

Roxas
18
Years of Service
User Offline
Joined: 11th Nov 2005
Location: http://forum.thegamecreators.com
Posted: 11th Nov 2007 17:54
No it cant be..
You should have good amount of polygons already..

Did you check your textures?

[center]

Click for details!
PresFox
19
Years of Service
User Offline
Joined: 28th Aug 2005
Location:
Posted: 11th Nov 2007 17:56
22000 polygons is nothing

terrains of upto 300000 poly's have been reported to run smoothly

Microsoft isnt evil, they just make really crappy operating systems -- Linus torvalds
Guyra
18
Years of Service
User Offline
Joined: 10th Nov 2005
Location: Norway
Posted: 11th Nov 2007 18:01
You should also make sure that the camera range isn't longer than it needs to.

SET CAMERA RANGE Near Value, Far Value
SET CAMERA RANGE Camera Number, Near Value, Far Value

Also, you could turn off AI if the enemy is too far away. (If you've got a ball looking for waypoints inside a room while firing laser beams at immortal enemies running around in the same room, then you don't usually need/want to run the AI when you're five miles away.)

If you won't have any real time reflection, then you should also only draw what you see, and hide all objects not in camera view.



Hope it helps, keep up the good work.
C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 18:05 Edited at: 11th Nov 2007 18:11
Well, I'll go try that camera range stuff, and at the moment the AI isn't very complex, they are just randomly walking around.

EDIT:
Well I tried reducing the camera range from 1,75000 to 1,1000, and I'm still only getting an FPS of around 30, and I should be getting at least 50. What else can I do?

Jeff032
17
Years of Service
User Offline
Joined: 13th Aug 2007
Location:
Posted: 11th Nov 2007 18:06
Quote: "and hide all objects not in camera view."


excluding the objects will give a higher speed boost.

C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 18:21
Well I made it so that objects that aren't in the screen are hidden, but that still doesn't make much difference to the FPS, it is still between 20 and 30.

What else can I do?

Roxas
18
Years of Service
User Offline
Joined: 11th Nov 2005
Location: http://forum.thegamecreators.com
Posted: 11th Nov 2007 18:22 Edited at: 11th Nov 2007 18:23
Your camera range was 75000!?!?!?!?

CRAZY!

Anyways did you check the object textures already? If textures are too big or wrong format or something else they slow hella lot!

Also for hiding objects.. did you use hide object? Or Exclude object on?

[center]

Click for details!
C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 18:35 Edited at: 11th Nov 2007 18:39
I used Hide object, and the 75000 range was an accident from another project. (I copy the source code everytime I start a new project.)

But just now I found out that for some reason, moving every enemy object down by 1 world-unit, reduces me FPS drasticly. Because now I get an FPS range of 27 to 51. (Which I also don't understand.)

EDIT:
Doing exclude object on didn't make any difference either, it is still around 30-50FPS.

Roxas
18
Years of Service
User Offline
Joined: 11th Nov 2005
Location: http://forum.thegamecreators.com
Posted: 11th Nov 2007 18:46
Exclude object is better than hide object..

I still think your proplem is on textures.. So simply your textures arent good.. not sure tough.. Cant help :/

[center]

Click for details!
C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 18:50
Well because there are 2 objects for every enemy (1 for the animation and a plain for the movement) I made sure I hid and excluded both when not looking at them.

Having done this, I ran through my level, killing everything and getting all health, ammo and destroying all the boxes until there was nothing left, everything was either destroyed or offscreen and my FPS went from around 20 at the start of the level to 50 at the end. :S

So what exactly do you think I should do to my textures?

Roxas
18
Years of Service
User Offline
Joined: 11th Nov 2005
Location: http://forum.thegamecreators.com
Posted: 11th Nov 2007 18:53
Check that they are jpg and they arent too big (In file size and in pixels !!) Also check that they are power of 2

[center]

Click for details!
C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 18:57 Edited at: 11th Nov 2007 19:03
Well I made my textures from 1024x1024 BMPs to 1x1 BMPs and there was no change what so ever.

I stopped my objects having gravity and now the FPS range is 26 to 53 which is really awekward for trying to shoot because you can't aim at something if your mouse speed is changing.

Aha, I found it.

It isn't the polygons, it isn't the animation, it isn't the collision, it isn't the textures - it's the AI. God I must be such a bad programmer if I can't even program AI.

I shall work on it and see if I can get it to stay at an FPS of 60 when running with AI.

Cash Curtis II
19
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Corpus Christi Texas
Posted: 11th Nov 2007 19:37 Edited at: 11th Nov 2007 19:38
A couple things to consider - what is the file size of the characters? That can drastically impact your framerate if they're too big. How many frames of animation do they each have?

I'm not sure how your culling system works right now, but DBP doesn't cull offscreen animated models. So, you need to exclude any character that's offscreen and exclude off them when they come back on. If you aren't already then be sure you've stopped animating them when they're offscreen as well.


Come see the WIP!
C0wbox
18
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 11th Nov 2007 20:04 Edited at: 21st Nov 2007 16:43
It all works fine, I said, after much fiddling I found it to be the AI and the constant downward movement of the simple-gravity that was lowering the FPS.

----------<End of WIP, do not bump>----------

Login to post a reply

Server time is: 2024-09-29 22:26:38
Your offset time is: 2024-09-29 22:26:38