Jump to content

Help with a class project


Recommended Posts

Okay, this isn't exactly modeling related but it is a project I'm working on, it is a work in progress and it is 40k related. Here is the situation:

 

I'm taking a database design class. And in the class we have to design and build a program that makes use of database systems. Well I hit on the idea of building a 40k army builder program. Not trying to compete with Army Builder, or step on GW's toes or anything like that. This is intended to be my class project and nothing more. Originally I was going to try and make the army builder capable of building any army from any book in the game.... but that's quickly growing beyond the scope of what I can accomplish in the term of the class. So now I'm parring it back to just Space Marine and Chaos Marine armies.

 

So the first step in designing the database is compiling a list of rules. If your mental process is anything like mine you're looking at that line and saying "What counts as rules?"

 

Well, it's quit literally the rules of the game as they pertain to the units. Here's an example:

 

Total points can not exceed "Game size" value.

 

Meaning if the selected Game size is 2000, the army that is assembled can be less than or equal to 2000, but it can not be more then 2000.

 

So what do I need help with? Well just listing out the rules. I'm slowly working my way through my books to compile the rules for the system. Annoying I keep forgetting to swap the book I have in my bag when I leave for the day so for the last 3 days I've only had the Badab War Part 1 book to work from.

 

Here is the list of the rules I've already thrown together:

  • You may not have more than 1 “Unique character(name)” in your army. (Example: You can have Commander Dante and you can have Lord Commander Culln, but you cannot have 2 Commander Dantes or 2 Lord Commander Cullns.)
  • You may take not more than 1 Commander Culln (There are multiple versions of Commander Culln. A given army may only have 0-1 Commander Culln)
  • If Lord High Commander Carab Culln is taken, no other “Chapter Master” type space marine characters may be taken.

 

Wargear

  • Terminator armor causes a unit to count as 2 infantry models
  • Terminator armor changes a unit “Save” to 2+ and adds an “Inv_save” of 5+ to the unit
  • Adding a “Jump pack” changes a unit type to “Jump Infantry”
  • Adding a “Bike” changes a unit type to “Calvary”
  • Adding a “Bike” adds 1 to the unit toughness
  • If a bike is taken, terminator armor may not be taken.
  • If a bike is taken, Jump pack may not be taken.
  • If terminator armor is taken, a bike may not be taken.
  • If terminator armor is taken, Jump pack may not be taken.
  • If a jump pack is taken, Terminator armor may not be taken.
  • If a jump pack is taken, a bike may not be taken.

 

Vehicles:

  • Rhino transports can carry 10 infantry sized models
  • Rhino transports may not carry bike.
  • Rhino transports may not carry Jump Infantry.
  • Land Raiders can carry 12 Infantry Sized models
  • Land Raiders can not carry jump infantry
  • Land Raiders can not carry Bikes.
  • Land Raider Redeemers can carry 14 Infantry sized models
  • Land Raider Redeemers can not carry jump infantry
  • Land Raider Redeemers can not carry Bikes
  • Land Raider Crusaders can carry 16 infantry sized models.
  • Land Raider Crusaders can not carry jump infantry
  • Land Raider Crusaders can not carry Bikes
  • Razorbacks can carry 6 Infantry sized models.
  • Razorbacks can not carry jump infantry
  • Razorbacks can not carry bikes.
  • Chimeras can carry 12 infantry sized models.
  • Chimeras can not carry jump infantry.
  • Chimeras can not carry Bikes.
  • Storm Ravens can carry 12 infantry models.
  • Storm Ravens can carry jump infantry.
  • Storm Ravens can not carry bikes.

Link to comment
Share on other sites

not sure how much we can help by posting rules up without infringing board rules

 

i did something similar for my GCSE's using VB (version 6.0 i think to give an idea how long ago this was)

 

if you label culn a unique then you dont need the individual rule for him as it will be caught as only 1 unique model per army. that said - sergent upgrades like telion shouldnt be unique so if there is a sergent rule for him you'll need a 'culn' rule still.

 

i apologiese if i'm preaching to the converted in how to make this, just in case this is how i would design it from a relational databases point of view:

 

tables for all changeable elements, so Warger, armour, unit type

 

unit type would include the basic stat line and rules that dont change for a given unit

 

additional rules should be linked to options stored in related tables eg armour

 

type save desciption Rules

PWR 3+ Power Armour

TERM 2+/5++ Terminator Armour No sweeping advance

ART 2+ Artificer Armour

 

your front end program will pull details from the tabe to updat the basic information in the unit type

e.g radial options on a say captains page would set armour type to one of the above. your front end will give the pretty display of the updated profile/rules. the back end list table will look something like this

your army list entries should end up in a tabe like this (nowhere near complete)

 

listname,unit,Armour,Squad leader,wep1,wep2,Bike/jump,pack,Melta Bombs,heavy,Special,Standard Rules

army1,Tacticals,PWR,yes,BP,pwrswd,-,,Y,ML,FLA,Combat squads

army1,captain,ART,-,Relic blade,stormshield,Bike,Y,-,-,

army1,Terminators,TERM,yes,Storm bolter,Power sword,-,-,CML,-,-

 

you then basically only need to run a report on your database for entries based on the army name to get the list out and it will be your report design that makes it pretty to read by pulling the required fields

 

with this design your rules above get limited to a bit of programming on the front end to manage options that disqualify others e.g. bike/terminator armour/jump pack and things like transport capacity/what a vehicle can carry is a straight rules entry in a basic units table as it doesnt change

 

though i've not shown this above, you may want to consider combat tactics as a special rule set by the commander unit type due to special characters overwriting this (so a column of its own referencin the army commander entry)

 

hope this makes a little sense

 

edit: formatting on 2nd table died horribly so have changed to CSV and reworded/changed a bit of what i'd included

Link to comment
Share on other sites

not sure how much we can help by posting rules up without infringing board rules

 

i did something similar for my GCSE's using VB

 

if you label culn a unique then you dont need the individual rule for him as it will be caught as only 1 unique model per army. that said - sergent upgrades like telion shouldnt be unique so if there is a sergent rule for him you'll need a 'culn' rule still.

 

i apologiese if i'm preaching to the converted in how to make this, just in case this is how i would design it:

 

Rules like transport capacity should be standard entries for the given unit. adiditonal rules should be linked to options stored in related tables eg armour

 

type save desciption Rules

PWR 3+ Power Armour

TERM 2+/5++ Terminator Armour No sweeping advance

ART 2+ Artificer Armour

 

Yeah you're stepping into the same trouble I had trying to understand the differences between "Rules" and "rules". I'll try to explain, and hopefuly clarify it for myself as well.

 

You have: Unit(Space Marine Commander)

Unit(Space Marine Commander) has the attributes:

WS: 4

BS: 4

S: 4

T: 4

W: 3

I: 4

A: 3

LD: 10

SV: 3+

unit size: 1

unit comp: 1 model

Inv Save: 4+

Points: 300 points

 

(just kind of pulling stats up off the top of my head here.)

 

Sweeping advance is not shown in those stats in any way, so there is no need to make a rule(database rule) for it, while it makes a difference to game play I'm not building a simulation system. Terminator armor does change several of the stats, namely the Inv save, the Save, and the points. Thus those changes can be reflected in the stats rendering:

Unit(Space Marine Commander) has the attributes:

WS: 4

BS: 4

S: 4

T: 4

W: 3

I: 4

A: 3

LD: 10

SV: 2+

unit size: 2

unit comp: 1 model

Inv Save: 5+

Points: 400 points

 

It's still a single entry, but giving it Terminator armor has other effects, such as not being able to be transported in Rhinos and Razorbacks. So I made a rule that says "Rhinos can not transport Terminators"

 

Also the problem with using a label like "Unique" and using that as a 1-only limit, is you can have more then 1 entry in an army that is unique. Like you can have Lord High Comander Culln and Chief Librarian Tigerius, both of which are unique. But you can not have Lord High Commander Culln and Marneus Calgar because both are Chapter Masters and Lord High Commander Culln has a rule that you can not have a 2nd chapter master if you take him.

 

radial options on a say captains page would set type to one of the above and update the save value for his profile plus add additional rules to his description linked from this table

you would also have a master wargear table and check boxes on a given unit entry that referencese th table and adds the rules

 

your army list entries should end up in a tabe like this

 

unit Armour Squad leader wep1 wep2 Bike/jump pack Melta Bombs heavy Special Standard Rules

Tacticals PWR yes BP pwrswd - Y ML FLA Combat squads

captain ART - Relic bladestormshield Bike Y - -

Terminato TERM yes Storm bolter Power sword - - CML -

 

on this basis rules will be pulled as part of your front end program from the relevant table(s).

 

you will also need to program rules into the front end to disable things that aren't allowed eg. taking Meltabombs if equiped with terminator armour.

you may want to consider combat squads as a special rule set by the commander unit type due to special characters overwriting this.

 

now see "can not take meltabombs if taking terminator armor" are the types of rules I'm asking for.

Link to comment
Share on other sites

i understand the differences - i just cant explain them very well :)

 

rules like terminators cannot be transported in rhinos are games rules though so dont need to be added for an army list program as code (this includes all your vehicle rules) but could be an entry in the standard rules for that vehicle unit type that is pulled when the army list is printed

 

of your rules above - these need code:

•You may not have more than 1 “Unique character(name)” in your army. (Example: You can have Commander Dante and you can have Lord Commander Culln, but you cannot have 2 Commander Dantes or 2 Lord Commander Cullns.)

•You may take not more than 1 Commander Culln (There are multiple versions of Commander Culln. A given army may only have 0-1 Commander Culln)

•If Lord High Commander Carab Culln is taken, no other “Chapter Master” type space marine characters may be taken.

 

Wargear

•Terminator armor changes a unit “Save” to 2+ and adds an “Inv_save” of 5+ to the unit

•Adding a “Jump pack” changes a unit type to “Jump Infantry”

•Adding a “Bike” changes a unit type to “Calvary”

•Adding a “Bike” adds 1 to the unit toughness

•If a bike is taken, terminator armor may not be taken.

•If a bike is taken, Jump pack may not be taken.

•If terminator armor is taken, a bike may not be taken.

•If terminator armor is taken, Jump pack may not be taken.

•If a jump pack is taken, Terminator armor may not be taken.

•If a jump pack is taken, a bike may not be taken.

 

additional rules will be things like:

tacticals - enable heavy weapon options if +5 men taken (remember to reset it to blank if this is then deselected)

tactical termiators - enable 2nd heavy weapon option with 10 models

tactical terminators - one tactical terminater unit per army may take a landraider as transport

assault terminators - one assault terminater unit per army may take a landraider as transport

 

 

also you may want to code in force organisation charts as these set the limits for number of types of unit

 

what are your creating this with?

Link to comment
Share on other sites

i understand the differences - i just cant explain them very well :)

 

Well at least we're in the same boat with it.

 

rules like terminators cannot be transported in rhinos are games rules though so dont need to be added for an army list program as code (this includes all your vehicle rules) but could be an entry in the standard rules for that vehicle unit type that is pulled when the army list is printed

I suppose once I get to the actual coding part of the process that is exactly what will happen. But my teacher (Upon my explaining the concept of... well a great many concepts about the game to him) was very emphatic about the whole "The Rhino can not transport Terminators" and "Storm Ravens can not transport bikes" sort of rules. Not totally sure if it'll work into the program itself beyond a string of text but yeah there it is.

 

also you may want to code in force organisation charts as these set the limits for number of types of unit

 

Already planning on it. I'm going through my books to build charts for the various force org charts.

 

what are your creating this with?

 

Access and MySql.

 

This all beyond my basic ability, but one thing I can suggest is FOC minimums, and a 2 FOC for 2000pts+.

 

Cheers,

Jono

 

I'm going to build a function to add additional FOCs above 2000 points. 2 FoC for up to 2,000 (to allow for allies) 3 for 2,001-3,000, 4 for 3,001-4,000 ect ect. If you want to use a single force org you will be able to.

Link to comment
Share on other sites

i guess it comes down to your project write up to explain the difference between games rules and what needs to be coded to limit user options and including in your spec that its only a list creator and not a game simulator so you dont have to include all game mechanic rules as limits etc

 

access will be good for creating the interface as you can just drag and drop components out on the screen and it will do most of the coding work for you then and you just have to document why you use drop boxes or groups of radial buttons to limit user choices.

 

good luck! ;)

Link to comment
Share on other sites

i guess it comes down to your project write up to explain the difference between games rules and what needs to be coded to limit user options and including in your spec that its only a list creator and not a game simulator so you dont have to include all game mechanic rules as limits etc

 

access will be good for creating the interface as you can just drag and drop components out on the screen and it will do most of the coding work for you then and you just have to document why you use drop boxes or groups of radial buttons to limit user choices.

 

good luck! :)

 

I admit I might be approaching it the wrong way, but for my thinking I'm trying to break down rules and unit abilities into respective tables, so for example I have Table: Space_marine_hq, Space_marine_fast_attack, Space_marine_dedicated_transports and so forth. But I want to avoid having to build special exceptions for crazy stuff like

 

Take a Space Marine Commander.

Put him on a bike.

Add a command squad on bikes.

Mount in a Storm Raven.

 

Storm Ravens can't carry bikes.

 

And now that I spell that out so I can read it myself I'm not sure that can happen anyway.

I donno. it's a learning experience all around I suppose.

 

I had a bit of a creative streak last night and put brain to mouse and came up with some mock up shots of what I want to make the program interface look like:

 

Opening screen of the program:

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-001.jpg

 

So here is the first screen you would see when loading the program.

 

Then you go to select your intended army to build:

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-002.jpg

I want to build some eye candy into the program so I'm look into building this menu so that when you select a given army, the background image changes to represent the army in question. Like so:

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-004.jpg

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-006.jpg

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-008.jpg

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-010.jpg

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-012.jpg

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-014.jpg

 

And then you let the drop down menu close:

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-003.jpg

 

It displays a little blurb about the army in question. Just a bit of filler fluff to encourage folks to be more characterful with their army I guess.

 

And then you select your game settings, point size and allies:

No allies

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-032.jpg

 

Allies:

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-031.jpg

 

 

And then you get to the actual army screen where you can select each section of the army (Troops, HQ, Elites, ect) and add a unit to that slot.

http://i14.photobucket.com/albums/a316/maverike_prime/Warhammer/mockup-033.jpg

 

Of course right now the army is invalid because it doesn't have an HQ or 2 troops in the primary detachments and no HQ or troops in the allies detachments. But those are details the aspiring generals must overcome.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.