[Crossfire-wiki] [Crossfire DokuWiki] page changed: dev:objects

no-reply_wiki at metalforge.org no-reply_wiki at metalforge.org
Fri Feb 9 07:38:18 CST 2007


A page in your DokuWiki was added or changed. Here are the details:

Date        : 2007/02/09 07:38
User        : mhoram
Edit Summary: New generator fields and features

@@ -289,19 +289,29 @@
  <del>The fields resist_*, armour, wc and dam can be set in map files to customize monsters.  However, if that monster can be equipped with items, and actually equips some, these values will get reset back to those in the clone archetype (normal values.)  Thus, if you want to put a wizard in that does dam 50, make sure can_use_armour, and can_use_weapon are set back to 0.  Otherwise, when items are equipped, all the above fields will be reset to standard values.</del>
  
  As of 2006-12-09, this shouldn't be the case anymore: server will detect modified archetypes, and store its values in a temporary archetype structure to be able to recompute everything.
  
- ===== Generators and creature spawning (generate) (other_arch) (use_content_on_gen) =====
  
- There are 2 types of generators in crossfire since september 2003.
- both are identified as generators by setting the flag "generate" to 1. 
- For the first type (the classical one) use "other_arch" to specify 
- archetype of object to be spawned.
- The second type allow more fine tuning on what to generate. To activate
- second type, set the flag "use_content_on_gen" to 1. Then each
- time something must be generated, it will be a copy of a randomly 
- choosen item in the generator's inventory.
+ ===== Generators and Creature Spawning =====
+ Generators spawn monsters or other objects.  By default, generators are alive and visible and can be destroyed like any other monster.  
  
+ ==== Generator (generator) ====
+ If set, this object is a generator.  Monsters (like mice) can be generators.
+ 
+ ==== Use Inventory (use_content_on_gen) ====
+ If set, the generator will create objects from its inventory.  If the inventory holds more than one object, one will be randomly selected from the list each time the generator creates one.  If not set, the ''other_arch'' object will be used.
+ 
+ ==== Object to Create (other_arch) ====
+ If ''use_content_on_gen'' is not set, the generator will create copies of the object set in this field.
+ 
+ ==== Generator Radius (generator_radius) ====
+ The generator will spawn objects within this radius of itself.  (Within a square of radius*2+1 tiles centered on the generator, to be exact.)  If this is not set, the radius defaults to 1, for legacy behavior.  Setting it to zero effectively turns off the generator.
+ 
+ ==== Maximum Number of Objects  (generator_max) ====
+ If this is set, it limits the number of objects the generator will create at one time.  Only objects on the same map are counted.  If objects are destroyed or leave the map, the generator will no longer count them and will be able to replace them.
+ 
+ ==== Generator Name (generator_name) ====
+ This value is used by the generator for marking and identifying the objects it creates, so it can count them to determine whether ''generator_max'' has been met.  This field is only used when ''generator_max'' is set.  If ''generator_name'' is not set, the generator defaults to using its ''name'', or if that is not set, to ''"generator"''.  If multiple generators on the same map have the same ''generator_name'', they will claim the same monsters.  This is a feature, not a bug. :-)  It means that you could have four generators in the corners of a room, each named "four generators" and each with a ''generator_max'' of 50, and they would create up to 50 total monsters, but in different parts of the room, and possibly from different inventory lists.
  
  ===== NPC's and their life =====
  
  An NPC can have any combination of the following programs (flags):


IP-Address  : 206.71.197.56
Old Revision: http://wiki.metalforge.net/doku.php/dev:objects?rev=1167828413
New Revision: http://wiki.metalforge.net/doku.php/dev:objects

-- 
This mail was generated by DokuWiki at
http://wiki.metalforge.net/




More information about the crossfire-wiki mailing list