[MUD-Dev] Thinking outside of the room . . . ur . . . box
Daniel.Harman at barclayscapital.com
Daniel.Harman at barclayscapital.com
Thu Jul 31 10:31:02 CEST 2003
From: Nolan J. Darilek [mailto:nolan at thewordnerd.info]
> Within the game, many of the shapes used will be rectangles as to
> make navigation a bit easier (I'm not entirely sure how to handle
> oddly-shaped rooms as of yet.) I would, however, like to offer the
> option of making triangles, octagons, whatever your twisted
> builder heart desires. :) I thought about doing this with a
> generic polygon containing a list of vertices, but are there any
> generic algorithms for taking a polygon of N sides and determining
> whether a point is contained within, or is this problem solved on
> a case-by-case basis (I.e. define a triangle class, rectangle
> class, etc.?)
Various techniques for handling this and they are on the whole
generic. N.B. It gets more complex if your polygons can be convex,
so I recommend disallowing this :)
> I'd also like to handle non-flat surfaces. I don't necessarily
> mean highly-detailed mountains with narrow ledges and lots of
> random contours . . . but I'd like a way to, say, walk down a
> road, up a hill and have your radius of visibility expand, walk
> into a valley and lose sight of the castle beyond the last hill,
> etc. Given that I'm only aiming for reasonably simple inclines,
> are there any good mechanisms for handling something like this?
Probably a height map based system. They are a relatively compact
way of representing this information, well relative to a polygon
soup at any rate.
> I'm not sure if this last requirement is horribly naive . . .
> but, as this platform will be 3-D (albeit with a more simplified
> structure) I'd like to offer graphics of some sort in the future
> (though this isn't an initial design goal and, in fact, may be
> struck entirely.) As descriptions consist almost entirely of
> nearby objects, it seems possible that I might be able to split
> object descriptions into several specifications. Text descriptions
> could contain strings with hints, while a graphical specification
> could list URIs for tiles, relative placement, etc. Not having
> much experience with graphics programming, I'm not sure what
> details the specification would need to export to the
> client. Also, assuming I use polygons to create objects, it seems
> that I might be able to achieve some level of 3-D graphics but
> again, not knowing much about how such things are structured, I
> could be horribly naive about this. I'm definitely not aiming for
> something to compete with commercial 3-D RPGs (especially as much
> of my interaction will still be text-based) but, assuming I wanted
> to create some sort of graphical representation of my world, what
> might be best? Tile-based? Simple 3-D? Or should I just scrap
> this crazy notion and stick with doing text very well? ;)
Well if you plan on adding 3D gfx in the future, you would be well
served to understand how it works before implementing a text
version. It would be very easy to make mistakes that would make the
enhancement tricky if you proceeed without the necessary knowledge.
Depending on what you want to do, 3D isn't out of the realms of
possiblity, but it has the potential to derail your project as the
complexity and development time will increase significantly. You
also tend to end up with a dependancy on an artist (or a library of
quake models!) when it comes to having animated characters etc.
By moving to 3D you will likely be adding the following tasks to
your workload beyond writing of the actual rendering code :
- Path finding.
- Control of working set size (models+skins need to fit on the
gfx card).
- Collision detection.
- Model creation.
- Line of site tests (ray casting).
- Complex network code (look in the archives for this, but TCP
isn't too suited for non text based games).
There are probably more I haven't thought of too.
You might be well served to leverage other peoples work in these
areas. The 'Nebula Device' project is a 3d engine that might well
server your purposes. In terms of handling networking code etc, you
might look at the 'Twisted Framework' or 'Beyond 2'. The latter two
are python based which might well be a disadvantage - it has
certainly put me off using them.
Dan
_______________________________________________
MUD-Dev mailing list
MUD-Dev at kanga.nu
https://www.kanga.nu/lists/listinfo/mud-dev
More information about the mud-dev-archive
mailing list