Documentation | GOTHIC |
Objects (Vobs) in the World | |
Author: Bert Speckels | Version: August 14th 2001 |
|
1 Objects (Vobs)1.1 What are VOBs?A Vob is a "virtual object". It has a position and orientation in space and can be visualised by an explicitly selectable "visual".The World is getting populated with Vobs. Every Vob belongs to a class, that defines the attributes and abilities of this object (e.g. "oCNPC" or "zCTrigger"). A detailed list offers the Spacer document about the Vob-Classes. Example of some Vobs:
1.2 The Vob hierarchy in the worldThe objects in the world are saved in a hierarchy. Most Vobs will "lie" as single objects in the world. But several Vobs should be inserted as a "child" of other Vobs.A good example for this is a fireplace: The main Vob is presented in form of a small heap of glowing wood, framed by stones. At this Vob we are now "attaching" a particle effect (fire) as a ChildVob. A fire usually smokes and emits light. Therefore we attach two additional Vobs as childs to the FireVob: A smoke particle effect and a light Vob. Altogether the hierarchy will then look as follows (the visual names are just fabricated now):
2 VOBs in the Spacer2.1 The Object DialogueAs a central dialogue for (almost) all operations with Vobs serves the object dialogue (also see this picture). It has three tabs:
2.2 The Object ListIn the Object list (see picture) all Vobs of the loaded World are listed. The hierarchy is preserved.Every level component (zCVobLevelCompo) is specified in the list. Every Vob of such a level component is sorted in special folders (with the name of the respective vob class). If a Vob has additional ChildVobs, so they are displayed respectively (if necessary one has to click on the plus sign). With a double click on a Vob in the Object list one jumps to the selected Vob in the main window (this function only functions correctly from Spacer-Version 1.5 onwards). Newly inserted Vobs have a green icon (circle) in front of them at first, all others have a red icon. 2.3 Special Object DialogueFor several vob classes there are special dialogues, which one can activate via the object toolbar. This are first of all the four buttons, that are marked with a red arrow in the right top corner:
3 Visible and invisible VobsAn important attribute of Vobs is their "visual". A visual regulates the display of the Vob. And there are different kinds of visuals:
3.1 The MeshIf a Vob has a Mesh (3ds) as its visual, it will be displayed as the three-dimensional object, that is described through the mesh. A mesh consists of polygons (triangles) strung together, which again are defined through Vertices (the corner points).Important! In case of meshes there is a limitation: A "normal" mesh is maximally allowed to have 2048 Verteces. One exception is the visual of a level component (zCVobLevelCompo), that does not underlie such a restriction. But level components can only be inserted at the Origin of the World and also cannot be moved or rotated. Wherefore the mesh of a level component (e.g. the tower of Xardas) must already be positioned at the correct coordinates in the 3D editor. The zSpy-Message 'Degenerated Polygon' is not tragical by the way, as these are removed automatically from the Vob meshes, but should be taken into account by the creator of the mesh: A 'degenerated Polygon' is a Polygon/Triangle, that has a surface area of 0 (for example through collinear Vertices). 3.2 Particle EffectsParticle effect Vobs are created via scripts. The respective files are to be found in the folder _work\data\scripts\system\pfx. The name of a PFX-Instance can be assigned as a visual, a ".pfx" must be appended.3.3 DECALsDECALs are two-dimensional meshes, to display two-dimensional structures. Examples for this are spider webs, curtains, paintings at the wall and more. The Meshes are automatically created and the texture, assigned as a visual, is automatically mapped upon it.3.4 Invisible VobsApart from all the clearly obvious Vobs there is also a range of invisible objects. They make an appearance through effects or events. A LightObject is not directly visible, but only becomes perceivable through the illumination of its environment. Similarly it is with sound objects. Music zones define, which background music should be played in a level area and trigger fields react upon contact with NPCs. A known example are also the Waypoints, which, connected together, form the Waynet.All these objects are visible in the Spacer, if one lets appear the so called "HelperVobs". This happens via the object toolbar: These Helpervobs for lights, sounds, waypoints and more are meshes, which are to be found in the folder _work\data\meshes\_intern and bear the name of the respective vob class (with a prefixed "invisible_"):
End. Do it well and thanks for the fish. |