Coding Stuff

The land-based version of Allegiance, under construction.
radruin
Posts: 314
Joined: Mon Nov 13, 2006 11:55 pm
Location: North Carolina, USA

Post by radruin »

The core files are probably going to be server-side only; there's no reason for Average Joe to have access to them without specifically downloading them or something. It's the server that needs the file, not the client.
QUOTE I think there should be a maximum of 20 Factions per core for the time being. I doubt we will ever have that many but just in case. the reason is for faction uID's.[/quote]I still don't understand the uID thing...
Image
QUOTE (Cadillac)Does that mean that dying is effectively a perma-ban from the "Life" server?[/quote]
the_dare
Posts: 481
Joined: Sat Sep 15, 2007 11:10 pm
Location: Bath, UK

Post by the_dare »

uids make it easier to refer to things! eg in code!
Image
Image
the_dare
Posts: 481
Joined: Sat Sep 15, 2007 11:10 pm
Location: Bath, UK

Post by the_dare »

Corename
Core Creator
Unique ID

CapacityHe3
ValueHe3
AmountHe3
He3Regeneration
MountRate
SecondsBetweenPaydays
StartingMoney
Income
RipcordTime
ExitAlephSpeed
ExitStationSpeed
GroundVeichleBaseSpeed
AirVehicleBaseSpeed
GroundUnitBaseSpeed
LifepodEndurance
AlephResDelay


so far only global done
Image
Image
the_dare
Posts: 481
Joined: Sat Sep 15, 2007 11:10 pm
Location: Bath, UK

Post by the_dare »

update i am looking into xml for the cores!
Image
Image
Gandalf2
Posts: 3943
Joined: Wed Oct 13, 2004 7:00 am
Location: W. Midlands, UK

Post by Gandalf2 »

QUOTE I still don't understand the uID thing...[/quote]

OK, lets say you have a list of factions. Bios, Giga and IC. You reference this list elsewhere, eg if faction = bios, then display bios model. Now let's say, sometime down the line, you decide Bios is a stupid name for a faction and you want to change it to Zerglings. OK, but now you've gone and referred to Bios elsewhere in your code. Disaster! You'll have to go and track down every reference of Bios in all your code, it#'ll take you ages and it'll probably still be throwing up bugs months later.

But, if you have a unique ID for each, then you'll be fine.

eg,
ID Faction
1 Bios
2 Giga
3 IC

You use the ID elsewhere in the code when referring to a faction. Now when you change a faction name, the rest of your code works fine as you linked to the ID, not the name /smile.gif" style="vertical-align:middle" emoid=":)" border="0" alt="smile.gif" />

Perhaps a slightly silly example, but I hope it shows the point /smile.gif" style="vertical-align:middle" emoid=":)" border="0" alt="smile.gif" />
Image
Image
spideycw - 'This is because Grav is a huge whining bitch. But we all knew that already' Dec 19 2010, 07:36 PM
HSharp
Posts: 5192
Joined: Fri Aug 11, 2006 11:18 am
Location: Brum, UK

Post by HSharp »

Dont forget to use OOP, OOP is your god and you must obey it!
Image
Image
radruin
Posts: 314
Joined: Mon Nov 13, 2006 11:55 pm
Location: North Carolina, USA

Post by radruin »

OOP /wub.gif" style="vertical-align:middle" emoid=":iluv:" border="0" alt="wub.gif" />. I started out with Java in HS, so I understand it just fine.
Image
QUOTE (Cadillac)Does that mean that dying is effectively a perma-ban from the "Life" server?[/quote]
Post Reply