Difference between revisions of "Characters"

From Wolfire Games Wiki
Jump to: navigation, search
m
(Wolf: Included note about fear parameters)
 
(51 intermediate revisions by 2 users not shown)
Line 1: Line 1:
''{{about|the engine feature|a list of characters in the Overgrowth universe|Characters (lore)}}''<br>
+
''{{about|the engine feature|a list of characters in the Overgrowth universe|Characters (lore)|character scripting|Character Scripting}}''<br>
  
 
[[Category:Modding]]
 
[[Category:Modding]]
Line 5: Line 5:
  
 
= Overview =
 
= Overview =
 +
Characters are a game entities that are controllable by a player or by AI. In the editor you place spawn points for characters, which look like boxes. When a level starts, each character will be created in its spawn point.
  
Characters are a game entities that are directly controllable by a player or by the AI.
+
Every character has a number of script parameters associated with it that can be used to change how its AI behaves, how fast it is, how big it is and other things like that. Read the [[Script_Parameters#Character|Script Prameters]] article for more information.
  
Characters have ''Rigged Objects'' attached, which support skeletal animation, rag doll animation, blends of those two, and character physics.
+
= Creating a Spawn Point =
 +
In the editor, in the top menu bar, press "Load → Character" and click one in the list, then click where you want to create the spawn point.
  
'''TODO''': More in depth description, akin to that in [[Hotspots]] and [[LevelScripts]]
+
If you press 8 while there is no player-controlled character in the level, the editor will create a Turner character spawn point on the camera and set it to player-controlled before entering play mode.
  
= Documentation =
+
You can set or unset any character as player-controlled, which is covered in the next section.
  
== Callable functions and data available inside character scripts ==
+
= Set Player-Controlled Character =
 +
To toggle wether a character is player-controlled or not, select exactly one spawn point and press cmd-shift-P. If the box is green it's player-controlled, if it's white it's AI controlled.
  
A list of functions, data, etc, is created automatically whenever you run the game, in a file on your hard drive. This lists what external code you get "for free" and can call from inside a character script.
+
If you want the level to be multiplayer you simply set more spawn points to player-controlled. Up to four spawn points can be player controlled.
  
* '''Windows''': <code>My Documents\Wolfire\Overgrowth\aschar_docs.h</code>
+
= Races =
* '''Mac''': <code>~/Library/Application Support/Overgrowth/aschar_docs.h</code>
+
Each race in Overgrowth has certain characteristics that make them different. Here you can read about some of the differences.
* '''Linux''': <code>~/.local/share/Overgrowth/aschar_docs.h</code>
 
  
This documentation will change with each version of the game, so keep checking back on this <code>aschar_docs.h</code> file to see the most up to date information.
+
== Cat ==
 +
* Has extra quiet footsteps
 +
* Can throw weapons when controlled by AI
  
There are also wiki pages which have more detailed documentation many of these functions. These pages have a danger of going out of date, but give more detailed documentation on some of the code:
+
== Dog ==
 +
* Cannot be strangled or held hostage, is shoulder thrown instead
 +
* Falls over when attacked with sword when unaware
 +
* Takes less damage to passive block from all other races (except wolf)
 +
* Can throw weapons when controlled by AI
  
* [[Character Script External Code|These functions are unique to character scripts]]
+
== Rabbit ==
* [[Common Script External Code|These functions are shared with other script types]]
+
* Jumps high and far
 +
* Hears extra well
 +
* Can do leg cannon
  
== Character instances in other scripts ==
+
== Rat ==
 +
* Takes more damage to passive block from all other races
  
Characters are exposed to other scripts as instances of the <code>MovementObject</code> class.
+
== Wolf ==
 
+
* Cannot be strangled or held hostage, is shoulder thrown instead
<code>MovementObject</code> instances are like other objects in the game. They support everything that is supported by <code>Object</code>, and also have their own special set of functions, properties, etc.
+
* Cannot use weapons
 
+
* Does tons of damage
If you have a handle to a <code>MovementObject@</code> object in angelscript, you can convert it to an <code>Object@</code> by calling <code>ReadObjectFromID(movement_object.GetID());</code>.
+
* Cannot be harmed by unarmed attacks, except from other wolves or leg cannon
 +
* Causes all other races controlled by AI except dogs to run away in terror
 +
** This is configurable in each character's parameters
 +
* Uses their KO shield as health

Latest revision as of 20:38, 12 July 2022


Overview

Characters are a game entities that are controllable by a player or by AI. In the editor you place spawn points for characters, which look like boxes. When a level starts, each character will be created in its spawn point.

Every character has a number of script parameters associated with it that can be used to change how its AI behaves, how fast it is, how big it is and other things like that. Read the Script Prameters article for more information.

Creating a Spawn Point

In the editor, in the top menu bar, press "Load → Character" and click one in the list, then click where you want to create the spawn point.

If you press 8 while there is no player-controlled character in the level, the editor will create a Turner character spawn point on the camera and set it to player-controlled before entering play mode.

You can set or unset any character as player-controlled, which is covered in the next section.

Set Player-Controlled Character

To toggle wether a character is player-controlled or not, select exactly one spawn point and press cmd-shift-P. If the box is green it's player-controlled, if it's white it's AI controlled.

If you want the level to be multiplayer you simply set more spawn points to player-controlled. Up to four spawn points can be player controlled.

Races

Each race in Overgrowth has certain characteristics that make them different. Here you can read about some of the differences.

Cat

  • Has extra quiet footsteps
  • Can throw weapons when controlled by AI

Dog

  • Cannot be strangled or held hostage, is shoulder thrown instead
  • Falls over when attacked with sword when unaware
  • Takes less damage to passive block from all other races (except wolf)
  • Can throw weapons when controlled by AI

Rabbit

  • Jumps high and far
  • Hears extra well
  • Can do leg cannon

Rat

  • Takes more damage to passive block from all other races

Wolf

  • Cannot be strangled or held hostage, is shoulder thrown instead
  • Cannot use weapons
  • Does tons of damage
  • Cannot be harmed by unarmed attacks, except from other wolves or leg cannon
  • Causes all other races controlled by AI except dogs to run away in terror
    • This is configurable in each character's parameters
  • Uses their KO shield as health