Jump to content

  • Log In with Google      Sign In   
  • Create Account

Caveman



The Building of Caveman - part 2. What to build, and tool selection

Posted by , 29 March 2014 - - - - - - · 1,128 views

The Building of Caveman - part 2.

What to build, and how?

What to build? thats the first of a million questions to be answered when
building a game.

Well, the answer turns out to be pretty simple:

you build what you want to play, that somebody else hasn't already built
for you.

odds are, if you think its cool enough to play that you'd go through the
effort of building it just to play it, then maybe other people might
like to play it as well.

in my case, it was pretty easy. i'd already made over a dozen games over
the years. some hits, some ok, some that didn't sell much at all.

so you go with what works.

the line of thought was: "well, my biggest hit was probably Caveman,
so i probbaly ought to do that first."

So that settled what to build: you lead with your strong suit, your
flagship product.

Now, how to build it:





Platform:
PC. bigger installed base than mac and linux. insufficient
manpower (i'm an army of one) to support multiple platforms,
so PC is it. moble etc isnt even an option ue to the size of the
game - at least at first - pc alone is plenty of a challenge.





Language(s) and libraries:

WHATEVER:
1. HAS THE CAPABILITIES REQUIRED
2. RUNS FAST ENOUGH
and
3. WILL REQUIRE THE LEAST LEARNING AND DEVELOPMENT TIME

in my case, that was procedural ADT C++ code (look it up!), and DX9
fixed function. i'd been coding C/C++ games since before OO syntax,
and didn't really need the OO language extenstions, thus the
procedural ADTs. And Caveman has a paleolithic setting with no
magic or fantasy elements, so not much in the way of special effects,
smoke, flames, clouds, thats about it. so all i needed was
aniso-mipmapped textured meshes, with a little alpha test and alpha
blend. I do use a 2 stage textre blend for snow on the ground but
thats it. i was already familair with dx8, and hadn't learned
shaders yet - i hadn't needed them. still haven't really learned
them or needed them yet in fact. truth is, i'm a little scared
to get into shaders for fear i'll like it too much. the mere
concept of such power to "party on the bitmap" is...
intoxicating <g>.




At this point i should mention that Caveman was developed on a
budget of $0. one baseline $400 pc (no graphics card), and
internet access, thats all you get to work with. no money for
tools, content, middleware, etc.



Compiler:
ms visual studio of course. i started with basic, then pascal,
then watcom C, all in the quest for speed. sometime in the mid
90's microsoft got a clue and added the compiler optimizations
required for games to the free version of MC C++. And directx
tends to work better with ms c++ than with some other compilers.



3d modeler:
truespace rosetta 7.61 beta
1. its free
2. used to be the next best thing after 3dsmax
3. full directx .x save capabilities built in. no conversion /
import / export headaches.




2d paint programs:
paint.net and "free clone stamp tool".
both are free. paint.net has the basic capabilities of
photoshop. clone stamp takes up the slack. a really awesome
little texture painting program.


Audio tools:
TBD (to be determined)
i have xaudio 2 up and runnning but so far all it does is
play "time to relax", track 1 from the album "smash"
(as i recall) by the offspring as a test. it was the first
wav file i came across on my hard drive. the music for the
game is pretty simple, tom toms and flute for atmosphere,
funky beats reampped to jungle drum kits for combat. and i
have the general 6000 series 50 cd sound effects library
from Sound Ideas for foley sfx. but i gues i'll have to
build another bow. the sound of a primitive bow firing was
the only effect i had to make myself for the original version.
to do it, i made a 7 foot long bow, with fishing line for
the bowstring, and relatively straight wood sticks for
arrows. having paid $1000 for the sound effects
library, i was bound and determined to get my money's
worth out of it. so i used the box as the mike stand
while i recorded the sound of me firing the bow down
the hallway in the house! <g>.

up next:
step one, getting a handle on directx graphics.

part 3:
http://www.gamedev.net/blog/1730/entry-2259520-the-building-of-caveman-part-3-getting-a-handle-on-directx/

part 1:
http://www.gamedev.net/blog/1730/entry-2259487-the-building-of-caveman-part-1/


The Building of Caveman - Part 1

Posted by , 29 March 2014 - - - - - - · 1,080 views

The Building of Caveman, Part 1

in this series of posts i will explain the process of making the game
Caveman v3.0.

What was done and why.

this is done in hopes that it may help others in their quest for success.

first, who i am:

i'm life long gamer.

as a little kid (before computers!), wargames facinated me.
that big hex map with all that terrain, and all those unit counters! and the
dice and the charts! WAY too cool! there was something seriously cool going on
here!

then there were arcade games like "night bomber", a very rudimentary
b-58 hustler flight sim arcade machine. it had a backlit plastic 3d
conveyor belt of plastic for the ground mesh, and used some sort of illuminated
platic for the missiles in flight. then it was mirror projected to the view
screen of the cabinet. explosions were backlit under the "terrain mesh".
i can still remember the "shoo,shoo,shoo - booom, boom, BOOM!" sound effect
it made when you cut loose with a salvo of missiles. <g>. i was so little i
had to stand on a stool to play!

later came D&D, then Traveller, then both at once! Two years as president of
the wargame club in high school. I also designed few table top games during
this period. There was a super RISK type wargame with land, sea, air and
carrier units, land, sea, and air bases, and land sea, and air zones for
movement. There was a sharship combat game, turn based strategy with carriers,
battle crusers, fighters, and such. and there was a simple futuristic RPG
inspired by the first star wars movie, set in a huge abandoned space station,
the rules of which were made upduring one of those rpg club convetions a
friend took me to once. Everyone always wanted to play in my D&D world, i was
almost always the DM, seldom got to be a player, but i learned as a player
from a great dm (thanks John Durfee!). i learned one of my first and best
game design lessons there: NO MONTY HAUL!


About the same time, i took my first
programming class (sophmore in high school i think it was). interperted
basic on an ibm 360 mainframe accessed remotely via 3 dumb tremials and a
teletype terminal, each running at 1200 bits per second. <g>. I wrote a
turn-based clone of the arcade game "lunar lander" on that system. you'd
input your x and y thrusts, and then it would draw the next frame <g>.
You should have seen how many trees i killed when i ran it one time on the
teletype terminal. to clear the screen and draw the next frame, it did a page
feed. so every frame printed an entire page on an 18" wide line printer
teletype terminal. the classroom was awash with printer paper! <g>.

after high school, i used my buddy's mom's pc to write a text and vector
graphics turn based D&D game. it was a sperry rand pc with 64k, 2 360k
floppies and a CGA card. interperted basic on dos 2.11.

a couple years later i got my first pc, an 8khz 8088 overclocked to
10khz. word was, for second year physics lab, even if your experiment was
unsucessful, if you could write it up correctly with all the charts and
graphs etc in a word processor, "real professional like", you got an A.
so that was my justificsation for getting a pc. now adays its almost
de-regeur, i'd assume. at first i wrote a few apps in basic: text editor,
autoscheduler, quicken-type software, etc. and "flying saucer shooter" -
think missile command vs flying saucers, and you get ground based lasers.
my first realtime arcade game!

then i got into developing operating environments and integrated packages
(look them up!).I learned how to write just about every kind of app.

flash forward about 6 years. By this time i had almost completed my
software engineering degree at OSU (i switched from aerospace when the
cold war ended). i had worked as a systems analyst for the air force
as my engineering co-op, specializing in needs analysis and puchase
recommendations for executive information systems software (looks it up!).
i had also worked for the OSU school of medicine dept of anatomy where i
specialized in needs analysis and purchase reccomendations for
multi-media computer network systems (they were putting Gray's anatomy
online for the first time ever anywhere - in high resolution full
living color).

one day, me and a buddy were DLing Star Trek games, and they were all
the same top down view, sector quadrant, turn based text mode trek game.
i said, "I could write something better than that!" - and in six weeks, i had.
showed it to my friends. they said, "looks cool! needs better
explosions!" (you know how players are! <g>). so i added better explosions.

then i sent an email to the sysop of the biggest BBS at OSU, and asked him
very politely how he thought i ought to distribute it. he replied that the
model recently established by a new game called "castle wolfenstein 3d",
where you gave them a little for free (about 5% of the game - roughly $1
worth of content at wolf's originl price point of $20), and if they
liked it they paid for the full version. sounded good to me. but my game
was a mission based starship flight sim, not a level based shooter.
so i limited it to 4 types of missions (out of 10) and 10 missions
completed max (vs unlimited).

then i posted it to the local bbs's. about 3 weeeks later someone uploaded
it to AOL. i didn't even have an account. it became a top 10 download of
the week on AOL, with over 10,000 copies downloaded the first week.
all thanks to good copy in the file description (marketing, marketing,
marketing!), and a cool game to back it up. for a flight sim it was
pretty easy to play, as you could automatically lock onto any target with
the computers, and fly to it or attack it.

SIMTrek was followed by many other games, apps, and utilities on and off
over the years (this is the fourth time i've started or re-started my
software company).

i was blessed with a second hit when i restarted Rockland Software
Productions for the second time in 2000. Caveman v1.0 was picked up by
the local NBC news in Washington DC (where i live) as a last minute
xmas gift. response was so great it crashed the website!

about 3 years later, i got cracked by a team out of eastern europe.
the cracked version of Caveman v1.3 was posted on a warez site in
Africa, hosted on servers in Russia. it was probably on other warez
sites as well. losses were so bad, i had to fold the company.

in 2006 i started developemnt of caveman 2.0, a full first person
view virtual world implementation of the game, and almost finished it.
but i lost funding and the project had to be abandonded.

in 2012 i re-started rockland software productions for the fourth time.
so i was (re)starting my software company from scratch. what to build?

this is where the story of the building of Caveman begins...

part 2:

http://www.gamedev.net/blog/1730/entry-2259488-the-building-of-caveman-part-2-what-to-build-and-tool-selection/












,


A day in the life...

Posted by , 24 March 2014 - - - - - - · 1,193 views

A day in the life...

This will give you an idea of what its like to be an indie.

Tasks to be done on the project go on the "todo list". once they're completed, they're moved to the "done list".

here's the "done list" for Caveman for the last few days:

march 15th:
* draw prairie better - need ref photos. need prairie grass textures. made new grass mesh, new grass textures, new grass ground tiles, new grass drawing routine.
 
* draw savanna better - need ref photos. need red dirt tex. need brown grass tex. need acacia tree meshes. need acacia tree bark texxture. need acacia tree leaf texture. made acacia tree leaf texture, tree turnk mesh, and tree model. added ability to add a model to a chunk. added new draw tree routine.
 
 
march 16-17th:
* need to model getting lost better?     get lost too easily?  adjusted chance to get lost. some difficulty generting a low enough probabiltity check, as the dice() funtion can only go down to 1 in 32K chance. the odds are more like 1 in 2 million (or billion?) per frame.
* tried numerous (six?) methods for drawing rain, including particle system.  still no satisfactory solution.
 
march 18th:
* fixed weather engine (hopefully). world now split into 3 climate zones, hot, med, cold. sand, jungle, savanna only found in hot zone. limits placed on "temp at cm0", based on climate zone. so no snow in hot zone etc. 
* snow in jungle - weather engine
* different weather for different areas? improved weather engine
* snow in desert - weather engine
* snow in savanna- weather engine
* wood spear male 1st person atk ani - already fixed
* water quads - gaps at seams - already done
* water quads - increase clip rad - already done
* clouds move too fast? cut speed in half
* gap in ground mesh where flowing water meets ocean. need to change heightmap near ocean. if at edge near ocean, heightmap = lerp from std heightmap to zero.  fixed.  heightmap was returning water edges with no seam fixup. now it does water heightmap, then seam fixup.
seam fixup already accounts for ocean.
* fix heightmap where flowing water crosses map square edge. was caused by no seam fixup.
   now it does seam fixup.
* z fighting where flowing water meets ocean. made hm_flowing_water_edge routine that comes before (overrides) seam fix where water crosses map edge.
* ocean color is darker than flowing water. generate ground mesh: ocean was using ground material, not default material.
* add impass mtns to player map when they come into view
* automap the local map more often, spinting skips some local map squares.
* butcher animal - show % done. already done.
* should not get fatigue watching clouds etc. - you don't. its damage and encumberance doing it.
* animate player run (walk, actually) in cross country 3pv
* clouds move too fast, shouldn't move as fast as wind? cut speed 50%.
 
 
 
march 19th:
* player jump ani in 3pv
* 3pv, jump: make model go up/dn.
* fixed:  forward motion stops while jumping during continuous movement.
* jump: restart sneak ani from the beginning each time they start a jump.
* impass mtns - show msg, improve hgt map. already done.
* game starts in winter! fixed, starts in spring. 
* stargaze, etc - show mood during the action. did stargaze, watch clouds, sing, dance, play drums, play flute, and daydream.
* draw player upatree in 3pv.
* dont draw player upatree so high in a tree in savanna.  upatree increases y by 20.  this is done many places in the code, hard coded as 20. making it a variable would be major work. probably not worth it. 
* superclip4 was clipping bandmember upatree. turned it off for drawing current bandmember upatree.
* move upatree height down to work with acacias, as well as taller trees. so that hard coded 20 became a #defined constant after all.
* disable move, climb, sneak, and jump when upatree
* moving manually, fatigue hits 100%, triggers rest action, speed doesn't drop back to normal at end of rest action. fixed. it was pushing donothing on the action stack. when rest ended, it would pop donothing and not change speed, instead of setting action to donothing and speed to normal.
* increase clip rad of acacia tree model. same issue as 3pv clipping of player up a tree? superclip not working for objects below the camera?
* sleep doesn't take long enough? increased base time from 1500 to 1700.
* green sky, just before noon? fixed. limited r,g,b to 255. brighter sky was probably causing wrap around.
* should rain wake you up? rain and snow now wake you up when it starts to rain or snow.
* rest - if no action afterwards, set gamespeed to normal (1). already done.
* use old flat heightmap for swamp
* rest action: show fatigue %
* ACTION AREA FOR RIVER NOT WIDE ENOUGH? fixed. increased from 20 to 30 radius.
* river quads dont quite reach to edge of river bank. fixed. increased draw rad from 30 to 40.
* small deer are too small and slow. fixed. animal 28. scaled model by 1.5. changed texture and moved horns so it wasn't just a smaller version of animal 11. increased speed to .4
* improve heightmap where flowing water crosses map edges.
* more stars at night - double up the textures
 
march 20th:
* savanna being generated in bottom 1/2 of map, not bottom 1/3!
* need non-tropical savanna. same as savanna, appears in northern 2/3 of world, uses regular tree models.
* regen terrain chunk if waterhole or creek goes wet/dry. covergae can change too. and other types of water. 2 choices: 1. regen map sqaures that change. 2. invalidate all chunks when the map changes, forcing regen of all chunks. made it init_chunks after change_the_map. no problem. runs plenty fast. didnt even notice it re-generating all visible chunks.
 
 
march 22nd:
* input mapper. can remap input controls to any key or mouse button.  added new playetest menu, triggered by alt-F12.  moved playtest hotkeys (including old playtest menu) to new playtest menu. pain in the ass. lot of typing. 2 days. 33 input controls, mappable to any key, or L or R mouse button. needed a routine to return the name of a key/button.  numbers, function keys, and letters were easy. everything else required a huge switch statement. same thing when checking what key they pressed. tons of typing.
* falling snow needs help - need to get online.   current effect is passable. good enough for now.
* rain: need better rain effect - need to get online.  made rain tube w/ endcaps. tube is cylindrical mapping scaled 30x10, endcaps are planar mapping scaled 10x10. uses 4 animated textures in round robin fashion. tube is unit size, scaled to 3 ft height and diameter around the camera.
 
march 23rd:
* improved caveman font
* dropped lit torch - animate flames !
use torch model. save head texture. change head texture to flames, and also draw a quad with flames. similar to flaming javelin. restore head texture when done.
should a lit torch go out if you drop it? - No.
make flaming torch model - animate the textures before drawing
done. model already made. animated the textures, set material to beacon.
* crc check for corrupt savegame files. give option to load backup if corruption detected
did checksum. added to z3d library:
appendfilebin()
filesize()
file_checksum_ok()
calc_checksum()
append_checksum()
made the game load save "b" if no save "a" found.
added checksum to save and load game. shows msg if checksum bad. aborts load.
ran quite slow at first, doing it one byte at a time, 15 seconds? made it use 2K buffers. takes about 2 seconds. maybe 4 from disk. not bad for a 67 meg savefile.
* add optimize meshes to playtest menu. remove optimize mesh from loadmeshes.
 
 
 
march 24th:
* skybox not low enough. fixed. made it unit size, centered on origin. made it draw at scale 3, centered on camera.
* made sun and moon draw centered on camera, not player at y=0. skybox centered on camera and sun/moon centered on player caused parallax motion of moon when you slew the 3pv camera around.
* fixed block ani 1pv
* block ani 3pv
* draw lit torch in hand, 3pv. added draw_lit_torch_BM(). added drawinlh(). 
* draw lit torch in hand, 3pv, animate the flames. set material to beacon.
* change defult mapping of "sheath wpn" to the "F" key. "H" is too far from W and left shift
 when you're trying to sprint away and sheath your weapon to move faster.
* remap input: doesnt list all control names correctly (function keys). both remap and get_vk_name used string manipulator at same tme! made get_vk_name use its own internal string.
* add: reset input controls to default mapping.
 



The basic game is DONE!

Posted by , 24 March 2014 - - - - - - · 1,047 views

that's right...

after taking a break and evaluating skyrim, my motivation levels were back up. A final push, and as of 7pm eastern time, march 24th 2014, the basic game is done!

and my original estimate of how long it would take was pretty accurate: about 2 years, working full/over time.

all that's left is adding on new high end features.

well, that and audio....

but the music is simple native tom-tom and flute stuff, the main theme music has already been written (for version 1.0), and the combat music is just a decent funky 4 measure drum loop remapped to a cool jungle drum kit. it would be trivial if my Alesis drum machine still worked. I plan to DL some freeware tools for that. voice acting consists of 40 samples, 20 male and 20 female, saying the 20 syllables in the caveman language. then you just play them in the correct order to say anything in the caveman language. i may just have them say random syllables. but i do have to get the infamous "bah-gah-bah" in there.

In the original version, it played like a FPS when you were in combat, a settlement, or a cavern. the rest of the time it played like TheSIMs. you'd pick an action from the actions menu, and your caveperson would say "bah-gah-bah" as if saying "Ok", then go off and do the action. when they finished, they'd return to the center of the scene, and say "bah-gah-bah" again, as if saying "all done!". for the foley effects, i have the general 6000 series 50 cd sound effects library from Sound Ideas out of canada. so i'm good to go there. paid $1000 bucks for it at CGDC '96. one of the best gamedev purchases i've ever made. and about the only content i've ever paid for. well, that and pyromania 1 and 2.

and it doesn't do animations of your cave person performing an action such as picking berries, like the first version did. but it can draw a mesh or multi-mesh model in a character's hands, and it can draw every object in the game, and there;'s the built-in animation editor. so its simply a matter of making some generic animations for different actions (pick.ani, hammer.ani, etc) perhaps 1-2 dozen (watch - it'll be 50! <g>). then add some code to set the camera for a good animation view, set the model's animation to "hammer" or whatever, and just draw that as the action completes. right now it just draws whatever's in front of the camera, with a progress message - no animations of you doing stuff.

i've divided the remaining new features/improvements into: code, graphics, and new: actions, skills, animals, objects, etc.

remaining coding tasks have been divided into: important, less important, and "even less important". <g> there's also an "easy" category, which i'll knock out tonight.

here's whats on the "important" list. some folks here may recognize some features they've offered suggestions about. this is a direct copy and paste from the Caveman todo list, so you can see the actual workflow document (note the time estimates on some features):
 
* option to disable windows key - need to get online
 
* adjustable diff levels for:
healing rate
hit points
caveman encounters
animal encounters
party strength (affects number appearing)
 
* number keys for select wpn
 
* yield, surrender, and parlay
1 DAY
 
* add thief encounters. guy walks up, "gimme all your stuff or else!"
1/4 DAY
 
* add slaver encounters. attack to subdue. capture. model escaping, etc. - REQUIRES ADDITIONAL AI 
2 DAYS
 
* kidnappers: like thieves and bushwhackers and slavers. attack to subdue. take captive, but to ransom you back, not sell off as a slave.
1 DAY - ONCE SLAVERS ARE DONE
 
* add encounters with traders who do settlement trader's hut type trading (IE professional traders). make friendly cavemen just do "what i got on me" trading 
 
(amateur traders).
 
* questgen
1 WEEK
 
* raiding and inter-band rivalry/conflict, and  forming alliances with other bands. 
3 DAYS
 
* romance, mating, offspring.
tied to relations. 
mate action on talk to caveman
need very good relations + opposite sex + physical attraction
need to track who is who's mate, and who has no mate
mating may lead to offspring.
pregnancy: food, water, sleep go down faster. fatigue goes up faster. movement rate goes down. damage or illness has chance of causing miscarriage.
physical attraction: charisma, but more - phermones - genes. compatability. hmm...
the 6 way street:  2way like, 2 way love, 2 way lust.
3 DAYS
 
the questgen is big, probably a week. mating may take more than 3 days. diff levels and hot keys, probably less than a day. yield, parlay, and
surrender, a few hours. but then you have to model escaping too. All the new encounter types can be done in 2 days. raiding might only take
2 days, maybe just one, or even less, basically its just triggering an encounter. but you do have to model who's at war with who.

wait and see how it goes.

time to get back to work.

whats next?

ah yes, give the player a chance to recognize
they're lost and stop travelling cross country.
add an is_lost variable to a bandmember struct.
set it to false when they start to travel cross
country. set it to true if they get lost.
when you check for getting lost, if they're
already lost, check for them recognizing they're
lost, and stopping.

til next time...

code once, test twice!


Progress Report: March 2014

Posted by , 06 March 2014 - - - - - - · 786 views

Few progress reports, but lots of progress:

All Improved animal animations done - even the new bunny_attack animation! <g>. The improved animations really bring the animals to life. Sometimes i'll be testing something and its like really being back in a paleolithic world.

Took some time out to finally give Skyrim a thorough evaluation. Oblivion was a major influence on the design of the original version of Caveman. I came away quite pleased with where Caveman is vis a vis Skyrim. Obviously i don't have the manpower to match them in graphics special effects or human generated content. OTOH, I found the changes between Oblivion and Skyrim to be evolutionary, not revolutionary. And it still suffers from the same design flaws as Oblivion (hard coded levels, hard coded spawn points, nothing to spend money on, rat in a maze level design, etc) plus new ones brought on by trying to add random encounters w/o thinking through the consequences (dragons, vampires, etc kill all the merchants!) and therefore not having a complete and balanced model/simulation (new merchants move in to replace those that die). Guess that's what happens when you try to add simulator type stuff to whats basically a level based shooter and don't think like a sim developer.

Spent some time (about week) playtesting and tweaking. Surprisingly little needed to be tweaked.

Implemented encounter ranges based on terrain elevation and vegetation cover.

Did final (?) improvements of caveman models.

Implemented all animations for 3rd person view:
stand
walk, run, and sprint - forward, back, left, and right.
sneak stand
sneak walk - forward, back, left, and right
climb mode stand (hang on) and walk (climb)
weapon ready
attack animations

graphics left to improve:
rain
falling snow
stars
prairie terrain
savanna terrain
cloud and sky brightness (both are a little dark right now)

this will bring all the graphics up to the minimum level acceptable for first release of this major new version of the game.

then there are a number of additional game play features to add, from interacting with snow, to taking rafts upstream, to high end stuff like raiding and inter-band rivalry, mating and offspring, etc. But these largely require just code, which i can kick out much faster than graphics. All the design work and rules have been worked out already, its simply a matter of typing it in. And for that i have Cscript, my secret productivity weapon.





March 2014 »

S M T W T F S
      1
2345678
9101112131415
16171819202122
23242526272829
3031     


PARTNERS