.com.unity Forums
  The Official e-Store of Shrapnel Games

This Month's Specials

Raging Tiger- Save $9.00
The Star and the Crescent- Save $9.00

   







Go Back   .com.unity Forums > Shrapnel Community > Space Empires: IV & V

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #4  
Old April 11th, 2008, 07:24 AM
Ed Kolis's Avatar

Ed Kolis Ed Kolis is offline
General
 
Join Date: Apr 2001
Location: Cincinnati, Ohio, USA
Posts: 4,547
Thanks: 1
Thanked 7 Times in 5 Posts
Ed Kolis is on a distinguished road
Default Re: EGGS - yet another programming project

If you're getting at what I think you're getting at (namely that using class/interface inheritance via C# code rather than ability inheritance via my library would be more efficent), I don't disagree, but that rather defeats the purpose of the library, since if I hardcoded more relationships, that would make the library less flexible.

I have hardcoded a few relationships, of course - with nothing hardcoded, there would be no code at all and it would be completely useless! For instance, inherent abilities are ALWAYS inherited from an entity's archetype, up the hierarchy of archetypes until a circular relationship is found or there are no more archetypes. Of course, if you don't want that to happen, you just don't set an archetype.

I guess what I'm basically doing is implementing a sort of pseudo-object-oriented framework in an object-oriented language. It seems redundant at first glance, but I'm not just designing for the end user (i.e. a programmer using my library), I'm designing for the end user's end user (i.e. someone with programing knowledge who wants to script/modify something written with my library).

Keep in mind also that the whole ability thing isn't everything - since this is for strategy games in particular, I also plan to have coordinate systems such as hexes and Cartesian planes, and a knowledge system whereby a user of the library can create "reports" on entities, which basically say what the location of an entity was at a point in time and what its abilities were.

All that a player will know about, incidentally, is the reports that he or she has received - only the game host will have the actual entities, so as to prevent cheating and reduce bandwidth usage! Actually, I suppose when I implement the player class, to avoid wasting bandwidth retransmitting old reports, I can just have the reports cached locally on the player's machine... that was one of the flaws of the "Cosmic Crises" game I was working on at one point (not to mention of SE5 though only with log messages and combat replays ) - old reports were retransmitted every turn, bloating the turn files! But then that might not be so great as you'd have to keep all your old turn files around to actually access the reports... hmmm...

Of course, if you're not writing a strategy game, you can ignore the reports, and if you're not even writing any sort of simulation of a physical space, you can leave out the locations, etc.

Writing a utility library is really a balance between 3 things: the ease of writing the library (e.g. how long does it take to write?), the comprehensiveness of the library (e.g. does it do feature X out of the box?), and the flexibility of the library (e.g. is it even possible to do feature X and still use the library?). Increase one and you must decrease one or both of the others
__________________
The Ed draws near! What dost thou deaux?
Reply With Quote
 

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 07:46 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2025, Shrapnel Games, Inc. - All Rights Reserved.