#exult@irc.freenode.net logs for 21 Nov 2005 (GMT)

Archive Today Yesterday Tomorrow
Exult homepage

[00:01:32] --> ShadwChsr has joined #exult
[00:01:38] <ShadwChsr> hey :)
[00:07:05] <Baastuul> Harro, harro.
[00:09:45] <ShadwChsr> :)
[00:24:18] <ShadwChsr> So quiet around here these days ;)
[00:35:41] <Baastuul> Yup.
[00:35:44] <Baastuul> I'm writing a paper right now. :(
[00:35:55] <ShadwChsr> ahhh
[00:38:54] * Baastuul is filled with a sudden urge to destroy you!
[00:38:56] * Baastuul destroys you.
[00:39:04] <ShadwChsr> :P
[00:39:39] <servus> I don't feel very destroyed
[00:39:56] <Baastuul> Whhhooo arrree yoooou!
[00:40:24] * Baastuul points a quivering finger at servus and mimics a facial expression of dramatic shock tinged with outrage and anger.
[00:41:44] <servus> The game. Lost.
[00:44:32] <ShadwChsr> Hey servus, how does U6 handle sprites?
[01:13:00] <servus> I dunno. Ask yuv?
[01:17:51] <Baastuul> whodat?
[01:21:20] <servus> Check #nuvie ? :)
[01:26:49] <Baastuul> Hmmm!
[01:29:44] <ShadwChsr> NUVIE = New VI Engine
[01:29:51] <ShadwChsr> in case you didnt know :)
[02:40:47] --> Colourless has joined #Exult
[02:40:47] --- ChanServ gives channel operator status to Colourless
[03:34:52] <ShadwChsr> hi
[04:29:18] --> Baastuul_ has joined #exult
[04:33:35] <-- Matt_O has left IRC ("Leaving")
[04:40:08] --> SB-X has joined #exult
[04:46:49] <-- Baastuul has left IRC (Read error: 110 (Connection timed out))
[04:54:29] --> g2112 has joined #exult
[04:56:25] <-- g2112 has left #exult ()
[05:16:03] <SB-X> hi
[05:29:42] <SB-X> ShadwChsr: U6 uses tiles for all its sprite effects. Some tiles are cached in memory and some are loaded from disk when needed.
[05:30:13] <ShadwChsr> Are the tiles stored the "old school" way, as a single large image with some sort of offsets?
[05:30:19] <ShadwChsr> or are they stored independently?
[05:30:45] <SB-X> They are packaged together in one file, although not as a singular image.
[05:30:56] <ShadwChsr> Ahhh
[05:31:13] <SB-X> another file has offsets into that file
[05:31:13] <ShadwChsr> How are animations, characters, and frames handled?
[05:31:46] <ShadwChsr> Is everything just stored as a single-frame sprite and the sprites are "swapped" by the engine to create animations or effects? Or to the shapes themselves have some sort of internal structure?
[05:32:05] <ShadwChsr> (to link similar frames together - ie/ avatar frames, etc)
[05:32:16] <SB-X> NPCs frames are all individual tiles grouped together, so you only need to iterate through a small list of tiles to animate.
[05:32:26] <SB-X> Yeah they are swapped.
[05:32:29] <ShadwChsr> Those frame #'s are hardcoded?
[05:32:52] <SB-X> No there is some method of converting actor number to tile number.
[05:32:58] <SB-X> And then you just add or subtract from that to get frame.
[05:33:10] <SB-X> the frames are in the same order for almost all actors/NPCs
[05:34:17] <SB-X> For sprite effects besides NPC animations, I assume the tile numbers are hardcoded.
[05:34:38] <ShadwChsr> *nods
[05:34:45] <ShadwChsr> What about U7, same thing?
[05:35:03] <SB-X> heh, no idea
[05:35:12] <ShadwChsr> Ahh :)
[05:35:17] <SB-X> actually actors in U7 have a shape number
[05:35:22] --- Lord_Nightmare is now known as LordNAway
[05:35:27] <ShadwChsr> *nods
[05:35:35] <ShadwChsr> I knew that much, but I wasn't sure how the shapes were organized
[05:35:39] <SB-X> which you can get by adding or subtracting, and then they also have a standard set of frames
[05:35:45] <SB-X> they are in a package too
[05:36:02] <ShadwChsr> Shape = Frame, Shape = Sequence of Frames, or Shape = 'Shape' with multiple animations underneath
[05:36:07] <SB-X> except I believe the offsets are at the start of the file
[05:36:14] <ShadwChsr> Ahhh
[05:36:54] <ShadwChsr> I want to have animations stored in my system - so you could have any # of frames
[05:37:23] <ShadwChsr> But I'm debating whether or not a shape should = an animation, or if a shape should represent something closer to the actual appearance
[05:37:42] <ShadwChsr> So you would have a shape called "Wolf" with multiple animations underneath.
[05:37:43] <ShadwChsr> :S
[05:38:03] <ShadwChsr> Problem with that is you end up with 3 levels - Shape, Animation, Frame. That makes writing a file format difficult :(
[05:38:23] <SB-X> In U7 the shape (more abstractly speaking) contains all of the frames. But it's not animation specific. The frames aren't necessarily even the same thing.
[05:38:51] <ShadwChsr> An "animation" resource could contain the frames sequenced as part of it's data, but the Shape data would need to be stored separately from the animation data.
[05:38:56] <ShadwChsr> That makes it tricky - linking the two together.
[05:40:54] <SB-X> The frames are just subimages of the shape.
[05:41:03] <SB-X> the sequencing is entirely done by the engine
[05:41:06] <ShadwChsr> *nodes
[05:41:20] <ShadwChsr> err *nods
[05:41:21] <ShadwChsr> :P
[05:41:26] <SB-X> although there is a standard for how they are grouped together for most actors, same as U6, it changes in some cases
[05:41:40] <SB-X> for multiple animations the frames in that sequence are grouped together
[05:41:56] <ShadwChsr> makes sense.
[05:42:25] <ShadwChsr> I don't really want to hard-code the frames though. Ie/ to allow 20 frames for a walk sequence for one character but 4 for another
[05:42:29] <SB-X> shape100=some actor; shape100:0-shape100-4=some actor walking; shape100:5-shape100:10=some actor attacking
[05:42:30] <ShadwChsr> a little more flexible
[05:43:08] <ShadwChsr> what happens if you set the shape to, say, a tree, where there is only one frame?
[05:43:24] <ShadwChsr> The animations cycle through the nearby shapes?
[05:43:59] <SB-X> It never tries to animate a tree. I don't know how they are stored in memory to know if it cycles to the next shape.
[05:44:12] <SB-X> if you made a tree actor that is :)
[05:44:26] <ShadwChsr> I think I tried once, and it wasnt animated (ie/ didnt cycle nearby frames). That's why I asked :)
[05:44:33] <SB-X> If you hard-code it you can allow as many frames as you want though.
[05:44:34] <ShadwChsr> The SI polymorph command ;)
[05:44:43] <SB-X> heh
[05:45:01] <SB-X> I think the best scheme is something that lets you identify animations by name, and define how you want to cycle through them at any given time.
[05:45:31] <SB-X> and where the animation names are standard for all types of objects that can use those animations
[05:45:39] <ShadwChsr> That's what I have right now - but I'm not sure if it's worth grouping those animations into another group for the actual shape.
[05:46:31] <ShadwChsr> I was thinking of an animation type enumeration (Default, Stand, Walk North, Sit, etc), with a Custom value that would allow for a custon named anim. For weird cases (sign in wind, etc)
[05:46:52] <SB-X> The animation types should be independant of the shape, but you might need a definition for each shape.
[05:47:23] <ShadwChsr> Yeah. So the best bet is to still have the 3 layers I guess. Hmmm.
[05:47:34] <SB-X> what if yo uwant more than one custom?
[05:47:38] <SB-X> you want*
[05:47:56] <SB-X> maybe you could forego the independant animation type/enumeration
[05:47:58] <ShadwChsr> You have more than one flagged as custom but with a different custom key (name)
[05:48:04] <SB-X> and just go with shape definitions
[05:48:10] <ShadwChsr> Shape definitions?
[05:48:33] <SB-X> each shape has a file with names of it's animations, and what frames they contain
[05:48:45] <SB-X> although you have to be careful to keep names the same for all shapes
[05:52:02] <-- LordNAway has left IRC (sterling.freenode.net irc.freenode.net)
[05:52:03] <-- SB-X has left IRC (sterling.freenode.net irc.freenode.net)
[05:52:03] <-- ShadwChsr has left IRC (sterling.freenode.net irc.freenode.net)
[05:52:03] <-- Darke2 has left IRC (sterling.freenode.net irc.freenode.net)
[05:52:03] <-- wjp has left IRC (sterling.freenode.net irc.freenode.net)
[05:52:03] <-- Colourless has left IRC (sterling.freenode.net irc.freenode.net)
[05:52:03] <-- Sevalecan has left IRC (sterling.freenode.net irc.freenode.net)
[05:52:03] <-- shazza` has left IRC (sterling.freenode.net irc.freenode.net)
[05:52:03] <-- servus has left IRC (sterling.freenode.net irc.freenode.net)
[05:52:03] <-- Kirben has left IRC (sterling.freenode.net irc.freenode.net)
[05:52:37] --> Colourless has joined #exult
[05:52:37] --> SB-X has joined #exult
[05:52:37] --> ShadwChsr has joined #exult
[05:52:37] --> Kirben has joined #exult
[05:52:37] --> Sevalecan has joined #exult
[05:52:37] --> shazza` has joined #exult
[05:52:37] --> Darke2 has joined #exult
[05:52:37] --> wjp has joined #exult
[05:52:37] --> servus has joined #exult
[05:52:37] --> LordNAway has joined #exult
[05:53:10] <ShadwChsr> The index can be buffered with blank records so that every new resource doesn't require it to be moved (and require the file to be 'compacted')
[05:53:31] <ShadwChsr> Each resource class is marked with IResource which inherits from IResourceListing
[05:54:02] <SB-X> Ok, so it's just a little more flexible than U7's packages.
[05:54:05] <ShadwChsr> IResourceListing is used to define just enough info for listing resources. Ie/ if I wanted a list of shapes in the map editor, but not actually load the shapes (would consume too much mem)
[05:54:25] <ShadwChsr> IResource inherits from IResourceListing and defines two methods - one for Serialization and one for Deserialization.
[05:54:35] <ShadwChsr> They are responsible for writing or reading the binary data.
[05:54:39] <SB-X> yeah
[05:55:02] <ShadwChsr> They can be marked virtual to allow descendent types to add additional fields or completely rewrire the data structures.
[05:55:32] <ShadwChsr> Even maps are stored that way - I have a single resource for the terrain (ground tiles) and multiple resources for the statics
[05:55:59] --> Matt_O has joined #exult
[05:56:14] <ShadwChsr> I'm not sure if it was a good idea, but I created a "ItemEntityTemplate" class.
[05:57:01] <ShadwChsr> the entity template classes define the base design of an entity - you would have a "Wolf" SentientEntityTemplate or a "Tree" ItemEntityTemplate.
[05:57:23] <SB-X> I don't have much experience with using templates.
[05:57:30] <ShadwChsr> You then would call .Spawn() from the template to create a new entity in the game world. The entity references back to the template so only one dataset needs to be created
[05:57:39] <ShadwChsr> Well its not an actual C++ template
[05:57:46] <SB-X> oh
[05:58:02] <SB-X> It's like a class then.
[05:58:08] <ShadwChsr> Yeah it is a class.
[05:58:11] <ShadwChsr> It's just a type of entity.
[05:58:24] <SB-X> anyway considering how you store things now, you'd just put all shapes for an object and the shape defintion in one file, each as its own resource
[05:58:51] <ShadwChsr> Well, that's the key factor.
[05:58:53] --- Baastuul_ is now known as Baastuul
[05:58:57] <SB-X> I wasn't really concerned with how you'd store the data but I think that makes sense.
[05:59:01] <ShadwChsr> I've decoupled Shapes from Entity Templates
[05:59:14] <ShadwChsr> an Entity Template would be something like "Pine Tree".
[05:59:27] <SB-X> Baastuul: stay out of our channel!!!
[05:59:31] <ShadwChsr> It would define it's behavior, usecode, etc.
[05:59:53] <SB-X> what's a shape then?
[05:59:55] <ShadwChsr> The Shape would be the actual graphic representation. The Entity Template would have a "Shape Id" property.
[06:00:03] <SB-X> in U7 a shape+frames is synonymous with object
[06:00:05] * Baastuul strangles SB-X in a fit of homicidal rage!
[06:00:16] <SB-X> Baastuul: I don't feel very strangled.
[06:00:26] <Baastuul> k sry 2 displz u
[06:00:40] <SB-X> hehe I'm jk I have no say what goes on in that channel
[06:01:06] <ShadwChsr> Not in this case. I split the two because I thought it would be interesting two have two different object types (and code) sharing the same animations/graphics
[06:01:31] <ShadwChsr> You could have NiceWolfEntity and SatanicWolfEntity, both using the Wolf Sprite ;)
[06:01:57] <SB-X> but wouldnt they inherit from WolfEntity anyway?
[06:02:02] <SB-X> but I get what you mean
[06:02:19] <SB-X> your way is cleaner
[06:02:27] <ShadwChsr> No because the entity object hierarchy wouldn't go as deep.
[06:02:49] <SB-X> in U7 it's accomplished by the fact that everything that's animated has the same basic sequence
[06:02:52] <SB-X> ah
[06:03:00] <ShadwChsr> Entity->ShapedEntity->ItemEntity or Entity->ShapedEntity->SentientEntity->PlayerEntity
[06:03:08] <ShadwChsr> anything other than that is defined using usecode/script
[06:03:14] <ShadwChsr> and placed into a template.
[06:03:27] <ShadwChsr> the template then spawns the actual entities.
[06:03:33] <SB-X> well, if Animation is a behavior that ItemEntity controls, then the anim definition should be part of the template
[06:03:51] <ShadwChsr> Well, thats the problem.
[06:04:10] <SB-X> you have to hardcode the frame resources :)
[06:04:14] <SB-X> associations
[06:04:21] <ShadwChsr> Do I have the entity link to multiple animations and swap between them using it's usecode, or do I just link the Shape and have the shape contain the animations?
[06:04:26] <SB-X> well not hardcode but put them in the definition
[06:04:57] <ShadwChsr> I could have Entity (link to) Shape (link to) ShapeAnimation (contains frames in shape animation data)
[06:04:59] <ShadwChsr> or
[06:05:07] <ShadwChsr> Entity (link to multiple) ShapeAnimation (contains frames in shape animation data)
[06:05:30] <ShadwChsr> The first method makes it really easy to structure and "consume" animations.
[06:06:01] <ShadwChsr> But it makes it a bitch to store the actual data, because I need to link the ShapeAnimation resources back to their parent shape. And write all the UI for that.
[06:06:15] <SB-X> Why do you have to link shapeanimation back to shape?
[06:06:25] <ShadwChsr> Because a shape would contain multiple animations.
[06:06:39] <SB-X> But only the shape needs to know where its animations are.
[06:08:49] <ShadwChsr> Well, it's probably easier putting a single ShapeId on the animation than a list of ShapeAnimations on the Shape.
[06:08:49] <ShadwChsr> But harder to load ;)
[06:08:49] <ShadwChsr> The other option is to just get rid of the Shape and only store animations.
[06:08:49] <ShadwChsr> But it might make it a pain to keep track of them all
[06:08:49] <SB-X> You probably don't want to do that...
[06:08:49] <ShadwChsr> Yeah.
[06:08:49] <SB-X> it would be better to make the frames entirely independant
[06:08:50] <SB-X> they aren't necessarily even an animation
[06:08:50] <ShadwChsr> Well the frames aren't independent, they are part of the animation
[06:08:50] <SB-X> then the shape is independant
[06:08:50] * ShadwChsr nods
[06:09:08] <ShadwChsr> Thats what I would like, idealy. Storing the structure and writing the UI is the nasty part though, and I haven't fully figured out how I'm going to do it
[06:10:06] <ShadwChsr> I guess I could have the Shape class contain a ShapeAnimationCollection class, accessible through the .Animations property.
[06:10:16] <SB-X> Don't do anything special for frames since they dependant on shape anyway.
[06:11:00] <ShadwChsr> The resource serialization for the shape class would first save/update the animations then write out a list of animation GUIDs to the shape.
[06:11:21] <ShadwChsr> or something like that :P :)
[06:11:33] <SB-X> Why need GUIDs?
[06:11:48] <SB-X> just don't differentiate "shape" from the "collection of frames" in a resource file
[06:12:11] <ShadwChsr> well, that would have a single resource for "Shape".
[06:12:18] <SB-X> yeah
[06:12:28] <SB-X> just stuff the frames together under one resource
[06:12:31] <ShadwChsr> Adding an animation would require the entire shape and all of it's other animations to be resaved
[06:12:50] <ShadwChsr> I was thinking of having two resources, one for the shape and one for the shapeanimation (which contains the frames)
[06:12:50] <SB-X> No you'd depend on the known sequence, and just add to the definition.
[06:13:06] <SB-X> That's unnecessary though.
[06:13:26] <ShadwChsr> So you would just stuff all the frames, and animations, into one shape?
[06:13:45] <ShadwChsr> so you would have something like..
[06:13:47] <SB-X> no
[06:13:53] <ShadwChsr> err sorry :)
[06:13:54] <SB-X> The animations are the definition.
[06:14:02] <SB-X> They are stored with the template.
[06:14:21] <SB-X> The frames themselves are stored in a known sequence but they themselves don't really make an animation, they're just data.
[06:14:44] <ShadwChsr> So internally you would have something like:
[06:14:46] <ShadwChsr> Animation1Frame1
[06:14:48] <ShadwChsr> Animation1Frame2
[06:14:50] <ShadwChsr> Animation2Frame1
[06:14:52] <ShadwChsr> Animation2Frame2
[06:15:13] <ShadwChsr> all stuffed together, and some other properties used to index them? ie/ Animation Start Frame, Animation Length?
[06:16:11] <SB-X> that would be with the template, although you don't really need any index properties beyond that, do you?
[06:16:22] <SB-X> Animation1Frame1 is the Start frame, unless you override that when playing it
[06:16:35] <ShadwChsr> what if I have another animation?
[06:16:41] <SB-X> isn't that Animation2
[06:17:35] <ShadwChsr> Well, maybe i'm confused :)
[06:17:56] <SB-X> It's your example. I'm the one that's confused! ;)
[06:18:11] <ShadwChsr> think of each "resource" as having a Unique ID and a stream of binary data. That's it.
[06:18:15] <SB-X> yep
[06:18:16] <ShadwChsr> And a type :)
[06:18:32] <SB-X> although the "shape" type is a collection of frames
[06:18:41] <ShadwChsr> well, that's the question :)
[06:18:55] <-- servus has left IRC (Read error: 110 (Connection timed out))
[06:18:58] <SB-X> just don't think of them as an animation
[06:19:05] <SB-X> it's just a group of images
[06:19:18] <SB-X> which you can access by RsrcID:index
[06:19:21] <ShadwChsr> group of common images, like, Avatar. Or Iolo, or Tree, or Wolf.
[06:19:27] <SB-X> whatever you wanted
[06:19:53] * ShadwChsr nods. I never really thought of it that way until now.
[06:20:00] --> servus has joined #exult
[06:20:11] <SB-X> I thought the animation list you were giving was how they'd be stored in the definition file
[06:20:25] <ShadwChsr> what's the definition file?
[06:20:35] <SB-X> the animation, sans image data
[06:20:43] <ShadwChsr> ahh. That's stored with the image data :)
[06:20:49] <ShadwChsr> just at the top
[06:20:59] <SB-X> I thought that was the question.
[06:21:19] <SB-X> if you store it with the entity you can have multiple animations use the same images
[06:21:32] <SB-X> entity/template*
[06:21:56] <ShadwChsr> Hmmm.
[06:22:15] <ShadwChsr> I always thought of it being a "tree", with the Shape containing the Animations, and the Animations containing the Frames.
[06:22:25] <ShadwChsr> The animation would have it's own properties, for things like timing.
[06:23:02] <SB-X> If you had various timing it would be set as some property in the definition like you alluded to earlier. I wasn't thinking of that.
[06:23:30] <SB-X> I thought you wanted a more flexible association than the tree though.
[06:23:55] <ShadwChsr> Well, the flexible association is between the template and the shape.
[06:24:19] <ShadwChsr> Think of the shape like a 3D Mesh, only 2D. The template is just the code describing an in game object. That code would say, use "X" shape.
[06:24:30] <ShadwChsr> ie/ current shape
[06:24:53] <-- Darke2 has left IRC (Read error: 110 (Connection timed out))
[06:25:01] <ShadwChsr> when the player walks, it would enumerate the shape's list of animations for the matching one and "play" it.
[06:25:09] <SB-X> Yeah that's how I was thinking of it, except without any animations defined. :)
[06:25:17] * ShadwChsr nods.
[06:25:20] <SB-X> yeah it's the same thing, the only difference is how you're storing it
[06:25:32] <ShadwChsr> Yeah
[06:25:46] <ShadwChsr> Deciding how to store it is the tricky part :)
[06:26:11] <ShadwChsr> Storing the frames, animations, shape all in one resource means it's a nice neat package and easy to load, and you can't have broken links.
[06:26:24] <SB-X> I'd put the animation in the template because that is a behavior. (the object doesnt just "walk" it does "display frame1" "display frame2" "display frame3")
[06:26:35] <SB-X> yeah that's a good positive
[06:27:10] <ShadwChsr> the downside is adding an animation or frame requires the whole thing to be resaved, and very likely, moved to the end of the file (since the size would grow). That would require more frequent compaction.
[06:27:17] <SB-X> I'd just do whatever is easier to code, which was the second method you listed above.
[06:27:30] <SB-X> adding a frame would always require it to be resaved
[06:27:56] <ShadwChsr> right, but if I decouple the animations from the shape, and have the animations have an ID pointer back to the shape, that wouldn't be a problem.
[06:28:07] <ShadwChsr> Adding a frame would only resave the animation, not all of the other animations for the shape.
[06:28:24] <ShadwChsr> With something like a player shape, with over a dozen animations, that could be significant.
[06:28:58] <SB-X> hmm, you could just add another layer and identify the frames by name instead of index
[06:29:13] <ShadwChsr> Option C is to say hell with the shape and just store animations. Like you said, the behavior would call "run animation AvatarNE" "run animation AvatarNW"
[06:29:19] <ShadwChsr> the animations wouldnt be grouped together at all.
[06:29:31] <SB-X> well they could be but depends on how you saved them
[06:29:35] <SB-X> they wouldnt have to be though
[06:30:44] <ShadwChsr> Shape.Animations["Walk"]
[06:30:46] <ShadwChsr> *shrug*
[06:31:14] <ShadwChsr> Instead of Animations["AvatarWalk"]
[06:31:35] <SB-X> I thought it was assumed that we wanted standard animations.
[06:31:52] <SB-X> Walk instead of AvatarWalk
[06:31:54] <ShadwChsr> Yeah, pretty much.
[06:32:04] <ShadwChsr> Unless it was too ugly doing it the other way.
[06:32:45] <SB-X> what was the problem with putting the animation list at the start of the resource file?
[06:33:02] <SB-X> oh, the whole thing being resaved
[06:33:17] <ShadwChsr> you mean at the start of the resource, not the resource file, right?
[06:33:45] <SB-X> oops
[06:33:54] <SB-X> yeah it makes more sense start of each resource
[06:34:10] <ShadwChsr> Even if my classes are structured like "Shape.Animations["Walk"].Frame[0]", I could serialize the data like this:
[06:34:21] <ShadwChsr> (shape data - bounding box, name, yadda yadda)
[06:34:27] <ShadwChsr> (# of animations)
[06:34:52] <ShadwChsr> (index of animations, with Name/LookupKey, Frame Start #, and # of frames)
[06:34:58] <ShadwChsr> (frames)
[06:35:01] <ShadwChsr> right?
[06:35:22] <SB-X> yeah
[06:35:31] <ShadwChsr> that would all be hidden in the UI, it would still be stored object level into separate classes and the user would never ever see "frame start #".
[06:35:38] <SB-X> although you don't need the .Frame[0] in your call
[06:35:46] <ShadwChsr> the frame offset/start#'s would be generated by the serializer/resource save code.
[06:35:52] * ShadwChsr nods
[06:36:18] <SB-X> but you can still add a seperate anim definition to templates
[06:36:19] <ShadwChsr> You know, that solution is definately a lot better than the other one.
[06:36:35] <ShadwChsr> I never thought about storing an index of animations with frame offsets right in the shape resource data stream.
[06:36:43] <SB-X> I'm not even sure what the original one was. :p I thought that was it.
[06:36:52] <SB-X> why not?
[06:36:57] <ShadwChsr> Nah, the original was two resource types, Shape and ShapeAnimation.
[06:37:05] <ShadwChsr> stored separately with a loose "ID" link between them.
[06:37:17] <ShadwChsr> But deleting one or the other causes problems and it's more difficult to program :)
[06:38:06] <SB-X> deleting a data file usually will cause problems
[06:38:13] <ShadwChsr> :)
[06:38:29] <SB-X> Don't require the animation list though.
[06:38:36] <ShadwChsr> I never thought of storing it all together because of the table/index of animations - it would be stored in the resource data.
[06:38:42] <ShadwChsr> What do you mean?
[06:38:53] <SB-X> the shape should still be generic enough to allow for any loose set of images to be collected
[06:39:03] <SB-X> if you wanted
[06:39:16] <ShadwChsr> Well, I was thinking it would just go into the "default" animation type.
[06:39:30] <ShadwChsr> So a tree, or ground tile would be Shape.Render(AnimationType.Default);
[06:39:31] <SB-X> as Name?
[06:39:46] <SB-X> oh
[06:39:46] <ShadwChsr> or ("") or (null);
[06:40:23] <ShadwChsr> Means I need to have a created class for the animation collection (and enumerate it), but the upside is I only need to program for one case.
[06:40:39] <ShadwChsr> I could optimize it internally by looking at if (AnimationCount == 1) or something.
[06:41:01] <SB-X> Can you still use an animation definition in the template? I still think that was a cool idea.
[06:41:20] <SB-X> because I wasnt really thinking of naming the animations in the shape, just the frames
[06:41:39] <ShadwChsr> Well, it would be a shape and animation definition together, but yeah, definately.
[06:41:57] <ShadwChsr> I havent programmed much of the entity template code, but I was thinking it would work something like this:
[06:41:59] <SB-X> (shape data - bounding box, name, yadda yadda)
[06:42:05] <SB-X> (# of frames)
[06:42:23] <SB-X> (index of frames, with Name/LookupKey)
[06:42:26] <SB-X> (frames)
[06:42:40] <ShadwChsr> An entity template has a "default" shape. It's standard form. It would be a property right on the template: StandardShapeId or something.
[06:42:43] <SB-X> heh sorry I didn't see you were about to type something :)
[06:43:07] <ShadwChsr> There would be a get/set property for "CurrentShapeId", which would be what is currently rendered to the world.
[06:43:09] <SB-X> yeah I assumed that too
[06:43:16] <SB-X> a ResourceID?
[06:43:20] <ShadwChsr> yeah.
[06:43:37] <ShadwChsr> Usecode/script could then dynamically change the current shape as required. Polymorph spells, crazy effects, whatever.
[06:43:47] <SB-X> well if you're doing that anyway, there should be no problem defining there what the animations are either
[06:43:48] <ShadwChsr> But could easily revert back to the default shape.
[06:44:04] <SB-X> add a list to the template...
[06:44:13] <ShadwChsr> Animations would be the same, you would have a CurrentAnimation.
[06:44:22] <ShadwChsr> which would be the current animation in the current shape :D
[06:44:32] <SB-X> animations { walk{ frame1, frame2, frame3, frame4 } }
[06:44:38] <ShadwChsr> Internally the template might use state machines to do the animation stuff.
[06:44:59] <ShadwChsr> well, that list would be in the shape, not the template.
[06:45:11] <SB-X> i guess
[06:45:21] <ShadwChsr> The template never contains the graphic. Template is just metadata describing an entity's behavior and appearance.
[06:45:26] <ShadwChsr> it never "defines" the appearance.
[06:45:30] <SB-X> it's not a graphic
[06:45:38] <ShadwChsr> Ahhh I see what you mean though.
[06:45:43] <SB-X> an animation is a behavior
[06:45:46] <SB-X> and frame1 is a name
[06:45:59] <ShadwChsr> Well that was one of my other thoughts. You wouldn't have shapes, just shape animations.
[06:46:15] <ShadwChsr> The template would display the animations through behaviors, just like what you described.
[06:46:28] <ShadwChsr> But maintaining the behaviors might end up being too much work. *shrug*
[06:46:39] <SB-X> this way you can make new animations out of existing framesets
[06:46:44] <SB-X> without recompiling the resource
[06:47:22] <SB-X> I was also thinking from the point of view of using the editor.
[06:47:27] <ShadwChsr> That would be cool but probably out of the scope of my project... I'd rather just add the image twice. If it means a little more storage it's worth the simplicity tradeoff.
[06:47:53] <SB-X> I don't see any more complexity here. You just take the # of animations and animation names out of the shape and put them in the template.
[06:48:51] <ShadwChsr> True, but what if you had ten templates all using the same walk animation?
[06:48:54] <ShadwChsr> You'd need to define it 10 times
[06:49:17] <ShadwChsr> *shrug*. I think I'll still store animations with the shape, but perhaps add a layer onto the template layer that allows for the extra flexibility.
[06:49:30] <SB-X> That would solve it.
[06:49:40] <SB-X> That or adding another inheritance level.
[06:49:49] <ShadwChsr> Idealy I want the editor to be "dumb" about frames. It should be easy average user to add animations without too much tech or scripting.
[06:49:52] <SB-X> Or adding a default template or definition.
[06:50:17] <ShadwChsr> Hmmmmm, template inheritance, interesting :)
[06:50:19] <SB-X> The only thing you need to write in the editor is the name of the frames. "walk1" "walk2"
[06:50:27] <ShadwChsr> scripted inheritance that is
[06:50:30] <SB-X> heh
[06:50:40] <ShadwChsr> And you know, it should be possible.
[06:50:44] <ShadwChsr> I'm using C#/.NET
[06:50:48] <SB-X> no idea about all the complexities that could have
[06:50:54] <SB-X> i just meant for animations:)
[06:50:58] <SB-X> but go ahead
[06:51:14] <ShadwChsr> Which has a command called "Emit" which dynanmically compiles script. I would leverage .NET's own inheritance!
[06:51:37] <SB-X> heh
[06:51:52] <SB-X> I havn't used .NET.
[06:51:54] <ShadwChsr> in fact, I could define the usecode is a class inherited from ItemTemplate or whatever.
[06:52:10] <ShadwChsr> write the actual functions as code, just stored in the resource file. The code would be compiled on load.
[06:52:18] <ShadwChsr> :D
[06:52:19] <SB-X> your solution of keeping the animation names in the shape will solve the problem without extra inheritance, but do also store the frame names
[06:52:42] <SB-X> at least if you store the frame names you'll be allowing for more flexibility later
[06:52:50] <SB-X> it's not any work to write names out in your editor
[06:52:50] <ShadwChsr> you mean .Frame["AvatarStanding"] .Frame["AvatarWalk1"]?
[06:52:57] <SB-X> no, just walk1
[06:52:59] <SB-X> the standard names
[06:53:02] <ShadwChsr> right, sorry.
[06:53:24] <ShadwChsr> Hmmm I'll think about that.
[06:53:50] <ShadwChsr> But I definately have a plan now, you had some great ideas I never even thought of :D
[06:54:21] <ShadwChsr> I've been waffling and moaning about the shape code for ages, just couldn't wrap my head around the best implementation.
[06:54:34] <SB-X> cool, glad to have helped somehow
[06:54:50] <SB-X> I usually just go ahead with what's easier to do and regret it later.
[06:54:58] <ShadwChsr> Definately! Thanks again for taking the time to understand my arcane setup :)
[06:55:17] <ShadwChsr> The main reason I'm writing this engine is to be expandable.
[06:55:25] <SB-X> you're welcome
[06:55:31] <SB-X> i know, sounds like it
[06:55:39] <ShadwChsr> I want to create my own worlds, so flexibility is a must. Most engines are written the other way around, and editing is an afterthought.
[06:55:56] <ShadwChsr> The downside is I end up spending most of my time mucking with stuff rather than getting something working :)
[06:55:59] <SB-X> how are you storing usecode now?
[06:56:02] <ShadwChsr> But I'm slowly making progress.
[06:56:05] <ShadwChsr> I'm not.
[06:56:20] <ShadwChsr> I haven't gotten that far, my entity code is pretty rudimentary.
[06:56:52] <ShadwChsr> Most of the renderer is operational, and I have basic entity classes so I can render a world with statics.
[06:57:05] <SB-X> I havn't worked on my engine at all. :\
[06:57:09] <SB-X> although I still want to
[06:57:29] <ShadwChsr> The mobiles and usecode haven't been written yet. Neither has any sort of interactivity, unfortunately.
[06:57:46] <SB-X> physics?
[06:57:47] <ShadwChsr> Quite a bit of it is mocked up using empty classes or functions.
[06:58:02] <ShadwChsr> Wouldn't have much physics being 2D - it's not going to be like U8.
[06:58:06] <SB-X> aww
[06:58:13] <ShadwChsr> I could always add it later :D
[06:58:21] <SB-X> do you have z coords?
[06:58:22] <ShadwChsr> More like U7 but with a renderer like U8
[06:58:25] <ShadwChsr> yes
[06:58:33] <ShadwChsr> Even for terrain.
[06:58:34] <SB-X> if you have z coords and bounding boxes that should be enough
[06:58:58] <ShadwChsr> I have z coords, render bounding boxes (boundaries), and collision boundaries.
[06:58:59] <SB-X> not sure though
[06:59:05] <SB-X> yeah collision boundaries
[06:59:27] <ShadwChsr> Whether or not I'll do things like having a goblet fall when dropped or render it throwing across a room remains to be seen :)
[06:59:48] <SB-X> u7 has some basic bounding boxes but that's mostly just so you can stack things
[06:59:52] <ShadwChsr> But the idea is to have enough data to program things like that later. I want to get something up and running, but have a core flexible enough to add cool stuff like that :)
[07:00:07] <SB-X> If you do it like U8/Crusader the goblet would just drop or slide across the screen.
[07:00:37] <SB-X> will you be able to stack things?
[07:00:42] <ShadwChsr> Hell yeah :D
[07:00:48] <SB-X> then it has to be able to fall
[07:00:55] <SB-X> if you move the table under it
[07:00:56] <ShadwChsr> Stacking, multiple floors, disappearing ceilings, all must haves.
[07:01:23] <SB-X> rpg's dont use multiple floors enough
[07:01:32] <ShadwChsr> Well, you could just drop it do the nearest collision boundary, as opposed to rendering the physics.
[07:01:40] <ShadwChsr> Yeah, I wonder why not.
[07:01:51] <ShadwChsr> I love it :D
[07:01:55] <SB-X> if they do, they are on seperate maps
[07:01:57] <SB-X> or off the map
[07:02:01] <ShadwChsr> *nods
[07:02:08] <ShadwChsr> I'm not sure why, it's not too hard to do.
[07:02:30] <SB-X> They probably don't want to hide a large part of the playfield with a giant building.
[07:02:36] <ShadwChsr> hehe
[07:02:40] <SB-X> not that you can't work around that
[07:02:48] <ShadwChsr> yeah that's more of a design issue.
[07:02:53] <SB-X> how about rotating map?
[07:02:56] <SB-X> will you have that?
[07:02:57] <ShadwChsr> No
[07:03:11] <SB-X> it would require many more frames
[07:03:18] <ShadwChsr> But i was debating hooking on a 3d renderer one day.
[07:03:23] <ShadwChsr> in pieces.
[07:03:36] <ShadwChsr> Player sprites would be rendered as 3d, but positioned over the 2d world.
[07:03:38] <SB-X> didnt you decide not to?
[07:03:44] <SB-X> we discussed this before
[07:03:47] * ShadwChsr nods.
[07:03:52] <ShadwChsr> I decided not to go 100% 3D.
[07:03:59] <ShadwChsr> but i think i can replace it in pieces.
[07:04:15] <ShadwChsr> Like simcity 4 :)
[07:04:23] <ShadwChsr> locked but 3d
[07:04:23] <SB-X> I think you complained that some free engine on SourceForce is trying to have multiple renderers like that, and that they'd be further along if they focused on one.
[07:04:33] <ShadwChsr> haha yeah :)
[07:04:41] <ShadwChsr> they even had a text one, lol.
[07:04:56] <ShadwChsr> But I was thinking more of something like UO.
[07:05:17] <ShadwChsr> They put 3d characters over their original 2d engine. The only diff is the sprites are rendered real time.
[07:05:24] <SB-X> UO3D?
[07:05:28] <ShadwChsr> yeah.
[07:05:40] <ShadwChsr> you interlace the 3d objects right in with the 2d stuff, which is pretty easy considering the 3d objects have bounding boxes too :)
[07:06:00] <ShadwChsr> Then I could slowly do things like replace wall objects and things - you could define basic wall shapes and allow users to retexture them.
[07:06:03] <SB-X> why are you locking the view?
[07:06:10] <SB-X> whether 2d or 3d
[07:06:11] <ShadwChsr> Well, because I would 3Dify it slowly.
[07:06:22] <ShadwChsr> Once i got to 100% 3d, then I could do it :)
[07:06:42] <SB-X> you still dont need actual 3d though
[07:06:48] <ShadwChsr> Lets say (haha) that this thing takes off and everyone plays it and i have microtransactions and make a killing
[07:06:52] <ShadwChsr> And i hire a 3d artist
[07:06:58] <SB-X> hehe
[07:07:08] <SB-X> your actors all have multiple sides anyway
[07:07:13] <SB-X> why not just draw objects with multiple sides?
[07:07:21] <ShadwChsr> Make all the 3d art then voila, 3d version using the same engine. Coordinate system and physics would be limited but you could do both, theoretically.
[07:07:29] <ShadwChsr> Because of $ :D
[07:07:36] <ShadwChsr> 4x the art
[07:07:52] <SB-X> yeah the 3D is actually easier
[07:07:56] <ShadwChsr> It's hard enough finding one sprite I can legally use :)
[07:08:04] <SB-X> most games that do it with 2D (U8) used 3D shapes as models anyway
[07:08:18] <ShadwChsr> Leaving the camera locked would let me add 3D models, then add 3D walls and ground.
[07:08:21] <SB-X> so you might as well go completely with 3D
[07:08:33] <ShadwChsr> Once i have those two things in place, I already have the code to 3Dify all of the other items like trees, etc.
[07:08:47] <SB-X> ok
[07:08:50] --> Darke2 has joined #exult
[07:08:59] <SB-X> how about music?
[07:09:15] <ShadwChsr> And I could have a mode that is stored in the map (or game info) that defines if it's locked into 100% 3d mode. If it is, the camera would be unlocked.
[07:09:24] <ShadwChsr> Music, haven't decided.
[07:09:34] <ShadwChsr> I can leverage DirectShow though. Mp3 support, etc.
[07:10:08] <ShadwChsr> Probably simple to begin with, but if I had an actual budget (hehe) I would have music files with layers.
[07:10:26] <ShadwChsr> Compose the music, maybe a basic low key version
[07:10:40] <SB-X> Are you saying you have individual maps?
[07:10:47] <ShadwChsr> then another version with the same length, beat structure, but different layers, for combat or whatnot. Or "danger".
[07:10:53] <SB-X> I still like mod music.
[07:10:58] <ShadwChsr> if you've ever played unreal you know what i mean.
[07:11:11] <SB-X> nope, but Deus Ex is like that
[07:11:13] <ShadwChsr> Well Direct-X has it's own "Mod"-like system. DirectMusic.
[07:11:33] <ShadwChsr> The game has individual maps, but the maps can be as large as a world.
[07:11:43] <ShadwChsr> Well beyond UO's size.
[07:12:00] <SB-X> Don't you have to store all that in memory?
[07:12:04] <ShadwChsr> No
[07:12:17] <ShadwChsr> Maps are cut into blocks, right now defined as 10x10.
[07:12:32] <SB-X> Why is the 3D flag stored with the data?
[07:12:34] <ShadwChsr> 10x10 ground tiles, that is.
[07:12:40] <SB-X> It depends on your engine capabilities.
[07:12:42] <ShadwChsr> It isn't. That was just a random thought :D
[07:12:44] <SB-X> i see
[07:12:46] <SB-X> oh :)
[07:13:05] <ShadwChsr> One thought I've had is to have a "game" file, that describes the overall game.
[07:13:12] <ShadwChsr> You could use the game engine to play multiple games.
[07:13:29] <ShadwChsr> Load up the engine, you get a menu of game worlds. Double click on one, it connects and loads that game's map and resources.
[07:13:33] <ShadwChsr> Kind of like a master rule file.
[07:14:04] <SB-X> That sounds like what I'd like for Nuvie, although it only has the three basic game types.
[07:14:06] <ShadwChsr> I want to play with two different silly hobby projects. One is your standard fantasty world, but I want an animal MMORPG thing just for kicks
[07:14:14] <ShadwChsr> Kind of like that old game "Wolf" or "Lion"
[07:14:23] <SB-X> no idea
[07:14:26] <ShadwChsr> Instead of clans you would have packs, haha.
[07:14:31] <SB-X> oh
[07:14:33] <ShadwChsr> Just a dumb idea, but you get my point.
[07:14:40] <SB-X> at first I thought you meant a simulation
[07:14:45] <ShadwChsr> sort of :)
[07:15:14] <ShadwChsr> I doubt I'll ever program it, but it could be interesting.
[07:15:19] <ShadwChsr> but probably not fun to play :D
[07:15:29] <SB-X> I'm planning that.
[07:15:32] <ShadwChsr> More of a proof of concept game.
[07:15:35] <SB-X> for my mmorpg
[07:15:44] <ShadwChsr> planning what?
[07:15:54] <SB-X> oh sorry, the nature simulation
[07:16:08] <SB-X> not where you play an animal
[07:16:18] * ShadwChsr nods
[07:17:16] <ShadwChsr> If you feel like learning C# some time, you're welcome to muck with my system.
[07:17:31] <SB-X> hehe
[07:17:32] <ShadwChsr> I have it on source forge and CVS. And Microsoft released Visual Studio for free too.
[07:17:40] <SB-X> they did?
[07:17:42] <SB-X> first I've heard of it
[07:18:44] <SB-X> I guess you're blocks sound like chunks in U7 but not sharing data.
[07:18:47] <SB-X> your*
[07:18:55] <ShadwChsr> they used to have the Visual Studio "Standard" editions
[07:19:12] <ShadwChsr> They are now called "Express" and theoretically cost $50 (or less)
[07:19:22] <ShadwChsr> They made them downloadable 100% free for the next year.
[07:19:31] <SB-X> what do I do after a year?
[07:19:35] <ShadwChsr> No catch, and you can continue using it after that year. Burn it on a disk, whatever.
[07:19:50] <ShadwChsr> it's just like you bought it, except it's electronic delivery and it's $0
[07:20:00] <SB-X> that's nice
[07:20:07] <SB-X> I've been using mingw lately.
[07:20:08] <ShadwChsr> you go to their site and download the files. Doesnt even take a logon.
[07:20:39] <ShadwChsr> I dont find the express editions very limited. They added a TON of stuff to them.
[07:20:58] <ShadwChsr> There's no class designer or direct database editing, but other than that they're basically the same.
[07:21:16] <SB-X> thanks for the information... didnt MSVC++ have a class designer?
[07:21:35] <ShadwChsr> oh and no source control (ie/ source safe). You can still use external stuff like CVS of course.
[07:21:47] <ShadwChsr> I think so, but they have a visual one now - diagramming type thing.
[07:22:07] <SB-X> http://ian-albert.com/misc/doommaps.php
[07:22:08] <ShadwChsr> If you edit your code the diagram gets updated, if you add to the diagram it creates code definitions.
[07:22:23] <SB-X> I was thinking of MFC designer.
[07:22:32] <SB-X> for widgets
[07:22:40] <ShadwChsr> Ahhh.
[07:22:50] <ShadwChsr> I just play with the .net stuff mostly.
[07:22:52] <SB-X> didn't know what class designer was'
[07:22:59] <ShadwChsr> It's new :)
[07:23:14] <ShadwChsr> VS 2005 just came out a few weeks ago.
[07:23:24] <SB-X> Have you followed Andrea B. Previtera's RPG engine? It's inspired by U7 and borrows some ideas from Exult.
[07:23:34] <ShadwChsr> never heard of it.
[07:23:55] <ShadwChsr> sounds like mine :)
[07:24:00] <SB-X> http://ashes.lalista.org/
[07:24:17] --> Khelz has joined #exult
[07:24:21] <SB-X> never seen that website before, got the link from http://aiera.timeimmortal.net/spinoffs.php
[07:24:23] <ShadwChsr> c++?
[07:24:54] <ShadwChsr> ahhh looks 3dish :D
[07:24:59] <SB-X> I think so.
[07:25:09] <SB-X> yep it is
[07:25:21] <ShadwChsr> looks sooooooo familiar hehe
[07:25:57] <ShadwChsr> Looks like he's actually using the U7 sprites.
[07:26:13] <SB-X> "pascal and assembler"
[07:26:21] <SB-X> yeah
[07:26:21] <ShadwChsr> Ahhh
[07:26:39] <ShadwChsr> I used to use Delphi for my older engine prototypes, but it's so damn buggy :(
[07:26:56] <ShadwChsr> Newer pascal is built in .NET though. I wonder if he's using that. Hmmmmmmmmmmmm code interoperability :D
[07:32:40] <ShadwChsr> but then again, Delphi .NET cant have inline assembly.
[07:35:49] <SB-X> it's closed source, but he might share it with you
[07:45:17] <ShadwChsr> Night! :D
[07:45:19] <-- ShadwChsr has left IRC ()
[07:45:39] <SB-X> oops, cya
[07:45:44] <-- SB-X has left IRC ()
[07:48:25] --> SB-X has joined #exult
[12:21:53] <-- Colourless has left IRC ("casts improved invisibility")
[12:23:19] --> shazza has joined #exult
[12:28:32] <-- shazza` has left IRC (Read error: 104 (Connection reset by peer))
[12:53:44] <Flooder> yo
[12:53:54] <SB-X> heya Flooder
[12:54:05] <Flooder> damn winter
[12:54:07] <Flooder> so cold
[13:02:06] <-- Kirben has left IRC (Read error: 110 (Connection timed out))
[13:16:07] <-- Khelz has left IRC (Read error: 54 (Connection reset by peer))
[15:53:29] <Baastuul> Talviosta!
[15:54:42] <Baastuul> REBOOT
[15:54:47] <-- Baastuul has left IRC ("Quatsch!")
[15:59:26] --> Baastuul has joined #exult
[16:04:34] <SB-X> Baastuul: what does Talviosta mean?
[16:07:37] <Baastuul> ur mom . ol ololol.
[16:07:51] <Baastuul> No, it's a movie. Hang on.
[16:08:02] <Baastuul> http://www.amazon.com/gp/product/B0000646UN/103-3813816-8871025?v=glance&n=130&s=dvd&v=glance
[16:08:44] <Flooder> never heard
[16:08:55] <Flooder> oh right
[16:09:01] <Flooder> it's Talvisota
[16:09:05] <Flooder> not talviosta
[16:09:15] <Flooder> Finnish Movie :)
[16:10:08] <Flooder> it's great :)
[16:14:23] <SB-X> :p
[16:14:30] <SB-X> what does Quatsch mean?
[16:19:18] <Baastuul> Is that in my quit message?
[16:19:40] <Baastuul> Quatsch is basically the German way of saying "rubbish" (in the sense of "nonsense," like "That's a load of a rubbish.")
[16:23:50] <SB-X> ah
[16:24:32] <Baastuul> Flooder, is Talvisota very graphic and BLOODY? :O
[16:31:19] <SB-X> it looks interesting
[17:05:11] <Flooder> Baastuul: can't remember :)
[19:16:20] --> Fingolfin has joined #exult
[19:16:20] --- ChanServ gives channel operator status to Fingolfin
[20:46:55] <-- SB-X has left IRC ("casts gate travel")
[21:16:40] --> Kirben has joined #exult
[21:16:41] --- ChanServ gives channel operator status to Kirben
[22:20:11] --- LordNAway is now known as Lord_Nightmare
[22:43:40] --> Colourless has joined #Exult
[22:43:40] --- ChanServ gives channel operator status to Colourless
[23:31:00] <-- Lord_Nightmare has left IRC (sterling.freenode.net irc.freenode.net)
[23:31:16] --> Lord_Nightmare has joined #exult
[23:36:56] <-- Fingolfin has left IRC ("42")