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.

DarkBASIC Discussion / Dark Noob Games HQ

Author
Message
Fluffy Rabbit
User Banned
Posted: 27th Nov 2012 04:31
@LBFN-

Now you understand. NOW you see, don't you? Now you see that Latch, though he contributed a lot already, needs to expand the capabilities of the ColDet library while retaining the original charm and all of that stuff.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 27th Nov 2012 05:12 Edited at: 27th Nov 2012 05:48
EDIT: I figured out how to make the collision work with the aliens. I used 'coldetSphereObjectCollision' to determine if there was a collision with the farm collision object and then used 'coldetSlidingCollision2' so I could get the sliding Y value. Then it was just a matter of adjusting the radius# and height# values.

So many games to code.....so little time.
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 27th Nov 2012 06:49
Thats good. You shouldn't have to cast a sphere first because that is done automatically by coldetslidingcollision2. You just have to make sure that the settings are correct. If the radius center is too low, there will be constant collision with the ground which would return an incorrect y sliding value.

Enjoy your day.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 27th Nov 2012 07:31 Edited at: 27th Nov 2012 18:32
I tried several times tweaking the radius# and height# variables using coldetSlidingCollision2 by itself, but never could get the settings to work right. With the ColdetSphereObjectCollision flagging a collision first, it works. If I use the exact same settings with coldetSlidingCollision2 alone, it is off. I expect it has something to do with this:


part of the function call to coldetSlidingCollision2, but didn't mess with the additions at all. I hope to look at that part tomorrow to see if I can get it down to one collision check. It is nice that I don't have to set up the aliens in coldet. I only actually need the sliding Y when the aliens are moving to waypoints. I will need the sliding X and Z when they are chasing after humans or the player.

EDIT:
Tried to get the alien collision working with coldetSlidingCollision2 alone, but it is not as exact as it is when I detect a collision with the farm collision object first. It is like the aliens move up in steps instead of being smooth and it tends to end up too high.

So many games to code.....so little time.
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 28th Nov 2012 00:11
Whatever works!

Just to note: The positioning of the sliding collision was based on the goblin 3rd person movement in load_ground.dba. The collision positioning and radius has to do with where the root pivot is for the goblin and the goblins height relative to the world. The aliens are completely different so all those things would have to be measured and so forth. To find the collision areas for the goblin, I created physical spheres where I inteded the collision to be so I could see where I was going to set up the collision limits.

But if you got a method, then run with it.

Enjoy your day.
Fluffy Rabbit
User Banned
Posted: 28th Nov 2012 02:37
I remember when the code was easy. Now the code is hard. How is this Dark N00Bs anymore?
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 28th Nov 2012 17:21
Quote: "How is this Dark N00Bs anymore?"

As I recall, only one person that I would consider a newbie even signed up for this project, and he has not been around for some time and has not contributed to it. So, practically from the get-go we have not really been working to help newbies learn coding in this project. If we would have had some on-board, I'm sure I would have worked to help them directly, like I did with Berzerk!

We are trying to work together and learn new things as we go, and enjoy the game-making process along the way. To me, it is rewarding to contribute and help out on a project and see it come to fruition. Since this is an open-source project, all can (hopefully) learn from it.

My $.02

LB

So many games to code.....so little time.
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 29th Nov 2012 03:42
Quote: "We are trying to work together and learn new things as we go, and enjoy the game-making process along the way."

Exactly!

Enjoy your day.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 2nd Dec 2012 00:29 Edited at: 2nd Dec 2012 02:06
Finishing up on the farm boy.



It has a few more polies than the farmer, but it has five fingers and the head and hair are more detailed. At 980 polies, I figure it will work for this game.

So many games to code.....so little time.

Attachments

Login to view attachments
Fluffy Rabbit
User Banned
Posted: 2nd Dec 2012 06:34
Great, except for him looking a little too buff.
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 3rd Dec 2012 10:01
Worked a little on the animator (we're most likely gonna need it). I dug into some of my old code that uses windows api controls. I've got actual windows menus working as well as listboxes and file dialogs working from within darkbasic classic. I was going to do limb collision for selecting limbs with the mouse but I think ill just leave that as a listbox selection.

I'll attach a screeny. I'll post the exe when it's usable. I won't go for any bells and whistles - it'll be basic for now so there's something to work with.

Enjoy your day.

Attachments

Login to view attachments
Fluffy Rabbit
User Banned
Posted: 3rd Dec 2012 12:42
@Latch-

I hope you post the full source code, too. In fact, you are quite obligated to by my own personal code of honor.

With that said, that screenshot looks very nice. A very professional looking tool indeed, although it looks a little hard to use. Too many lines and buttons and words. But, since I won't be the one using it, I'd say it looks like a very powerful tool.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 7th Dec 2012 04:09
Latch,

I stumbled on some DBC code that features an animated robot dancing to the Blue Danube. It says that it was done by you. I looked, but cannot find a thread for it on the forums. That was an outstanding piece of animation work. I assume that you rigged and animated the mesh in Blender and used the Python script to save it as an .x file for use in DBC.

It would almost be worth learning Blender to be able to do that, if indeed that is the case. Does your Python script work with Blender version 2.6.2?

So many games to code.....so little time.
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 7th Dec 2012 07:41
LBFN,

Here's the link to that thread:

DBC Animations

Quote: "Does your Python script work with Blender version 2.6.2?"

I never updated it beyond 2.45 . I think it works with 2.49 but after 2.5 the blender python API changed dramatically.

Enjoy your day.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 7th Dec 2012 12:13
Wow, that was 3.5 years ago

Okay, I plan to wait to see what you come up with as far as a new animator for DBC. The pic of it so far looks good. Bare bones, but effective works better for me as well.

So many games to code.....so little time.
BN2 Productions
20
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 8th Dec 2012 00:47
Finally got around to debugging the shooting system.

the error was in the data creation subprogram. I've attached the new file.

Note that line 1 now reads:


At the bottom, the directory is changed to that and the files are saved there. I chose this directory due to this being the current working directory of the program when the code reaches the load subroutine.

To be honest, though, I don't really understand the directory structure. It seems like everything is just thrown into farmhands, so that's what I went with. Keep in mind that you will still need to copy the 3ds object files that I made into the "farmhands\obj" directory.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose

Attachments

Login to view attachments
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 12th Dec 2012 03:40 Edited at: 12th Dec 2012 03:42
The farmer's wife:



934 polies; with 5 fingers.

So many games to code.....so little time.

Attachments

Login to view attachments
BN2 Productions
20
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 12th Dec 2012 06:11
Looks good. I'm no good with modelling/anything artistic.

Where are we at on the code? I have a few weeks with nothing but time on my hands.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Fluffy Rabbit
User Banned
Posted: 12th Dec 2012 11:01
@LBFN-

Less fingers, more face. Your models look rather dull (although that's not to say they don't look professional). The wife is the best yet. Now, how are they going to be animated?

@BN2-

That is a question best answered by someone who knows what he's talking about.
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 12th Dec 2012 19:59 Edited at: 12th Dec 2012 20:06
@all
Still here. Trying to squeeze out a little more time - but still in this 100% .

@LBFN
Another thing to try regarding animation:

If you can download the trial version of Fragmotion - or buy it if you like, you can animate your objects in Milkshape, export them to Fragmotion. I don't know if fragmotion accepts Milkshape, but it does import Direct X, both skeletal and hierarchical with or without animation.

Export the model out of fragmotion as OBJ.

Export the animation out of fragmotion as BVH.

I can load the model and the animation into Blender, modify the model for DBC, import the BVH animation, and animate the models properly for DBC with your animations.

When you export the BVH animation, choose Biovision and not Poser.

You could even import the T-pose alien and animate it in Fragmotion. Then export the animation as BVH and I can animate it in Blender and export it.

Fragmotion exports Direct X, but not hierarchical - only Bone animation with Matrix Keys (matrix keys can cause problems anyways.)

Enjoy your day.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 12th Dec 2012 23:55
Okay, downloaded the seven-day trial of FragMotion. It says that it does indeed accept Milkshape (.ms3d) files. So, I'll plan to rig the alien, do the animations (did we ever decide on what all we wanted?) and export the OBJ and BVH files. Then I will post a .rar file here for you to DBCatize it.

Quote: "Where are we at on the code? I have a few weeks with nothing but time on my hands."


BN2, I have not worked with your shooting code at all. I was waiting for Latch to have an opportunity to bring in the tractor and trailer/gun to the game to really do much more with it.

General gameplan: I have not yet brought any of the three humans into the game. I figure to try the animation stuff with the alien first; if it works okay, I plan to work on animating the humans next. Then some code would be needed to place them within the buildings and give them some basic movement. Some waypoint stuff for them would be great. It also might be cool to have additional textures for them. Once they are in the buildings, I plan to have them scramble to the different corners and maybe out the door to avoid the aliens. The aliens will need to have updated AI code for this too.

All this said, whatever you want to work on is fine, BN2, just let me know what you want to do so we don't work on the same thing. If nothing else, you could use placeholders.

So many games to code.....so little time.
BN2 Productions
20
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 13th Dec 2012 01:06
I could take a stab at getting the civilian system up and running. Will they have health (the aliens chase and attack them and they die eventually) or are they more of scenery and the aliens are attacking the buildings?

If they have help, it seems that the aliens and civilians could all be controlled with one entity management system that would store things like:

position
direction
waypoint information
ai subsystem references (so if the ai data is 1, then use this subroutine, if 2, use another).
team data (civilians, fighters, aliens)
weapon data (if armed)
etc

Just depends on what you guys are intending the humans to really do.

I assume that either way, they will stay in the building until aliens enter, then scatter (maybe I'll see if I can get some cool ai to have some run around the alien to escape while others run straight back).

Also: did we ever get a satisfactory movement system implemented? I feel like that would be an important thing to do first.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 13th Dec 2012 04:27
Quote: "I could take a stab at getting the civilian system up and running. Will they have health (the aliens chase and attack them and they die eventually) or are they more of scenery and the aliens are attacking the buildings?"

okay, good. I definitely think they need to attack the people and not the buildings. I was thinking that the aliens could actually drag the people away and beam them up to their ship. The only problem with that is we would need a lot of people to protect, or we would have to regenerate new people to run and hide in one of the buildings. That is certainly do-able. I don't think I would use health for them in this case.

Quote: "
If they have help, it seems that the aliens and civilians could all be controlled with one entity management system that would store things like:

position
direction
waypoint information
ai subsystem references (so if the ai data is 1, then use this subroutine, if 2, use another).
team data (civilians, fighters, aliens)
weapon data (if armed)
etc"


I have something like this setup for the aliens currently. The direction they move is waypoint based. However, certain waypoints (i.e. inside the barn, house, etc.) have code that could easily be used to have the alien searching for a human and moving to catch them. The code to do this is not in, but the framework is in place. They do not have weapons and do not fight as teams, though.

Quote: "Also: did we ever get a satisfactory movement system implemented? I feel like that would be an important thing to do first.
"


With regard to the player / tractor / trailer / gun? Latch is working on that. I haven't seen it yet.

So many games to code.....so little time.
BN2 Productions
20
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 13th Dec 2012 04:37
Quote: "fight as teams,"


Team was meant to indicate control of what "side" they are on. For instance, no alien will be chasing another alien. Conversely, no civilian will be trying to chase down civilians. Ultimately something like this would be necessary if we choose to have one primary entity management system that controls alien and civilian movement and ai.

Before I start, just wanted to get the flow clear:

Aliens land. Civilians are inside buildings.

Aliens move via waypoints (presumably) to various buildings.

Alien enters building. Civilians scatter.

Alien chases and grabs civilian. Returns to closest waypoint. If alien is killed while he holds the civilian, the civilian will attempt to return to their building.

Alien follows waypoints back to extraction site.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 13th Dec 2012 04:51
yes, that is how I see it. The buildings are not very big, and there are lots of aliens in a relatively short period of time. Granted, many of the aliens will get blasted by the player, but I am a little concerned that it will be overwhelming too quickly. This could be adjusted by making a longer delay of the alien ships in-between alien drop-offs and also by changing the number of aliens that get dropped.

We may want to have the human(s) go to a corner, crouch down and quiver or something. I suppose we could find a pitchfork for them to stick in one of the aliens too Seeing the wife go ninja on the aliens would be funny too.

So many games to code.....so little time.
BN2 Productions
20
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 13th Dec 2012 04:54
Quote: "
We may want to have the human(s) go to a corner, crouch down and quiver or something. I suppose we could find a pitchfork for them to stick in one of the aliens too Seeing the wife go ninja on the aliens would be funny too."


Haha I like that idea. Many would just cower in a corner, but I imagine those near a corner by the entrance by default should run out (cowering in a corner right next to an open door seems a bit counter intuitive).

Perhaps if the number of humans to aliens ratio in a building is high enough, they could all team up on the alien and kill him (such as a barn full of humans and one alien kicks the door in).

I'll see what I can do.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 14th Dec 2012 01:17 Edited at: 15th Dec 2012 04:13
Proposed animations for the alien (and NPCs in general):
idle, walk, attack1 (lunge), attack2 (hand swipes), recoil, die1 (backward), die2 (forward), pick up human, carry human while walking, scream / taunt, special move (maybe a T spin or a frontward barrel roll)

The alien Tpose is rigged and ready for animation. I will get started on the animating. Please respond as quickly as possible if you think we should have different animations.

EDIT:
I found the alien in the pic on an old stick drive of mine. I did not make it and it came from TurboSquid (link below). The version I have is an older version of it, and I like it better than the new version.




SquirboTuid link:
http://www.turbosquid.com/3d-models/free-3ds-mode-alien/400453

So many games to code.....so little time.

Attachments

Login to view attachments
Fluffy Rabbit
User Banned
Posted: 15th Dec 2012 09:50
That's a nice Alienâ„¢.
BN2 Productions
20
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 16th Dec 2012 01:55
Sorry for the slight messiness. Here is a basic draft of the chase and evade ai. Blue squares are Civilians, red are Aliens. You can spawn and place as many as you want to test.

For now, once an alien hits the civilian, the civilian is dead and stops moving.

Is this the kind of behavior that we want to see (obviously, aliens will eventually carry humans away) or do they seem like they aren't moving in a realistic fashion?

Let me know what you think as the next steps build off of this.



Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 16th Dec 2012 03:06
It seemed to track the 'humans' reasonably well. The alien moved a little fast as compared to the humans. It appears to be heavy on calculations; I am concerned about gamespeed with all that we are putting in this game. Could you run it using 3D models (maybe you could use the alien character chasing some spheres) to see how it looks at 35 FPS?

So many games to code.....so little time.
BN2 Productions
20
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 16th Dec 2012 05:05
The aliens are set (tentatively) to double the max speed of the humans and double the acceleration (so they can get up to top speed faster).

Here is an attached EXE that runs the simulation with 4 aliens and 4 humans in a 3d world. I used SYNC RATE 35 to cap the FPS (displayed in corner). When running at 0, I got over 60 FPS.

The simulation ends when all humans have been "caught".

One thing I'm not liking is the ability for the humans to escape relatively easily. Their slowness ensures that they will almost always be caught eventually, but I might go with a smarter system to manage the aliens (each chooses a unique target and pursue it while other aliens are then disallowed from selecting the same target).

The next implementation for the system is putting everyone in a room and see how they react.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose

Attachments

Login to view attachments
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 16th Dec 2012 06:09 Edited at: 17th Dec 2012 05:24
Quote: "One thing I'm not liking is the ability for the humans to escape relatively easily. Their slowness ensures that they will almost always be caught eventually, but I might go with a smarter system to manage the aliens (each chooses a unique target and pursue it while other aliens are then disallowed from selecting the same target)."

The rooms are pretty small and I figure the humans are almost never going to get away because of their close proximity. So allowing them the possibility of getting away is a good thing, IMO. The aliens come quickly and I really don't think we want the humans getting grabbed up super fast, as the player will never be able to keep up and will give up from frustration. The farm is large enough that the player is going to have his hands full picking off all of the aliens and keeping them from taking the humans to their ship. So, having an alien AI that allows the humans a chance to get away is a good thing as I see it.

We might want to think of ways to introduce more humans as the game goes on. Perhaps we could have rounds, where you have so many humans to rescue and a bonus is given for each one you save. If they all die, you lose the game.

EDIT:
Alien is fully animated and exported from FragMotion. The OBJ and BVH files are attached. I imported them into Blender v 2.62 and it was not pretty. Hope it works better for you, Latch.
Anim frames:
idle: 1- 38
walk: 38-66
attack1: 67-85
attack2: 85-114
recoil: 114-129
die1: 129-147
die2: 148-174
pick up human: 175-189
carry human while walking: 189-209
taunt: 210-239


So many games to code.....so little time.

Attachments

Login to view attachments
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 21st Dec 2012 01:52 Edited at: 21st Dec 2012 01:56
@LBFN
I'll take a look at them when I get home tonight.

"Taunt" that's funny! I can't wait to see what that is.

I changed some of the code in the original BVH script in Blender and it seems to work most of the time. I've also wrote a DBC program that loads and runs BVH animations so I'll be able to see if the animations will work.

There are a couple of export BVH export options if I remeber correctly with Fragmotion. One of them doesn't work well with Blender. The Biovision one does, I think.

Enjoy your day.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 21st Dec 2012 04:39
I used the Biovision export for the BVH file - hopefully it will work.

The taunt anim isn't much really - the alien stretches his arms up and outward in a threatening position and then becons the player with one hand to come on. It was a bit of a joke, but I guess it could be used when the player is nearby.

If you can get this working, I can work on animating the farmer, wife and boy. I would be interested in the DBC code/dll that loads BVH files if it is available for others to use.

How are you doing with getting the tractor, trailer and gun in the game? I would love to start blowing away a few aliens. What do you think about the other alien that I posted up?

So many games to code.....so little time.
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 21st Dec 2012 17:57
Quote: "How are you doing with getting the tractor, trailer and gun in the game? I would love to start blowing away a few aliens. What do you think about the other alien that I posted up?"


I hate making excuses but the code I have generally works but it isn't integrated with the code you posted (including aliens, and spacships and such). I am actually done with holiday stuff until Monday and I won't be working until Wednesday so I should actually have spare time to work on the code. If I don't integrate it, I'll post the code anyway. It's set up as functions and subroutines so it should be able to be added easily - just called at the correct times.

I like the other alien but doesn't it look like the Alien from the movies? Would that be copyright trouble waiting to happen?

Quote: "I would be interested in the DBC code/dll that loads BVH files if it is available for others to use."


My goal with this code was to make a sellable application. As that is still an intention, I don't want to release anything just yet. However, that may change if I ever realize it'll probably never get finished. Part of the goal is loading in direct x skeletal animations and converting them to limb based and vice verse as well as creating a DBC skeletal animation method. I have most of the pieces working as separate tests, one of which is loading and viewing BVH animations as DBC limbed animations.

Enjoy your day.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 22nd Dec 2012 03:23 Edited at: 22nd Dec 2012 03:28
Quote: "If I don't integrate it, I'll post the code anyway. "

It probably would be better to post it and I can do the integration. I have made some updates to the code since I last posted it, so I'm going to have to do some work anyway.

So, how does the player fit into all this? The player shoots the gun that is mounted on the trailer; The gun is aimed via mouse / keyboard input, and the player is positioned appropriately behind it. The player can exit the trailer and whip some alien tail in hand-to-hand combat whenever he wants? How does that work? Was it decided who/what the player character even is (I cannot recall)? What about the tractor driver? Sorry if this was covered previously. I'm trying to figure out what would be the next course of action after the tractor and trailer are added and working properly.
Quote: "
My goal with this code was to make a sellable application"
.
okay. TGC should buy it and update DBC with it and the Coldet dll.

The alien looks somewhat like the one from the movie, but it is too far away from the original to be a copyright infringement in my view. Obviously, I don't want anything to do with copyright issues, but I didn't see it as a problem myself. Still, if you are uncomfortable, we should not use it.

So many games to code.....so little time.
Fluffy Rabbit
User Banned
Posted: 22nd Dec 2012 07:57
Quote: "I like the other alien but doesn't it look like the Alien from the movies? Would that be copyright trouble waiting to happen?"


Not so much copyright issues, but in general I think that people would find it kind of dumb that for your aliens you have Aliensâ„¢.

Quote: "My goal with this code was to make a sellable application"


Selling your code for money? Honestly, that's a surprise. You're a great programmer, but still, it must be the end of the world!

Quote: "okay. TGC should buy it and update DBC with it and the Coldet dll."


Well, since the ColDet DLL is free, I can't imagine it happening quite like that.

Anyhow, I'm very sorry that I have not been contributing much to the project recently. To be honest, I don't think you miss me. I kept trying to combine all of the code into one thing, but now it has diverged/branched so much that I don't think that is possible except for a master coder like Latch who will spend days doing so.
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 23rd Dec 2012 20:41 Edited at: 23rd Dec 2012 20:51
Quote: "but now it has diverged/branched so much..."

The slow downs I think are a good part my fault. I really didn't expect the time demands from the real world when I started this. As far as the branching, the code will probably branch again and again. It's evolving, and that's kinda the way it goes. It's still short code - it's not 10,000s of lines, so it's still easily managed.

Quote: "...with it and the Coldet dll"

Thanks for the flattery. I didn't write the base code for ColDet so that would be up to the author. There's another LGPL collision library out there called OZcollide. It sounds more complete than ColDet - that'd be another project.

@LBFN
I'd rather not use a knock-off of a famous creature like that where the "purists" can't wait to criticize or cry foul.

As far as a tractor driver, I was going to use a DarkMatter Model and just do some bouncing, looking around, general movement animation.

The main farmer is going to be the main player right? So, perhaps it's third person when he runs around, and then maybe first person when behinid the turret? Third person on the turret might be tough. Let me get those models and code available and everyone can take a look to see what might work. We can experiment also. This is all in fun, so we can do whatever we want, but I also know there is the desire to finish it quickly.

Enjoy your day.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 23rd Dec 2012 23:03 Edited at: 23rd Dec 2012 23:04
Quote: "I'd rather not use a knock-off of a famous creature like that where the "purists" can't wait to criticize or cry foul."

okay, the Alien is out; not a big deal. I sense that we will just stick with the one alien as the only baddie for the game.

Quote: "The main farmer is going to be the main player right?"

okay, that should work. I just didn't remember it being stated as such.

Quote: "So, perhaps it's third person when he runs around, and then maybe first person when behinid the turret?"


It would be trickier to have him behind the turret. Previously, I coded a working turret in DBPro that allows for aiming of a turret using the mouse and it works pretty well, and I think it could be made to work here. It would definitely be easier if the player is not there, though. So, a first-person mode without the player and a third-person mode when he exits the trailer would be a good way to go.

One question that needs answering is, what does he do when he is running around? He has no gun at that point. I guess he could waylay the aliens with some karate kicks and punches and stuff. Maybe run to get more ammo? Fix a tire on the tractor? Run and hide? Set or throw bombs? Use a pitchfork?

Quote: "We can experiment also. This is all in fun, so we can do whatever we want, but I also know there is the desire to finish it quickly."

I agree that we can figure out what will work best. It would be nice to get some progress on this. I thought we would be all done by now, but that's okay, as I completely understand that this is not the first priority in our lives.

So many games to code.....so little time.
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 28th Dec 2012 08:09 Edited at: 28th Dec 2012 08:17
@LBFN
I got a chance to mess around with your animated alien a bit. The BVH file seems to work, though I'm not 100% sure what you wanted the animation to look like. One thing I noticed is that in the BVH file, the first frame was not the initial T-pose so I added it.

Here's the limbatized version with your animations. I think maybe a couple of the rotations in the arms are a bit off. It could be a some angle differences when the animation was converted to BVH.

A tip that may help: don't leave too much to the interpolation between keyframes. I mean, don't space all of your keyframes too far apart. Take more control of the animation directly with immediate sequential keys. This helps control strange rotations when the frames are left to interpolation between distant rotation gaps.

Enjoy your day.

Attachments

Login to view attachments
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 28th Dec 2012 12:28 Edited at: 29th Dec 2012 01:17
Hi Latch,

With a SYNC rate of 35, I set the interpolations to 1 and the object speed to 10 and the animations are fairly close. However, some of the arm movements are off a bit, though the legs seem to animate pretty well. I noticed when the alien dies, it does not fall down to the floor and bounce, as in the original animations.

EDIT: I have modified the animation file and have stored every keyframe. Hopefully, this will work better. The .bvh and .obj files are included in the attached .rar folder.

So many games to code.....so little time.

Attachments

Login to view attachments
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 6th Jan 2013 01:05
@LBFN:
I'll give it a go. The strange movements could be from all of the translations: MDS > BVH > BLENDER > X . Something may be getting lost somewhere down the line.

@all
I was working on the vehicle tilt today. I was thinking about using sparkys since I already have the code in place to do it - but it might make some of the collision object definitions redundant with ColDet. I'll try it anyways. If it hits performance it will just be a matter of switching one for the other. The ray collision is similar enough it so switching shouldn't be an issue. And yes, believe it or not, I'm actually sneaking in some coding time today!

uh oh, "the boss" just came in and said we have to go to the grocery store to get some vegetables...

Enjoy your day.
Zero G Scott
16
Years of Service
User Offline
Joined: 14th Dec 2007
Location: California, USA, Earth, Sol Sys
Posted: 12th Jan 2013 21:21
Very interesting to see how this has progressed since the last time I was around it was a gleam in someone's mother's eye. Very nice work!

@ Latch
Your e-mail still active or am I in the dog house again?
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 17th Jan 2013 03:26
@Zero G
Haven't checked that email for along time. I'll take a look. good to hear from you.

@all
I should have some code up in the next couple of hours. I'm attaching a screeny of a guy driving around the tractor and hauling a trailer just to show there is something in my pot and it's working. The cubes in the shot are the waypoints the tractor's following. I still have to mount the gun on the flatbed. I've corrected a few texturing problems so it's just about ready. I can't believe how much work this takes! What ever happened to free time?

screeny attached

Enjoy your day.

Attachments

Login to view attachments
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 17th Jan 2013 10:06
Alright,

This attachment includes code for choosing waypoints for the tractor and having it move towards and through them. There are five paths:

Around the house
Around the barn
around the shed
around the stable
to the center

The commands are listed at the top of the source code. Function keys F1-F6

I wasn't able to incorporate this code into the newest code LBFN published. If I had tried to integrate it, I probably would have never gotten finished with what I have.

There are 4 new models incorporated:
Tractor
Trailer
Mounted Gun
Driver

The driver isn't animated as of yet; that'll have to wait.

The code is laid out mostly in functions and subroutines. I've commented what I thought was necessary to understand, but i don't know if it makes things any easier. Theres a lot of code. I included the running goblin code just to get and idea of scale and also so you could move the camera around in an interesting way (arrow keys and mouse)

The code could use work, but it does what it's supposed to for the most part. There's no collision on the tractor or trailer. I apologize for how much time it's taken to get this out, but I'm really short on time these days.

Enjoy your day.

Attachments

Login to view attachments
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 18th Jan 2013 00:20 Edited at: 18th Jan 2013 00:21
Okay, got the new code / models installed with the existing code. It was surprisingly easy to do. Running it without the tractor moving at all and got 30-33 FPS.



So many games to code.....so little time.

Attachments

Login to view attachments
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 21st Jan 2013 19:06
Quote: "Running it without the tractor moving at all and got 30-33 FPS.
"

Assuming it was running at a steady 35 previously? Likely, it's due to the graphics. Disable the skysphere to start with - hide it or don't load it at all - then see if there is a performance difference. Next, eliminate/disable all of the lighting/fog commands. See if this makes a change. If so, the slow down is due to graphics and we can control that to within a tolerence we feel is acceptable. We add the more important things, like shooting and moving, test the performance, then cut back on some graphics where we can. The textures for the tractor and the gun are at 1024x1024 each so we can try saving a version of those at 512x512 - see if the detail is tolerable and see if that has an effect.

I think there might have to be a bit of an overhaul in the code as well, as it seems the individual blocks of code are running together though they may not be running together efficiently.

Enjoy your day.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 22nd Jan 2013 02:59 Edited at: 22nd Jan 2013 04:28
It was running around 33-35 before. I tried running without the skyspheres and it didn't matter speed-wise. I ran without the fog on (which I don't see as needful anyway), again with no difference. I then ran it at a sync rate of 0 - it maintained a steady 60 FPS! I set the sync rate for 60 FPS and it ran at 50 FPS solid. If I put it at 45 or below, it runs at 33. Go figure.

Agreed that resizing the textures would help with the FPS, but downsizing will likely make revamping the UV map necessary (uggh!) DBC can load .dds textures. I could convert them to .dds, give them to you and have you retexture the farm with them to see if there is a speed increase. I could do the farm family. .dds files would also save on the load time and total size of the program. My preference would be to try this method first before revamping the UV maps with smaller sizes.

I'm sure the code could use some efficiency improvements.

So many games to code.....so little time.
Latch
18
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 22nd Jan 2013 20:44
Quote: "Agreed that resizing the textures would help with the FPS, but downsizing will likely make revamping the UV map necessary (uggh!) DBC can load .dds textures. "

No. Not doing any texture remapping. No need for a dds conversion. The only real use for that is storing mipmaps within the file. All textures are converted to direct draw surfaces when loaded anyway, so there is no advantage except on intialization. If the texture file is reduced to half and saved as the same file type (png in this case) with the same file name the mapping won't change.

However, maybe we'll start with a code revamp and maybe limiting the number of aliens to 8 to 12 at a time. If you're getting 60 fps at 0 SYNC rate, then we're ok. If you load a midi file or mp3 as music and play it, the cap on your FPS will also be released so it will likely show above 60. If the FPS only fell 2 or 3 points when you added the tractor and stuff, then we are still pretty good. If we maintain a tolerence above or equal to 25 FPS, we'll have a playable game; but lets strive for 35 fps.

I'll try combining my code with the old code you posted and see what the FPS are I get later on during the week. If there is any performance bottle necks, maybe coldet is a culprit as well. It really hasn't been tested with DBC in a full on game. I've only done testing based on specific examples to show functionality. It seemed to perform quite well, but who knows what'll happen with many moving/animated entities.

Enjoy your day.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 24th Jan 2013 00:52
I tried reducing the texture size on the boy from 1024 X 1024 to 512 X 512, textured the model with it and it was fine, so I learned something there.

As I recall, the last code I posted was in November of last year. I have updated it somewhat since then, though efficiency was not my highest priority. I think I was only moving so many aliens per iteration in that code. Besides moving all of the aliens every loop, I think the biggest addition was using coldet to place the aliens at the ground level. If you want me to post the current code, let me know and I will put it up.

I looped OBese87's 'Harvest' song in the game and ran it at 0 SYNC RATE and got 59/60 FPS. I am thinking that we might be able to run as is, but if not, limiting the aliens on-screen at any given time would surely help bring it up. I think we should be real close to 35, at minimum.

So many games to code.....so little time.

Login to post a reply

Server time is: 2024-11-24 11:20:40
Your offset time is: 2024-11-24 11:20:40