<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://datoolset.net/mw/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Axe+Murderer</id>
		<title>Dragon Age Toolset Wiki - User contributions [en]</title>
		<link rel="self" type="application/atom+xml" href="http://datoolset.net/mw/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Axe+Murderer"/>
		<link rel="alternate" type="text/html" href="http://datoolset.net/wiki/Special:Contributions/Axe_Murderer"/>
		<updated>2026-06-10T01:28:47Z</updated>
		<subtitle>User contributions</subtitle>
		<generator>MediaWiki 1.25.6</generator>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Installation_troubleshooting&amp;diff=8727</id>
		<title>Installation troubleshooting</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Installation_troubleshooting&amp;diff=8727"/>
				<updated>2009-12-12T12:53:48Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: punctuation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''NOTE: version 1.00 had a problem with installing to directories with paths longer than 58 characters, which is the default for Steam installations. 1.01 overcomes this problem, but if you wish to install 1.00 see [[Installation with Steam]] for details and a workaround.'''&lt;br /&gt;
&lt;br /&gt;
Refer to [[Known issues]] for the current list of issues that are being worked on, and their status.&lt;br /&gt;
&lt;br /&gt;
See [[Installing the toolset]] for general information and guidance about installing the Dragon Age toolset. If something goes wrong during that process this page may have useful information and advice.&lt;br /&gt;
&lt;br /&gt;
If you experience a crash, logs can be found in &amp;lt;code&amp;gt;My Documents\BioWare\Dragon Age\Toolset\logs&amp;lt;/code&amp;gt;. The log filenames will include the date on which the log file was created. Sending in a log will help greatly with bug fixing.&lt;br /&gt;
&lt;br /&gt;
== General errors ==&lt;br /&gt;
&lt;br /&gt;
If you get the &amp;quot;Dragon Age: Origins game install not found&amp;quot; error when you run the toolset installer:&lt;br /&gt;
* You must have the game installed before you can install the toolset. Please install the game first.&lt;br /&gt;
* If you have installed the game, but not yet run the configure program, you will get this message: &amp;quot;Please launch the Dragon Age: Origins Configure Utility&amp;quot;. This happens automatically the first time you attempt to run the game. After you have successfully configured and launched the game at least once, you should no longer get this error.&lt;br /&gt;
&lt;br /&gt;
If the toolset cannot find DLLs you may need to run the configuration tool after installation to tell the toolset where to find the Dragon Age build. This can happen if you uninstall the toolset and then reinstall it again in a different location.&lt;br /&gt;
&lt;br /&gt;
If you install the toolset in a non-default location, the toolset may not be made aware of where the [[Resource Builder]] has been put. This can be easily fixed by changing the &amp;quot;Resource Build Path&amp;quot; variable found in Options-&amp;gt;Environment.&lt;br /&gt;
&lt;br /&gt;
On Vista and Windows 7 systems you may get a message reading &amp;quot;Windows has blocked some of the features of this program.&amp;quot; It will indicate that the offending program is &amp;quot;Microsoft Register Server&amp;quot;, located at C:\windows\system32\regsvr32.exe. The installer makes use of this program to register the game engine's DLL for use by the toolset. You can choose to block or allow this, the installer will work either way. It is somewhat safer to leave it blocked.&lt;br /&gt;
&lt;br /&gt;
MSSQL Express 2005's installer has a limitation that prevents it from installing to a directory path that's longer than 58 characters.&amp;lt;sup&amp;gt;[http://support.microsoft.com/kb/935371]&amp;lt;/sup&amp;gt; Version 1.01 of the toolset installer has addressed this issue by installing the database to a predefined location independant of the location of the game executable.&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;[[Unable to connect to the database]]&amp;quot; ==&lt;br /&gt;
If you receive the &amp;quot;unable to connect to the database&amp;quot; error message there are many reasons why this happens, and various ways to correct it.&lt;br /&gt;
&lt;br /&gt;
A new troubleshooting page for this error has been created.  Rather than random suggestions of things to try, it has a troubleshooting flowchart to help you diagnose and fix your problem.  Please visit [[Unable to connect to the database]] for the latest help with this problem.&lt;br /&gt;
&lt;br /&gt;
== Installer hangs at the stage of &amp;quot;Execute:regsvr32.exe /s &amp;quot;C:\Dragon Age\tools\Engine.dll&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
In some instances Regsvr32.exe is failing for some unknown reason and refusing to terminate. Version 1.01 of the toolset installer has addressed this problem by no longer waiting for a return value from regsvr32, so the installer should no longer hang at this stage.&lt;br /&gt;
&lt;br /&gt;
If you encounter this problem on installing version 1.00, open the task manager and kill regsvr32.exe. The installer should continue on installing after that's done. This could mean that engine.dll won't be registered, however, so you may need to do that manually.&lt;br /&gt;
&lt;br /&gt;
To manually register the dll, go to &amp;quot;run&amp;quot; in your start menu and type in the following command:&lt;br /&gt;
&lt;br /&gt;
regsvr32 &amp;quot;C:\Program Files\Dragon Age\tools\Engine.dll&amp;quot;&lt;br /&gt;
&lt;br /&gt;
(or substitute the actual path to Engine.dll if it it's different from that). Make sure to run this as an administrator. It should pop up a &amp;quot;success!&amp;quot; message. If it fails, it should hopefully pop up an error message that will tell us how to fix it once and for all. It should be safe to re-try this command over and over, registering the dll more than once is harmless.  Some users have found that the only way to successfully register Engine.dll is to boot up in safe mode and log in as administrator before registering it.  After it is registered, you can then boot normally.&lt;br /&gt;
&lt;br /&gt;
NOTE: If you purchased the game through Steam, your Engine.dll will be located in a different folder.  Assuming that you installed the toolset in the default folder, the path will be:&lt;br /&gt;
&lt;br /&gt;
C:\Program Files\Steam\steamapps\common\dragon age origins\tools&lt;br /&gt;
&lt;br /&gt;
So the command in the Run window will be&amp;quot;&lt;br /&gt;
&lt;br /&gt;
regsvr32 &amp;quot;C:\Program Files\Steam\steamapps\common\dragon age origins\tools\Engine.dll&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Other database issues and solutions ==&lt;br /&gt;
&lt;br /&gt;
If you have never installed MSSQLServer Express, check for updates available for it through Windows Update after installing the toolset.&lt;br /&gt;
&lt;br /&gt;
If the SQL install fails with a crash it is possible that it is conflicting with MSXML6. If you have MSXML6 installed, uninstall it and try reinstalling the toolset. See [http://support.microsoft.com/kb/968749 Microsoft's support page on this issue]. If you have trouble uninstalling MSXML6, try the [http://support.microsoft.com/kb/290301 Microsoft Windows Installer Cleanup Utility].&lt;br /&gt;
&lt;br /&gt;
During the SQL Server Express installation when the installation script attempts to start the database, a message box with the &amp;quot;The SQL Server service failed to start...&amp;quot; error message and options to Retry or Cancel may pop up.&lt;br /&gt;
*Don't hit cancel. Cancel rolls back the installation, preventing the creation of the BWDATOOLSET database. You'll need to reinstall from scratch if this happens.&lt;br /&gt;
*Instead, navigate to C:\Documents and Settings\NetworkService\Application Data\Microsoft\ and right click on the Protect folder and open the Properties window. On the Security tab add NETWORK SERVICE to the list of Groups and User names and grant it Full Permissions.&lt;br /&gt;
*If you don't have a Security tab then close the Properties window and select Tools | Folder Options from Explorer's menu bar. In the Folder Options window click on the View tab, scroll to the last option and uncheck Use simple file sharing (Recommended) option. Now you should be able to do complete the previous step.&lt;br /&gt;
*Finally return to the &amp;quot;The SQL Server service failed to start...&amp;quot; error message and click on the Retry option.&lt;br /&gt;
&lt;br /&gt;
The version of MSSQL Server 2005 included with the toolset may have trouble installing on 64-bit operating systems. This can be indicated by SQL Server Error 70047 in the installer's logs. To resolve this problem, install [http://go.microsoft.com/fwlink/?LinkId=55734 Microsoft .NET Framework Version 2.0] for 64-bit architectures before installing the toolset. &amp;lt;!-- ref: http://www.microsoft.com/downloadS/details.aspx?familyid=220549B5-0B07-4448-8848-DCC397514B41&amp;amp;displaylang=en --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You may also encounter issues running migration scripts on 64 bit OSes. An alternate migration script can be found here: http://social.bioware.com/project/46/&lt;br /&gt;
&lt;br /&gt;
You may get issues with access permissions. This can be avoided by giving your username admin rights to the database. To do this:&lt;br /&gt;
# Run &amp;quot;SQL Server Surface Area Configuration&amp;quot; (should be on your start menu under Microsoft SQL Server 2005)&lt;br /&gt;
# Select the &amp;quot;Add new administrator&amp;quot; option.&lt;br /&gt;
# Add yourself as administrator.&lt;br /&gt;
&lt;br /&gt;
If you get a syntax error during installation, it could be caused by the path being too long.  Rather than moving your whole install, try this: http://support.microsoft.com/kb/935371&lt;br /&gt;
&lt;br /&gt;
See [[Manual database installation]] for instructions on how to manually set up the database for use with your toolset.&lt;br /&gt;
&lt;br /&gt;
== Windows XP SP 2 and endless reboot cycles after install ==&lt;br /&gt;
&lt;br /&gt;
The MSSQL Server Express installer bundled with the toolset has a potential issue when installed on Windows XP Service Pack 2 that can cause an endless cycle of reboots. The toolset installer will warn you not to proceed if it detects SP2 on your system. Dragon Age: Origins has Service Pack 3 as part of its minimum installation requirements, so you should try upgrading to Service Pack 3 and reinstall.&lt;br /&gt;
&lt;br /&gt;
If you're stuck in an endless reboot cycle:&lt;br /&gt;
&lt;br /&gt;
*Press ctrl+alt+del and open the task manager as soon as possible. Failing that, try booting in safe mode by holding down F8 during the boot process.&lt;br /&gt;
*Then go to the start menu and in execute type in &amp;quot;msconfig&amp;quot;&lt;br /&gt;
*In MSConfig go to services and deactivate all the SQL services.&lt;br /&gt;
*Now you can go to control panel...software and uninstall the SQL server from the last piece upward.&lt;br /&gt;
&lt;br /&gt;
Alternately, instead of booting into safe mode after holding down F8 during boot, you can choose the option &amp;quot;Last known good configuration (your most recent settings that worked)&amp;quot;. This may restore your system to a functional state and allow SQL Server to function correctly.&lt;br /&gt;
&lt;br /&gt;
Once you've uninstalled SQL Server this should prevent further reboot cycles. You can now install Windows XP Service Pack 3.&lt;br /&gt;
&lt;br /&gt;
== Externals links for troubleshooting ==&lt;br /&gt;
&lt;br /&gt;
[http://forum.canardpc.com/showthread.php?p=2675920 Canard PC forum] French only :Forum résumant la marche a faire en cas de problèmes. &lt;br /&gt;
&lt;br /&gt;
[[Category:Toolset installation]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Installing_the_toolset&amp;diff=8726</id>
		<title>Installing the toolset</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Installing_the_toolset&amp;diff=8726"/>
				<updated>2009-12-12T12:50:29Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Troubleshooting */ punctuation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The Dragon Age Toolset installer comes with several pieces of third-party software that are needed for the toolset to function. They are:&lt;br /&gt;
&lt;br /&gt;
* DirectX 9.0c&lt;br /&gt;
* Visual C Runtime Library&lt;br /&gt;
* Microsoft SQL Server Express 2005 Edition&lt;br /&gt;
* Nvidia PhysX drivers&lt;br /&gt;
&lt;br /&gt;
These components will be installed along with the toolset by the toolset's installer.&lt;br /&gt;
&lt;br /&gt;
== Location ==&lt;br /&gt;
&lt;br /&gt;
The first screen you'll get to after starting the installer and passing the title page is the install location selector. The toolset can only install the program into a specific subdirectory of the Dragon Age game directory, so you won't be able to alter the installation path; it's for informational purposes.&lt;br /&gt;
&lt;br /&gt;
'''Note:''' MSSQL Express 2005 is bundled with this toolset and is required for it to function. Unfortunately, MSSQL Express 2005's installer has a limitation that prevents it from installing to a directory path that's longer than 58 characters.&amp;lt;sup&amp;gt;[http://support.microsoft.com/kb/935371]&amp;lt;/sup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Follow the instructions on [[installation into a directory with a long path name]] for a workaround on this issue.&lt;br /&gt;
&lt;br /&gt;
== Components ==&lt;br /&gt;
&lt;br /&gt;
The next screen after location has been selected is where you can choose which components to install. There are only two selectable components here; Core Resources (the toolset itself) and Microsoft SQL Server Express. To run the toolkit you'll obviously need to install the Core Resources option. SQL Server is presented as a separate option so that if you already have a database server installed on your system you can use that instead of installing a whole new one.&lt;br /&gt;
&lt;br /&gt;
If you don't have an SQL server installed, or if you don't know whether you have one installed, it's safe to go with the default and install SQL Server Express. SQLServer's installer will check the existing components and, finding that all required components are already in place, won't do anything after you click &amp;quot;finish.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Manual database selection ==&lt;br /&gt;
&lt;br /&gt;
If you choose not to install SQL Server Express, the installer will ask for a database server and database name to install the toolset's resource database to instead. The default server is &amp;lt;code&amp;gt;.\BWDATOOLSET&amp;lt;/code&amp;gt; and the default database name is &amp;lt;code&amp;gt;bw_dragonage_content&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
Once you have selected these options the Dragon Age toolset will begin the installation process. This can take a while. When the install process is finished you'll be given the option to read a readme.txt file.&lt;br /&gt;
&lt;br /&gt;
The toolset will create a start menu folder named &amp;quot;Dragon Age&amp;quot;. The start menu folder will include a link to start the toolset, a link to the toolset's uninstaller, and a link to the toolset's external configuration utility.&lt;br /&gt;
&lt;br /&gt;
The installer will write a log file in your My Documents folder. If installation fails this log file will be helpful for debugging purposes.&lt;br /&gt;
&lt;br /&gt;
If you are installing over a previous version of the toolset, you may need to update the format of your old database to make it compatible with the new version of the toolset. See [[database migration]] for details.&lt;br /&gt;
&lt;br /&gt;
=== Lightmapper ===&lt;br /&gt;
&lt;br /&gt;
The [[lightmap|lightmapper]] is the tool used to calculate lighting in level layouts. You only need to use it if you're going to be creating or modifying level layouts. The lightmapper included with the toolset requires Python to run but Python isn't currently bundled with the toolset, so if you don't already have it installed you'll need to do the following:&lt;br /&gt;
&lt;br /&gt;
# Install [http://www.python.org/ftp/python/2.5.4/python-2.5.4.msi Python 2.5.4 ]&lt;br /&gt;
# Install the [http://sourceforge.net/projects/pywin32/files/pywin32/Build%20214/pywin32-214.win32-py2.5.exe/download win32 extensions] for Python 2.5 &amp;lt;BR&amp;gt; '''OR'''&lt;br /&gt;
# Install [http://downloads.activestate.com/ActivePython/windows/2.5/ActivePython-2.5.4.4-win32-x86.msi ActiveState Python 2.5.4.4]&lt;br /&gt;
&lt;br /&gt;
The easiest way to do this is to download and install ActiveState python which comes with the needed extensions.  Just click through the defaults on the installer and you will be ready to go.  If you want to use python.org installer, maker sure to install it first, then install the win32 extensions.&lt;br /&gt;
&lt;br /&gt;
* If you don't have Python installed and try to run the lightmapper, you'll receive a standard Windows error message indicating that &amp;quot;EclipseRay.exe has stopped working.&lt;br /&gt;
&lt;br /&gt;
* Note for 64 bit machines: There appears to be a bug with the 64-bit version of ActiveState Python 2.5 for Windows that prevents the lightmapper from functioning. Install the 32-bit version instead, it works.  The 32-bit version is the one linked above.&lt;br /&gt;
&lt;br /&gt;
* Do not install both ActivePython and Python.org.  This will most likely cause you to get an Error Code 1 when rendering lightmaps.&lt;br /&gt;
&lt;br /&gt;
* If you get an error code of -1073741819 this means you either have the 64 bit version or you have a version higher than 2.5.  Uninstall and use the installers from the links above.&lt;br /&gt;
&lt;br /&gt;
== Configuration ==&lt;br /&gt;
&lt;br /&gt;
The external configuration utility [[ConfigureToolset.exe]] (found in the Dragon Age\tools directory) is used to configure the toolset's database connection and to tell the toolset where the game's executable is. You shouldn't need to run the configuration utility during routine usage of the toolset, and if the defaults set up by your installer work you may not need to run it at all.&lt;br /&gt;
&lt;br /&gt;
The default database string is &amp;quot;&amp;lt;code&amp;gt;Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=bw_dragonage_content;Data Source=.\SQLEXPRESS&amp;lt;/code&amp;gt;&amp;quot;. For advanced configuration, click on the ellipsis button ([[Image:ellipsis.png]]) to open the data link properties window.&lt;br /&gt;
&lt;br /&gt;
== Uninstallation ==&lt;br /&gt;
&lt;br /&gt;
An uninstaller shortcut is available from the same start menu folder as the toolset itself. It will autodetect the location you installed the toolset in, display it to you to confirm that this is correct, and then after you click &amp;quot;next&amp;quot; it will ask which components to uninstall.&lt;br /&gt;
&lt;br /&gt;
* Core Resources - uninstalled by default, this is the toolset itself.&lt;br /&gt;
* Database - Since the uninstaller can't automatically determine if you're using SQLServer Express purposes other than just the Dragon Age toolset, SQLServer is ''not'' uninstalled automatically by default. To have the uninstaller remove the database server as well, unselect this checkbox.&lt;br /&gt;
&lt;br /&gt;
The uninstaller is generated on installation and therefore isn't signed. This may cause Vista to complain under some circumstances but shouldn't affect the uninstaller's functioning. &lt;br /&gt;
&lt;br /&gt;
== Troubleshooting ==&lt;br /&gt;
&lt;br /&gt;
See [[installation troubleshooting]] for a list of common problems that can occur during installation and how to correct or work around them.&lt;br /&gt;
&lt;br /&gt;
Note that there is currently an issue with installing the toolset for games that have been installed via Steam. See [[Installation with Steam]] for specific instructions on how to resolve this issue. If you have installed your game in a directory with a path name longer than 58 characters you may also encounter this same issue.&lt;br /&gt;
&lt;br /&gt;
If you experience a crash, logs can be found in &amp;lt;code&amp;gt;My Documents\BioWare\Dragon Age\Toolset\logs&amp;lt;/code&amp;gt;. The log filenames will include the date on which the log file was created. Sending in a log will help greatly with bug fixing.&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
Documentation is currently provided via the wiki at:&lt;br /&gt;
&lt;br /&gt;
http://social.bioware.com/wiki/datoolset/&lt;br /&gt;
&lt;br /&gt;
[[Category:Toolset installation]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=EVENT_TYPE_CRAFT_ITEM&amp;diff=8428</id>
		<title>EVENT TYPE CRAFT ITEM</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=EVENT_TYPE_CRAFT_ITEM&amp;diff=8428"/>
				<updated>2009-11-29T19:52:06Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: missing the link brackets&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{needs review}}&lt;br /&gt;
{{event&lt;br /&gt;
|sourcefile=script.ldf&lt;br /&gt;
|when=&lt;br /&gt;
|from=[[engine]]&lt;br /&gt;
|to=[[module]]&lt;br /&gt;
|object0name=oCrafter&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Event types|CRAFT_ITEM]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Ambient_behaviour&amp;diff=8350</id>
		<title>Ambient behaviour</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Ambient_behaviour&amp;diff=8350"/>
				<updated>2009-11-27T16:52:02Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Local Variables (var_creature) */ Incorrect information, someone verify my assumption that PATROL == palindrome order is proper&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Ambient behaviour begins when the player moves within 50m of a creature and ceases when the player remains more than 50m away for at least 40s. Ambient behaviour alternates between a movement phase and an animation phase, simulating a bubble of activity around the player. In a movement phase, the creature (optionally) moves to a new destination (typically a [[waypoint]] but it could be any object) and turns to face the same direction as the destination object. In an animation phase, the creature (optionally) performs one or more animations either in sequence or at random. Exact behaviour is controlled by local variables set on either the creature instance or template (see table below). All other local variables with the prefix AMBIENT_* are used internally by the ambient behaviour system (see script [[sys_ambient_h]].nss) and should not be manually modified. Never directly modify AMBIENT_* local variables at run time using [[SetLocalInt]] - always use the functions [[Ambient_Start]], [[Ambient_Stop]], [[Ambient_OverrideBehaviour]], and [[Ambient_RestoreBehaviour]] instead. Ambient behaviour is persisted when a game is saved and automatically resumes when a game is loaded. &lt;br /&gt;
&lt;br /&gt;
== Local Variables (var_creature) ==&lt;br /&gt;
&lt;br /&gt;
{{Variable table start}}&lt;br /&gt;
{{Variable table row|AMBIENT_SYSTEM_STATE| int| 0| Bitmask controlling ambient system operation. (ergo, values below are in hexadecimal).&lt;br /&gt;
* 0x01 (AMBIENT_SYSTEM_ENABLED): Ambient behaviour enabled. For non-looping animations this is the only bit that need be set.&lt;br /&gt;
* 0x02 (AMBIENT_SYSTEM_SPAWNSTART: Begin ambient behaviour immediately after spawning. Generally, only infinitely looping animations require this.&lt;br /&gt;
* 0x04 (AMBIENT_SYSTEM_NOPLAYNEXT): Sets '''bPlayNext''' parameter to [[CommandPlayAnimation]] to false. Only infinitely looping animations require this.&lt;br /&gt;
* 0x08 (AMBIENT_SYSTEM_NOBLEND): Sets '''bBlendIn''' parameter to [[CommandPlayAnimation]] to false. Set this to force a creature to resume an infinitely looping animation after a conversation.&lt;br /&gt;
* 0x10 (AMBIENT_SYSTEM_ALWAYSON): Ambient behaviour never stops, regardless of distance to player. This should rarely, if ever, be used but at least the functionality exists if needed.}}&lt;br /&gt;
{{Variable table row|AMBIENT_MOVE_PATTERN| int | 0 | Dictates how the creature moves. Add 100 to the values below make creature run instead of walk.&lt;br /&gt;
*  0 (AMBIENT_MOVE_NONE): No ambient movement &lt;br /&gt;
*  1 (AMBIENT_MOVE_PATROL): Patrol waypoints (1, 2, 3, 2, 1, ...) &lt;br /&gt;
*  2 (AMBIENT_MOVE_LOOP): Loop through waypoints (1, 2, 3, 1, 2, 3, ...) &lt;br /&gt;
*  3 (AMBIENT_MOVE_WARP): Jump creature from the last waypoint to the first (1, 2, 3, jump to 1, 2, 3, ...) &lt;br /&gt;
*  4 (AMBIENT_MOVE_RANDOM): Move to a random waypoint other than the one the creature is currently at &lt;br /&gt;
*  5 (AMBIENT_MOVE_WANDER): Move to random location within 10m of home location &lt;br /&gt;
*  6 (AMBIENT_MOVE_WANDER_FAR): Move to random location within 30m of home location &lt;br /&gt;
*  7 (AMBIENT_MOVE_PATH_PATROL): Patrol all waypoints using [[CommandMoveToMultiLocations]] (1,2,3,2,1,...) &lt;br /&gt;
*  8 (AMBIENT_MOVE_PATH_LOOP): Loop through all waypoints using [[CommandMoveToMultiLocations]] (1,2,3. 1,2,3)&lt;br /&gt;
*  9 (AMBIENT_MOVE_ONCE): Walk through the waypoint set once (1-2-3)}}&lt;br /&gt;
{{Variable table row|AMBIENT_MOVE_PREFIX| string | ap_&amp;lt;tag&amp;gt;| The prefix used to determine the waypoints the creature can travel to. Note that ''&amp;lt;tag&amp;gt;'' is a placeholder filled in at run-time with the tag of the creature. Hence, for example, if AMBIENT_MOVE_PREFIX is ''ap_&amp;lt;tag&amp;gt;'' and the creature's tag is ''cr_dog'' then the system will look for waypoints with tags ''ap_cr_dog_01'', ''ap_cr_dog_02'', ''etc''. If no waypoint is found with the ''_01'' extension, the system will search instead for all waypoints with tags matching the AMBIENT_MOVE_PREFIX value exactly (i.e. ''ap_cr_dog''). This is useful in cases where you just want to add N waypoints all with the same tag.}}&lt;br /&gt;
{{Variable table row| AMBIENT_ANIM_PATTERN| int | 0 | Index into [[ambient_ai.xls]]. Specifies the list of possible actions the creature can/will perform during an animation phase.&lt;br /&gt;
*  0: No ambient animation pattern (ergo, no ambient animations).}}&lt;br /&gt;
{{Variable table row| AMBIENT_ANIM_FREQ| float | -1.0  | Animation frequency. The part left of the decimal specifies the minimum and the part right of the decimal specifies the maximum number of random animations to play during an animation phase. So, for example, a value of 1.3 will play between 1 and 3 random animations from the animation pattern listed in ambient_ai.xls. A value of -1.0 plays all animations in the animation pattern in the order they are listed in ambient_ai.xls. Animation pattens that are highlighted in green on the worksheeet should always be played in order (i.e. AMBIENT_ANIM_FREQ is -1.0).}}&lt;br /&gt;
{{Variable table row| AMBIENT_COMMAND | int | 0 |If non-zero, this value forces the creature to perform a specific command (instead of moving and animating).&lt;br /&gt;
*  0: Use standard ambient ambient behaviour system to perform movement and animations. &lt;br /&gt;
*  1: Forces creature to attack the nearest object with tag ''&amp;lt;tag&amp;gt;_target''. There's an interval of 1-5 seconds between attack commands. &lt;br /&gt;
*  2: Forces creature to attack the nearest object with tag ''&amp;lt;tag&amp;gt;_target''. There's an interval of 0-0.5 seconds between attack commands.}}&lt;br /&gt;
{{Variable table row|AMBIENT_ANIM_PATTERN_OVERRIDE| int| 0| Overrides AMBIENT_ANIM_PATTERN if non-zero.}}&lt;br /&gt;
{{Variable table row|AMBIENT_ANIM_FREQ_OVERRIDE| int| 0| Overrides AMBIENT_ANIM_FREQ if non-zero.}}&lt;br /&gt;
{{Variable table row|AMBIENT_ANIM_STATE | int |0| Internal use by ambient behaviour system. Tracks number of animations left to play.}}&lt;br /&gt;
{{Variable table row|AMBIENT_MOVE_COUNT | int |-1| Internal use by ambient behaviour system. Tracks total number of destination points for a creature.}}&lt;br /&gt;
{{Variable table row|AMBIENT_MOVE_STATE | int |0| Internal use by ambient behaviour system. Tracks the last waypoint creature moved to and direction of travel.}}&lt;br /&gt;
{{Variable table row|AMBIENT_TICK_COUNT | int |0| Used internally, do not modify}}&lt;br /&gt;
{{Variable table row|AMBIENT_ANIM_OVERRIDE_COUNT|int|0|}}&lt;br /&gt;
{{Variable table end}}&lt;br /&gt;
&lt;br /&gt;
== ambient_ai.xls ==&lt;br /&gt;
The actions used in an animation phase are listed in the ambient_anim_patterns worksheet of [[ambient_ai.xls]]. Each row defines an animation pattern, consisting of up to thirteen actions. Each action is composed of an animation (left of the decimal) and the number of loops it is played (right of decimal). For example, 619.02 will play a sleeping loop animation twice and 619.99 will play an infinitely looping sleeping animation. Non-looping animations require no loop-count (i.e. decimal) component. The list of all available animations is located in [[ANIM_base.xls]]. &lt;br /&gt;
&lt;br /&gt;
== sys_ambient_h ==&lt;br /&gt;
&lt;br /&gt;
The script [[sys_ambient_h]] contains the implementation of the ambient behaviour system. The AMBIENT_* local variables should never be directly modified at run-time. Instead, use the following functions to customize a creature's ambient behaviour through script.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;	&lt;br /&gt;
// Normally this function is called automatically to begin or resume  ambient behaviour when a &lt;br /&gt;
// creature perceives the player. However, it can be called explicitly to force a creature to begin &lt;br /&gt;
// performing ambient behaviour or, if nAmbientEnable is 1, to enable ambient behaviour on a creature. &lt;br /&gt;
void Ambient_Start(object oCreature = OBJECT_SELF, int nAmbientEnable = 0, int nMovePattern = 0, string sMovePrefix = &amp;quot;&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
// Normally this function is called automatically to pause ambient behaviour after the party has &lt;br /&gt;
// been out of the creature's sight for a while. However, this function can be used to force a &lt;br /&gt;
// creature to temporarily cease ambient behaviour. Note that the creature will automatically  &lt;br /&gt;
// resume ambient behaviour when it perceives the player again. &lt;br /&gt;
void Ambient_Pause(object oCreature = OBJECT_SELF, int bCheckVisibility = TRUE);&lt;br /&gt;
&lt;br /&gt;
// Turns off ambient behaviour on a creature. The creature will resume ambient behaviour only &lt;br /&gt;
// after Ambient_Start() is called.&lt;br /&gt;
void Ambient_Stop(object oCreature = OBJECT_SELF);&lt;br /&gt;
&lt;br /&gt;
// Overrides the ambient animation pattern and animation frequency defined by the creature's template. &lt;br /&gt;
void Ambient_OverrideBehaviour(object oCreature, int nAnimPattern, float fAnimFreq);&lt;br /&gt;
&lt;br /&gt;
// Restores a creature's ambient animation behaviour to that defined in the creature's template.&lt;br /&gt;
void Ambient_RestoreBehaviour(object oCreature);&lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Overriding Ambient Behaviour ==&lt;br /&gt;
&lt;br /&gt;
{{Variable table start}}&lt;br /&gt;
{{Variable table row|AMBIENT_ANIM_PATTERN_OVERRIDE | int | 0 | Index into [[ambient_ai.xls]]. Specifies the list of possible actions the creature can/will perform during an animation phase.&lt;br /&gt;
* 0: no animations.}}&lt;br /&gt;
{{Variable table row| AMBIENT_ANIM_FREQ_OVERRIDE | float | -1.0 | Animation frequency. The portion left of decimal specifies the minimum and the portion right of the decimal specifies the maximum number of animations to play during an animation phase. A value of -1.0 plays all animations in the animation pattern in the order listed in [[ambient_ai.xls]].}}&lt;br /&gt;
{{Variable table row| AMBIENT_ANIM_OVERRIDE_COUNT | int | | Used internally, do not modify}}&lt;br /&gt;
{{Variable table end}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Ambient behavior]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=CreateObject&amp;diff=8007</id>
		<title>CreateObject</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=CreateObject&amp;diff=8007"/>
				<updated>2009-11-20T07:25:59Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Remarks */ grammar&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dafunction&lt;br /&gt;
|name=CreateObject&lt;br /&gt;
|brief=Create an object in the specified location. Will attempt to use a corresponding pool if one exists.&lt;br /&gt;
|param1type=int&lt;br /&gt;
|param1name=nObjectType&lt;br /&gt;
|param1desc=The object type (placeable, creature, etc)&lt;br /&gt;
|param1default=&lt;br /&gt;
|param2type=resource&lt;br /&gt;
|param2name=rTemplate&lt;br /&gt;
|param2desc=The template to use&lt;br /&gt;
|param2default=&lt;br /&gt;
|param3type=location&lt;br /&gt;
|param3name=lLoc&lt;br /&gt;
|param3desc=Location of the object&lt;br /&gt;
|param3default=&lt;br /&gt;
|param4type=string&lt;br /&gt;
|param4name=sOverrideScript&lt;br /&gt;
|param4desc=Script assigned to the object. If empty, the engine will use the template script&lt;br /&gt;
|param4default=&amp;quot;&amp;quot;&lt;br /&gt;
|param5type=int&lt;br /&gt;
|param5name=bSpawnActive&lt;br /&gt;
|param5desc=Whether or not this object is enabled at spawn time&lt;br /&gt;
|param5default=TRUE&lt;br /&gt;
|param6type=int&lt;br /&gt;
|param6name=bNoPermDeath&lt;br /&gt;
|param6desc=Set to TRUE to avoid destroying the object permanently (only valid for pool creatures)&lt;br /&gt;
|param6default=FALSE&lt;br /&gt;
|returntype=object&lt;br /&gt;
|returndesc=The new object, OBJECT_INVALID on failure&lt;br /&gt;
|sourcefile=script.ldf&lt;br /&gt;
|sourcemodule=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- == Description == --&amp;gt;&lt;br /&gt;
&amp;lt;!-- This section contains the full description from the functions comments. Do not change unless you are confident these are incomplete or incorrect. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Remarks ==&lt;br /&gt;
&amp;lt;!-- This section contains additional comments, observations and known issues. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that dynamic creation of objects in the engine is subject to a host of limitations, reason being attempts to cut down 'unaccounted' memory usage.&lt;br /&gt;
&lt;br /&gt;
Avoid using CreateObject whenever possible.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These objects can be created with CreateObject:&amp;lt;br /&amp;gt;&lt;br /&gt;
- Creature&amp;lt;br /&amp;gt;&lt;br /&gt;
- Placeable&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These objects can not be created with CreateObject:&amp;lt;br /&amp;gt;&lt;br /&gt;
- Merchant (Store)&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The function appears to assume that the lLoc parameter represents a valid safe location. If it is valid but not safe, it will be adjusted to the nearest safe location and the object will be created there instead. This is not completely confirmed, but it is clear that placeables cannot be created above the ground level in the air (z-coordinate gets adjusted). However, using SetPosition after creating the object allows you to immediately move the object to an unsafe location if that is desired (see the custom function called CreateObjectIn3DSpace provided in the example below).&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&amp;lt;!-- This section contains examples transcluded from the snippet library. --&amp;gt;&lt;br /&gt;
&amp;lt;dascript&amp;gt;void main()&lt;br /&gt;
{     &lt;br /&gt;
    // get a location from a waypoint with a unique tag&lt;br /&gt;
    object oWaypoint = GetObjectByTag(&amp;quot;wp_werewolf_spawn&amp;quot;); &lt;br /&gt;
    location lWaypoint = GetLocation(oWaypoint);&lt;br /&gt;
                  &lt;br /&gt;
    // create a werewolf object at the location&lt;br /&gt;
    object oWerewolf = CreateObject(OBJECT_TYPE_CREATURE, R&amp;quot;werewolf_core.utc&amp;quot;, lWaypoint);&lt;br /&gt;
}&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;// CreateObjectIn3DSpace - Creates a new object allowing for&lt;br /&gt;
//                         locations that are valid but unsafe.&lt;br /&gt;
//&lt;br /&gt;
// Same as CreateObject except the lLoc parameter is not adjusted to&lt;br /&gt;
// the nearest safe location allowing for creation of objects anywhere&lt;br /&gt;
// in the area including up in the air and below ground.&lt;br /&gt;
//&lt;br /&gt;
object CreateObjectIn3DSpace( int nObjectType, resource rTemplate,&lt;br /&gt;
                              location lLoc, string sOverrideScript = &amp;quot;&amp;quot;,&lt;br /&gt;
                              int bSpawnActive = TRUE, int bNoPermDeath = FALSE );&lt;br /&gt;
  &lt;br /&gt;
object CreateObjectIn3DSpace( int nObjectType, resource rTemplate,&lt;br /&gt;
                              location lLoc, string sOverrideScript = &amp;quot;&amp;quot;,&lt;br /&gt;
                              int bSpawnActive = TRUE, int bNoPermDeath = FALSE )&lt;br /&gt;
{     &lt;br /&gt;
    // Create the object using CreateObject.&lt;br /&gt;
    object oNewObject = CreateObject( nObjectType, rTemplate, lLoc, sOverrideScript, bSpawnActive, bNoPermDeath );&lt;br /&gt;
    if( !IsObjectValid( oNewObject ) ) return OBJECT_INVALID;&lt;br /&gt;
                  &lt;br /&gt;
    // Move the object to absolute location in 3D space even if it is&lt;br /&gt;
    // unsafe, then return the new object.&lt;br /&gt;
    SetPosition( oNewObject, GetPositionFromLocation( lLoc ), FALSE );&lt;br /&gt;
    return oNewObject;&lt;br /&gt;
}&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&amp;lt;!-- This section contains links to articles, functions or constant groups. --&amp;gt;&lt;br /&gt;
[[CreatePool]], [[DestroyObject]], [[OBJECT_TYPE*]]&lt;br /&gt;
[[Category: Object functions]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=CreateObject&amp;diff=8006</id>
		<title>CreateObject</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=CreateObject&amp;diff=8006"/>
				<updated>2009-11-20T07:24:22Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Remarks */ clarified Merchant means Store (OBJECT_TYPE_STORE) here.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dafunction&lt;br /&gt;
|name=CreateObject&lt;br /&gt;
|brief=Create an object in the specified location. Will attempt to use a corresponding pool if one exists.&lt;br /&gt;
|param1type=int&lt;br /&gt;
|param1name=nObjectType&lt;br /&gt;
|param1desc=The object type (placeable, creature, etc)&lt;br /&gt;
|param1default=&lt;br /&gt;
|param2type=resource&lt;br /&gt;
|param2name=rTemplate&lt;br /&gt;
|param2desc=The template to use&lt;br /&gt;
|param2default=&lt;br /&gt;
|param3type=location&lt;br /&gt;
|param3name=lLoc&lt;br /&gt;
|param3desc=Location of the object&lt;br /&gt;
|param3default=&lt;br /&gt;
|param4type=string&lt;br /&gt;
|param4name=sOverrideScript&lt;br /&gt;
|param4desc=Script assigned to the object. If empty, the engine will use the template script&lt;br /&gt;
|param4default=&amp;quot;&amp;quot;&lt;br /&gt;
|param5type=int&lt;br /&gt;
|param5name=bSpawnActive&lt;br /&gt;
|param5desc=Whether or not this object is enabled at spawn time&lt;br /&gt;
|param5default=TRUE&lt;br /&gt;
|param6type=int&lt;br /&gt;
|param6name=bNoPermDeath&lt;br /&gt;
|param6desc=Set to TRUE to avoid destroying the object permanently (only valid for pool creatures)&lt;br /&gt;
|param6default=FALSE&lt;br /&gt;
|returntype=object&lt;br /&gt;
|returndesc=The new object, OBJECT_INVALID on failure&lt;br /&gt;
|sourcefile=script.ldf&lt;br /&gt;
|sourcemodule=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- == Description == --&amp;gt;&lt;br /&gt;
&amp;lt;!-- This section contains the full description from the functions comments. Do not change unless you are confident these are incomplete or incorrect. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Remarks ==&lt;br /&gt;
&amp;lt;!-- This section contains additional comments, observations and known issues. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that dynamic creation of objects in the engine is subject to a host of limitations, reason being attempts to cut down 'unaccounted' memory usage.&lt;br /&gt;
&lt;br /&gt;
Avoid using CreateObject whenever possible.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These objects can be created with CreateObject:&amp;lt;br /&amp;gt;&lt;br /&gt;
- Creature&amp;lt;br /&amp;gt;&lt;br /&gt;
- Placeable&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These objects can not be created with CreateObject:&amp;lt;br /&amp;gt;&lt;br /&gt;
- Merchant (Store)&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The function appears to assume that the lLoc parameter represents a valid safe location. If it is valid but not safe, it will be adjusted to the nearest safe location and the object will be created there instead. This is not completely confirmed, but it is clear that placeables cannot be created above the ground level in the air (z-coordinate gets adjusted). However, using SetPosition after creating the object allows you to immediately move the object to an unsafe location if that is desired (see the custom function provided in the example below).&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&amp;lt;!-- This section contains examples transcluded from the snippet library. --&amp;gt;&lt;br /&gt;
&amp;lt;dascript&amp;gt;void main()&lt;br /&gt;
{     &lt;br /&gt;
    // get a location from a waypoint with a unique tag&lt;br /&gt;
    object oWaypoint = GetObjectByTag(&amp;quot;wp_werewolf_spawn&amp;quot;); &lt;br /&gt;
    location lWaypoint = GetLocation(oWaypoint);&lt;br /&gt;
                  &lt;br /&gt;
    // create a werewolf object at the location&lt;br /&gt;
    object oWerewolf = CreateObject(OBJECT_TYPE_CREATURE, R&amp;quot;werewolf_core.utc&amp;quot;, lWaypoint);&lt;br /&gt;
}&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;// CreateObjectIn3DSpace - Creates a new object allowing for&lt;br /&gt;
//                         locations that are valid but unsafe.&lt;br /&gt;
//&lt;br /&gt;
// Same as CreateObject except the lLoc parameter is not adjusted to&lt;br /&gt;
// the nearest safe location allowing for creation of objects anywhere&lt;br /&gt;
// in the area including up in the air and below ground.&lt;br /&gt;
//&lt;br /&gt;
object CreateObjectIn3DSpace( int nObjectType, resource rTemplate,&lt;br /&gt;
                              location lLoc, string sOverrideScript = &amp;quot;&amp;quot;,&lt;br /&gt;
                              int bSpawnActive = TRUE, int bNoPermDeath = FALSE );&lt;br /&gt;
  &lt;br /&gt;
object CreateObjectIn3DSpace( int nObjectType, resource rTemplate,&lt;br /&gt;
                              location lLoc, string sOverrideScript = &amp;quot;&amp;quot;,&lt;br /&gt;
                              int bSpawnActive = TRUE, int bNoPermDeath = FALSE )&lt;br /&gt;
{     &lt;br /&gt;
    // Create the object using CreateObject.&lt;br /&gt;
    object oNewObject = CreateObject( nObjectType, rTemplate, lLoc, sOverrideScript, bSpawnActive, bNoPermDeath );&lt;br /&gt;
    if( !IsObjectValid( oNewObject ) ) return OBJECT_INVALID;&lt;br /&gt;
                  &lt;br /&gt;
    // Move the object to absolute location in 3D space even if it is&lt;br /&gt;
    // unsafe, then return the new object.&lt;br /&gt;
    SetPosition( oNewObject, GetPositionFromLocation( lLoc ), FALSE );&lt;br /&gt;
    return oNewObject;&lt;br /&gt;
}&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&amp;lt;!-- This section contains links to articles, functions or constant groups. --&amp;gt;&lt;br /&gt;
[[CreatePool]], [[DestroyObject]], [[OBJECT_TYPE*]]&lt;br /&gt;
[[Category: Object functions]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=CreateObject&amp;diff=8005</id>
		<title>CreateObject</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=CreateObject&amp;diff=8005"/>
				<updated>2009-11-20T07:21:14Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Examples */ added custom function showing how to make a wrapper to create new objects at absolute locations in 3D space.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dafunction&lt;br /&gt;
|name=CreateObject&lt;br /&gt;
|brief=Create an object in the specified location. Will attempt to use a corresponding pool if one exists.&lt;br /&gt;
|param1type=int&lt;br /&gt;
|param1name=nObjectType&lt;br /&gt;
|param1desc=The object type (placeable, creature, etc)&lt;br /&gt;
|param1default=&lt;br /&gt;
|param2type=resource&lt;br /&gt;
|param2name=rTemplate&lt;br /&gt;
|param2desc=The template to use&lt;br /&gt;
|param2default=&lt;br /&gt;
|param3type=location&lt;br /&gt;
|param3name=lLoc&lt;br /&gt;
|param3desc=Location of the object&lt;br /&gt;
|param3default=&lt;br /&gt;
|param4type=string&lt;br /&gt;
|param4name=sOverrideScript&lt;br /&gt;
|param4desc=Script assigned to the object. If empty, the engine will use the template script&lt;br /&gt;
|param4default=&amp;quot;&amp;quot;&lt;br /&gt;
|param5type=int&lt;br /&gt;
|param5name=bSpawnActive&lt;br /&gt;
|param5desc=Whether or not this object is enabled at spawn time&lt;br /&gt;
|param5default=TRUE&lt;br /&gt;
|param6type=int&lt;br /&gt;
|param6name=bNoPermDeath&lt;br /&gt;
|param6desc=Set to TRUE to avoid destroying the object permanently (only valid for pool creatures)&lt;br /&gt;
|param6default=FALSE&lt;br /&gt;
|returntype=object&lt;br /&gt;
|returndesc=The new object, OBJECT_INVALID on failure&lt;br /&gt;
|sourcefile=script.ldf&lt;br /&gt;
|sourcemodule=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- == Description == --&amp;gt;&lt;br /&gt;
&amp;lt;!-- This section contains the full description from the functions comments. Do not change unless you are confident these are incomplete or incorrect. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Remarks ==&lt;br /&gt;
&amp;lt;!-- This section contains additional comments, observations and known issues. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that dynamic creation of objects in the engine is subject to a host of limitations, reason being attempts to cut down 'unaccounted' memory usage.&lt;br /&gt;
&lt;br /&gt;
Avoid using CreateObject whenever possible.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These objects can be created with CreateObject:&amp;lt;br /&amp;gt;&lt;br /&gt;
- Creature&amp;lt;br /&amp;gt;&lt;br /&gt;
- Placeable&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These objects can not be created with CreateObject:&amp;lt;br /&amp;gt;&lt;br /&gt;
- Merchant&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The function appears to assume that the lLoc parameter represents a valid safe location. If it is valid but not safe, it will be adjusted to the nearest safe location and the object will be created there instead. This is not completely confirmed, but it is clear that placeables cannot be created above the ground level in the air (z-coordinate gets adjusted). However, using SetPosition after creating the object allows you to immediately move the object to an unsafe location if that is desired (see the custom function provided in the example below).&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&amp;lt;!-- This section contains examples transcluded from the snippet library. --&amp;gt;&lt;br /&gt;
&amp;lt;dascript&amp;gt;void main()&lt;br /&gt;
{     &lt;br /&gt;
    // get a location from a waypoint with a unique tag&lt;br /&gt;
    object oWaypoint = GetObjectByTag(&amp;quot;wp_werewolf_spawn&amp;quot;); &lt;br /&gt;
    location lWaypoint = GetLocation(oWaypoint);&lt;br /&gt;
                  &lt;br /&gt;
    // create a werewolf object at the location&lt;br /&gt;
    object oWerewolf = CreateObject(OBJECT_TYPE_CREATURE, R&amp;quot;werewolf_core.utc&amp;quot;, lWaypoint);&lt;br /&gt;
}&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;// CreateObjectIn3DSpace - Creates a new object allowing for&lt;br /&gt;
//                         locations that are valid but unsafe.&lt;br /&gt;
//&lt;br /&gt;
// Same as CreateObject except the lLoc parameter is not adjusted to&lt;br /&gt;
// the nearest safe location allowing for creation of objects anywhere&lt;br /&gt;
// in the area including up in the air and below ground.&lt;br /&gt;
//&lt;br /&gt;
object CreateObjectIn3DSpace( int nObjectType, resource rTemplate,&lt;br /&gt;
                              location lLoc, string sOverrideScript = &amp;quot;&amp;quot;,&lt;br /&gt;
                              int bSpawnActive = TRUE, int bNoPermDeath = FALSE );&lt;br /&gt;
  &lt;br /&gt;
object CreateObjectIn3DSpace( int nObjectType, resource rTemplate,&lt;br /&gt;
                              location lLoc, string sOverrideScript = &amp;quot;&amp;quot;,&lt;br /&gt;
                              int bSpawnActive = TRUE, int bNoPermDeath = FALSE )&lt;br /&gt;
{     &lt;br /&gt;
    // Create the object using CreateObject.&lt;br /&gt;
    object oNewObject = CreateObject( nObjectType, rTemplate, lLoc, sOverrideScript, bSpawnActive, bNoPermDeath );&lt;br /&gt;
    if( !IsObjectValid( oNewObject ) ) return OBJECT_INVALID;&lt;br /&gt;
                  &lt;br /&gt;
    // Move the object to absolute location in 3D space even if it is&lt;br /&gt;
    // unsafe, then return the new object.&lt;br /&gt;
    SetPosition( oNewObject, GetPositionFromLocation( lLoc ), FALSE );&lt;br /&gt;
    return oNewObject;&lt;br /&gt;
}&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&amp;lt;!-- This section contains links to articles, functions or constant groups. --&amp;gt;&lt;br /&gt;
[[CreatePool]], [[DestroyObject]], [[OBJECT_TYPE*]]&lt;br /&gt;
[[Category: Object functions]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=CreateObject&amp;diff=8004</id>
		<title>CreateObject</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=CreateObject&amp;diff=8004"/>
				<updated>2009-11-20T07:09:09Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Remarks */ added paragraph concerning the function's behavior in regards to its handling of the location parameter provided to it. Needs further testing, clarification, and verification.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dafunction&lt;br /&gt;
|name=CreateObject&lt;br /&gt;
|brief=Create an object in the specified location. Will attempt to use a corresponding pool if one exists.&lt;br /&gt;
|param1type=int&lt;br /&gt;
|param1name=nObjectType&lt;br /&gt;
|param1desc=The object type (placeable, creature, etc)&lt;br /&gt;
|param1default=&lt;br /&gt;
|param2type=resource&lt;br /&gt;
|param2name=rTemplate&lt;br /&gt;
|param2desc=The template to use&lt;br /&gt;
|param2default=&lt;br /&gt;
|param3type=location&lt;br /&gt;
|param3name=lLoc&lt;br /&gt;
|param3desc=Location of the object&lt;br /&gt;
|param3default=&lt;br /&gt;
|param4type=string&lt;br /&gt;
|param4name=sOverrideScript&lt;br /&gt;
|param4desc=Script assigned to the object. If empty, the engine will use the template script&lt;br /&gt;
|param4default=&amp;quot;&amp;quot;&lt;br /&gt;
|param5type=int&lt;br /&gt;
|param5name=bSpawnActive&lt;br /&gt;
|param5desc=Whether or not this object is enabled at spawn time&lt;br /&gt;
|param5default=TRUE&lt;br /&gt;
|param6type=int&lt;br /&gt;
|param6name=bNoPermDeath&lt;br /&gt;
|param6desc=Set to TRUE to avoid destroying the object permanently (only valid for pool creatures)&lt;br /&gt;
|param6default=FALSE&lt;br /&gt;
|returntype=object&lt;br /&gt;
|returndesc=The new object, OBJECT_INVALID on failure&lt;br /&gt;
|sourcefile=script.ldf&lt;br /&gt;
|sourcemodule=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- == Description == --&amp;gt;&lt;br /&gt;
&amp;lt;!-- This section contains the full description from the functions comments. Do not change unless you are confident these are incomplete or incorrect. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Remarks ==&lt;br /&gt;
&amp;lt;!-- This section contains additional comments, observations and known issues. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that dynamic creation of objects in the engine is subject to a host of limitations, reason being attempts to cut down 'unaccounted' memory usage.&lt;br /&gt;
&lt;br /&gt;
Avoid using CreateObject whenever possible.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These objects can be created with CreateObject:&amp;lt;br /&amp;gt;&lt;br /&gt;
- Creature&amp;lt;br /&amp;gt;&lt;br /&gt;
- Placeable&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These objects can not be created with CreateObject:&amp;lt;br /&amp;gt;&lt;br /&gt;
- Merchant&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The function appears to assume that the lLoc parameter represents a valid safe location. If it is valid but not safe, it will be adjusted to the nearest safe location and the object will be created there instead. This is not completely confirmed, but it is clear that placeables cannot be created above the ground level in the air (z-coordinate gets adjusted). However, using SetPosition after creating the object allows you to immediately move the object to an unsafe location if that is desired (see the custom function provided in the example below).&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&amp;lt;!-- This section contains examples transcluded from the snippet library. --&amp;gt;&lt;br /&gt;
&amp;lt;dascript&amp;gt;void main()&lt;br /&gt;
{     &lt;br /&gt;
    // get a location from a waypoint with a unique tag&lt;br /&gt;
    object oWaypoint = GetObjectByTag(&amp;quot;wp_werewolf_spawn&amp;quot;); &lt;br /&gt;
    location lWaypoint = GetLocation(oWaypoint);&lt;br /&gt;
                  &lt;br /&gt;
    // create a werewolf object at the location&lt;br /&gt;
    object oWerewolf = CreateObject(OBJECT_TYPE_CREATURE, R&amp;quot;werewolf_core.utc&amp;quot;, lWaypoint);&lt;br /&gt;
}&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&amp;lt;!-- This section contains links to articles, functions or constant groups. --&amp;gt;&lt;br /&gt;
[[CreatePool]], [[DestroyObject]], [[OBJECT_TYPE*]]&lt;br /&gt;
[[Category: Object functions]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Classes&amp;diff=7723</id>
		<title>Classes</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Classes&amp;diff=7723"/>
				<updated>2009-11-15T04:08:27Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Character Creation Scripting */ grammar&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''Work in progress''&lt;br /&gt;
&lt;br /&gt;
=== Overview ===&lt;br /&gt;
&lt;br /&gt;
Dragon Age: Origins is a strongly class based RPG featuring 3 distinct character classes with exclusive abilities and progressions.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Description ===&lt;br /&gt;
&lt;br /&gt;
This page explains the technical implementation and role of character classes in Dragon Age: Origins and is aimed at people wishing to create new content, modifications or adventures using the Dragon Age ruleset.&lt;br /&gt;
&lt;br /&gt;
The classes of the game are defined in '''[[CLA_base.xls]]'''.  &lt;br /&gt;
The following is an excerpt of the game rules and systems relevant columns in the file and illustrates how data relating to character class is stored.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; width=&amp;quot;100%&amp;quot; style=&amp;quot;font-size:xx-small&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''ID'''||'''Label'''||'''BaseHealth'''||'''BaseManaStamina'''||'''DepletableProgression'''||'''StrAdjust'''||'''ConAdjust'''||'''WillAdjust'''||'''MagAdjust'''||'''CunAdjust'''||'''DexAdjust'''||'''BaseAttack'''||'''BaseDefense'''||'''DefensePerLevel'''||'''HealthPerLevel'''||'''LevelsPerAbility'''||'''LevelsPerSkill'''||'''DamagePerLevel'''&lt;br /&gt;
|-&lt;br /&gt;
|0||INVALID||****||****||****||****||****||****||****||****||****||****||****||****||****||****||****||****|&lt;br /&gt;
|-&lt;br /&gt;
|1||Warrior||100||100||5||4||3||0||0||0||3||60||45||1||6||1||3||0.4&lt;br /&gt;
|-&lt;br /&gt;
|2||Wizard||85||115||6||0||0||4||5||1||0||50||40||1||4||1||3||0.1&lt;br /&gt;
|-&lt;br /&gt;
|3||Rogue||90||90||4||0||0||2||0||4||4||55||50||1||5||1||2||0.2&lt;br /&gt;
|-|&lt;br /&gt;
|}&lt;br /&gt;
For details on the meaning of each column, please refer to '''[[CLA_base.xls]]'''.&lt;br /&gt;
&lt;br /&gt;
=== Character Creation Scripting === &lt;br /&gt;
&lt;br /&gt;
Dragon Age characters are 'blank' when the game starts, with all their [[Creature Properties]] initialized to default values. &lt;br /&gt;
&lt;br /&gt;
The character generation scripts, through interaction with the Character Creation UIs, use the data in [[CLA_base.xls]] to construct the character based on the player's choices. They are also responsible for any modification to the character's base stats during the Levelup process.&lt;br /&gt;
&lt;br /&gt;
Note that major party members will use the character creation scripts, hostile enemies use a speed optimized and abreviated algorithm to determine their attributes based on rank, AI package and level. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Scripts ====&lt;br /&gt;
&lt;br /&gt;
The scripts that handle most of character creation and levelup are:&lt;br /&gt;
&lt;br /&gt;
* sys_chargen - Entry point for all character creation based [[Event]]s that get routed into this file from module_core.nss. &lt;br /&gt;
* sys_chargen_h - Library containing most of the underlying logic for modifying [[Creature Properties]] based on the game rules.&lt;br /&gt;
* sys_chargen_engine - Include defining a few constants and containing some snippets of relevant engine code for reference.&lt;br /&gt;
* sys_autolevelup_h - File defining the logic used by Party Member NPCs to level up when they are hired. After that, they use normal levelup.&lt;br /&gt;
* sys_autoscale_h - Contains shared logic used for determining levelup condition and code for creature autoscaling.&lt;br /&gt;
* sys_rewards_h - File containing XP reward entry point and levelup checks.&lt;br /&gt;
&lt;br /&gt;
[[Category: Scripts]]&lt;br /&gt;
[[Category: Character_generation]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=CreateObject&amp;diff=7722</id>
		<title>CreateObject</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=CreateObject&amp;diff=7722"/>
				<updated>2009-11-15T03:15:24Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Remarks */ grammar&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dafunction&lt;br /&gt;
|name=CreateObject&lt;br /&gt;
|brief=Create an object in the specified location. Will attempt to use a corresponding pool if one exists.&lt;br /&gt;
|param1type=int&lt;br /&gt;
|param1name=nObjectType&lt;br /&gt;
|param1desc=The object type (placeable, creature, etc)&lt;br /&gt;
|param1default=&lt;br /&gt;
|param2type=resource&lt;br /&gt;
|param2name=rTemplate&lt;br /&gt;
|param2desc=The template to use&lt;br /&gt;
|param2default=&lt;br /&gt;
|param3type=location&lt;br /&gt;
|param3name=lLoc&lt;br /&gt;
|param3desc=Location of the object&lt;br /&gt;
|param3default=&lt;br /&gt;
|param4type=string&lt;br /&gt;
|param4name=sOverrideScript&lt;br /&gt;
|param4desc=Script assigned to the object. If empty, the engine will use the template script&lt;br /&gt;
|param4default=&amp;quot;&amp;quot;&lt;br /&gt;
|param5type=int&lt;br /&gt;
|param5name=bSpawnActive&lt;br /&gt;
|param5desc=Whether or not this object is enabled at spawn time&lt;br /&gt;
|param5default=TRUE&lt;br /&gt;
|param6type=int&lt;br /&gt;
|param6name=bNoPermDeath&lt;br /&gt;
|param6desc=Set to TRUE to avoid destroying the object permanently (only valid for pool creatures)&lt;br /&gt;
|param6default=FALSE&lt;br /&gt;
|returntype=object&lt;br /&gt;
|returndesc=The new object, OBJECT_INVALID on failure&lt;br /&gt;
|sourcefile=script.ldf&lt;br /&gt;
|sourcemodule=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- == Description == --&amp;gt;&lt;br /&gt;
&amp;lt;!-- This section contains the full description from the functions comments. Do not change unless you are confident these are incomplete or incorrect. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Remarks ==&lt;br /&gt;
&amp;lt;!-- This section contains additional comments, observations and known issues. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that dynamic creation of objects in the engine is subject to a host of limitations, reason being attempts to cut down 'unaccounted' memory usage.&lt;br /&gt;
&lt;br /&gt;
Avoid using CreateObject whenever possible.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These objects can be created with CreateObject:&amp;lt;br /&amp;gt;&lt;br /&gt;
- Creature&amp;lt;br /&amp;gt;&lt;br /&gt;
- Placeable&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These objects can not be created with CreateObject:&amp;lt;br /&amp;gt;&lt;br /&gt;
- Merchant&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&amp;lt;!-- This section contains examples transcluded from the snippet library. --&amp;gt;&lt;br /&gt;
&amp;lt;dascript&amp;gt;void main()&lt;br /&gt;
{     &lt;br /&gt;
    // get a location from a waypoint with a unique tag&lt;br /&gt;
    object oWaypoint = GetObjectByTag(&amp;quot;wp_werewolf_spawn&amp;quot;); &lt;br /&gt;
    location lWaypoint = GetLocation(oWaypoint);&lt;br /&gt;
                  &lt;br /&gt;
    // create a werewolf object at the location&lt;br /&gt;
    object oWerewolf = CreateObject(OBJECT_TYPE_CREATURE, R&amp;quot;werewolf_core.utc&amp;quot;, lWaypoint);&lt;br /&gt;
}&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&amp;lt;!-- This section contains links to articles, functions or constant groups. --&amp;gt;&lt;br /&gt;
[[CreatePool]], [[DestroyObject]], [[OBJECT_TYPE*]]&lt;br /&gt;
[[Category: Object functions]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=2DA&amp;diff=7605</id>
		<title>2DA</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=2DA&amp;diff=7605"/>
				<updated>2009-11-12T11:46:52Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: removed section for item xls files. items are already in the objects section.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Many of the properties of objects in the toolset make reference to 2DAs (two-dimensional arrays). These are read-only arrays containing various data used by scripting and the game engine. For example, the set of local variables that an object supports is defined in a 2DA.&lt;br /&gt;
&lt;br /&gt;
The source files for 2DAs are Microsoft Excel worksheets. This allows a wide variety of sophisticated techniques to be used to generate the values of the 2DA fields, such as macros and formulas. It also makes editing much easier since the columns can be annotated and formatted in helpful ways, and multiple related worksheets can be grouped into one file.&lt;br /&gt;
&lt;br /&gt;
Data in a 2DA is identified by a row number, with the first row (row zero) usually being reserved for internal use (undefined value, etc.) by convention. Each row has an arbitrary number of columns identified by strings. &lt;br /&gt;
&lt;br /&gt;
Before they can be used by the toolset or the game, 2DAs must be converted from Excel files into a more efficient form. Processed 2DAs are stored in files with the .[[GDA]] extension.&lt;br /&gt;
&lt;br /&gt;
== Excel file formatting ==&lt;br /&gt;
&lt;br /&gt;
Cell A1 will contain &amp;quot;ID&amp;quot;. This is checked by the processor and the worksheet will fail if this is not the case.&lt;br /&gt;
&lt;br /&gt;
Column A starting at line 3 will contain an integer row ID number that is unique to that row across all files (unless creating an M2DA override). Row IDs will be listed from smallest to highest within the same file and do not need to be consecutive.&lt;br /&gt;
&lt;br /&gt;
A blank row or column will determine the dimension of the spreadsheet in that direction. Everything past that point is ignored by the binarizer.&lt;br /&gt;
&lt;br /&gt;
Column names are case sensitive. This is because of the CRC32 algorithm used to generate the hash key. Changing the case of a column name after it is in use will break the game. White space before and after a column name will be removed before hashing.&lt;br /&gt;
&lt;br /&gt;
Row 2 will be a &amp;quot;types&amp;quot; row. Each is a single word: [[int]], [[string]] (single chars as well), [[resource]], [[float]] or [[bool]]. A special type &amp;quot;[[comment]]&amp;quot; can be used to exclude a column from export.&lt;br /&gt;
&lt;br /&gt;
Any column with string data that refers to files should have a type of &amp;quot;resource&amp;quot; and not &amp;quot;string&amp;quot;. This is because the &amp;quot;resource&amp;quot; type is used to determine dependencies for the 2DA file.&lt;br /&gt;
&lt;br /&gt;
'bool' type may be one of: a zero or non-zero number, Yes or No (case insensitive), or words beginning with T or F (such as True! and False!). NOTE: You cannot use TRUE and FALSE because Excel converts those to a special keyword the binarizer can't parse properly at this time. '''Note:''' the scripting language doesn't have a function for retrieving boolean values from a 2DA, and the behavior of Get2DAInt when retrieving a boolean is untested. It is probably safer to just use an integer for scripting purposes.&lt;br /&gt;
&lt;br /&gt;
If you wish to leave a cell unfilled, the string &amp;quot;****&amp;quot; (four asterisks) can be inserted instead of a value.&lt;br /&gt;
&lt;br /&gt;
Any worksheets that are not exportable 2DA data will have an underscore prepended to their name - the resource builder will subsequently ignore them.&lt;br /&gt;
&lt;br /&gt;
Worksheets need to have unique names among all excel files, duplicates will overwrite each other as each worksheet is exported as a file&lt;br /&gt;
&lt;br /&gt;
You cannot have the workbook open in Excel at the same time as running the binarizer on it.&lt;br /&gt;
&lt;br /&gt;
Strings have a maximum length of 768 characters. Anything longer will be truncated.&lt;br /&gt;
&lt;br /&gt;
== Extending the game via M2DAs ==&lt;br /&gt;
&lt;br /&gt;
An &amp;quot;M2DA&amp;quot; is a &amp;quot;Multiple 2DA&amp;quot; that stacks a number of 2DA files into one larger table. They work much like single 2DA files except they can be patched or expanded later by adding more resources. These are useful for any table that lists other resources, such as appearance tables, so that new resources can be added later without having to modify a monolithic table.&lt;br /&gt;
&lt;br /&gt;
This is especially important for third-party modders, since BioWare might release an update to a core table at a later date that would overwrite any changes third parties had made to it. By using an M2DA with a unique name, and by using a range of ID numbers significantly separated from those already in use, you can ensure that your additions won't conflict with other portions of the M2DA.&lt;br /&gt;
&lt;br /&gt;
A list of all M2DAs used by the game can be found in [[2DA_base.xls]]. Every 2da listed in M2DA_base is treated as a M2DA, except for those with an ID between 10000 and 10999 which are handled as regular 2DAs. Each M2DA has a label that describes the subject covered by the M2DA and a worksheet prefix that all components of that M2DA must use.&lt;br /&gt;
&lt;br /&gt;
Every worksheet listed in M2DA_base is actually a prefix. The system reads this prefix and then searches through all the 2DAs for the ones starting with this prefix and merges them together as one 2DA. For example: M2DA Id 0 is &amp;quot;ANIM_&amp;quot;. The system looks through its list of 2das and finds &amp;quot;ANIM_base&amp;quot;, &amp;quot;ANIM_combat&amp;quot; and &amp;quot;ANIM_walk&amp;quot;. It will read and merge all 3 2DAs into an M2DA called &amp;quot;ANIM_&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Not all of the prefixes end in an underscore. For example, longsword variations are in worksheets prefixed with &amp;quot;longsword_variation&amp;quot;, so both &amp;quot;longsword_variation_candyland&amp;quot; and &amp;quot;longsword_variationcandyland&amp;quot; would work as M2DA worksheet names.&lt;br /&gt;
&lt;br /&gt;
2DAs are merged row by row, keyed on the ID column. If two rows in two different 2DAs to be merged have the same ID, the row in the2da with the highest priority wins.&lt;br /&gt;
&lt;br /&gt;
== 2daExporter.xls ==&lt;br /&gt;
&lt;br /&gt;
To convert an XLS file into a 2DA usable by the game, another Excel file is used; &amp;lt;code&amp;gt;2daExporter.xls&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
[[Image:2DA exporter.png]]&lt;br /&gt;
&lt;br /&gt;
It has the following settings:&lt;br /&gt;
*ResourceBuild Path: The path to ResourceBuild.exe, which is installed by default in your Dragon Age directory under tools\ResourceBuild&lt;br /&gt;
*2DA Path: The source path of the XLS files to be exported. This is the root directory, you can specify subdirectories for each individual XLS file.&lt;br /&gt;
*Override Path: The path to the override directory that the completed 2DAs should be exported to.&lt;br /&gt;
*Debug Mode:&lt;br /&gt;
&lt;br /&gt;
Simply list the xls files you wish to convert, one to a line, and then click on the &amp;quot;Export Selected&amp;quot; button. The converted 2DAs will be exported to the specified override path. Remember that the 2DAs are generated from worksheets inside the xls files so converting one xls file can produce a number of different GDA files in the output directory.&lt;br /&gt;
&lt;br /&gt;
2daExporter.xls has been tested with Microsoft Excel, it has not been tested with other compatible spreadsheet programs. It may have trouble with paths that have spaces in their names (eg, &amp;quot;C:\My Documents&amp;quot;); if your export attempt fails try moving your working directories to a directory path with no spaces.&lt;br /&gt;
&lt;br /&gt;
== Adding 2DA export to the Windows XP file explorer ==&lt;br /&gt;
&lt;br /&gt;
Here's an easy way to add a context menu item that quickly converts new or updated Dragon Age Excel files into GDA format: &lt;br /&gt;
&lt;br /&gt;
Setup: &lt;br /&gt;
&lt;br /&gt;
# Open Windows Explorer and click Tools | Folder Options.&lt;br /&gt;
# In the File Types tab, select the XLS extension from the list and click the Advanced button.&lt;br /&gt;
# Click the New button and put 'Binarize 2DA' in the Action field.&lt;br /&gt;
# Paste the following in the Application field and click OK (update the drive and folder names to match your client): &amp;lt;tt&amp;gt;C:\DA\tag\main\ResourceBuild\Processors\ExcelProcessor.exe  &amp;quot;%l&amp;quot;  -outdir=C:\DA\tag\main\build\packages\core\override&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that paths with spaces in them can cause Windows trouble, if your paths have spaces in them remember to wrap them in quotation marks.&lt;br /&gt;
&lt;br /&gt;
Usage:&lt;br /&gt;
&lt;br /&gt;
# Using Windows Explorer, navigate to your 2DA folder (in my case C:\DA\tag\main\data\Source\2DA) and select the Excel file(s) to process. Right click and select 'Binarize 2DA' from the context menu. &lt;br /&gt;
# Confirm a corresponding GDA file is created in your override folder (in my case C:\DA\tag\main\build\packages\core\override) for each Excel file processed.&lt;br /&gt;
&lt;br /&gt;
== Step-by-Step ==&lt;br /&gt;
&lt;br /&gt;
If you have problems using the 2daExporter.xls spreadsheet to generate 2DAs the following method may work instead:&lt;br /&gt;
&lt;br /&gt;
*Create two folders called C:\2DA\ and C:\2DA\Override\&lt;br /&gt;
*Copy ExcelProcessor.exe to C:\2DA\&lt;br /&gt;
*Copy the Excel spreadsheets containing the 2DA you want to use in the game to C:\2DA\&lt;br /&gt;
*Create a batch file with the following line in it (change &amp;quot;placeables.xls&amp;quot; to whatever Excel file you're working with):&lt;br /&gt;
C:\2DA\ExcelProcessor.exe placeables.xls -outdir=C:\2DA\override\&lt;br /&gt;
*Run your batch file&lt;br /&gt;
*Find the GDA file from the C:\2DA\Override\ directory and copy it to the game's override directory. Remember to take into account the naming conventions of M2DAs; you may need to rename your 2DA files with a new suffix unique to your module to allow it to add to the core 2DAs without conflict.&lt;br /&gt;
&lt;br /&gt;
== 2DA XLS files used in Dragon Age ==&lt;br /&gt;
&lt;br /&gt;
''Note: This list is very incomplete right now''&lt;br /&gt;
&lt;br /&gt;
Bear in mind that 2DAs names are actually based on the names of the worksheets inside these Excel files, not the names of the files themselves. Some of these files contain a large number of individual 2DAs within them. They are bundled together into Excel files based on the nature of the 2DAs for convenience.&lt;br /&gt;
&lt;br /&gt;
=== Creatures ===&lt;br /&gt;
&lt;br /&gt;
*[[APR_base.xls]] - appearance types for creatures&lt;br /&gt;
*[[ABI_base.xls]] - integrates all talents and spells into the game&lt;br /&gt;
*[[ANIM_base.xls]]&lt;br /&gt;
*[[ANIM_combat.xls]]&lt;br /&gt;
*[[ANIM placeables.xls]]&lt;br /&gt;
*[[SyncAnimations.xls]]&lt;br /&gt;
*[[CLA_base.xls]] - Defines the character classes used throughout the game&lt;br /&gt;
*[[background.xls]] - defines the various origin stories available to each race and class.&lt;br /&gt;
&lt;br /&gt;
=== Objects ===&lt;br /&gt;
*[[placeables.xls]] - interactive object types&lt;br /&gt;
*[[BITM base.xls]] - item types&lt;br /&gt;
*[[ItemVariations.xls]] - item appearance variations (eg, all the different ways a longsword can look)&lt;br /&gt;
*[[PRJ_base.xls]] - how various projectiles look and behave&lt;br /&gt;
*[[VFX_base.xls]] - Visual effects&lt;br /&gt;
&lt;br /&gt;
=== Areas and plots ===&lt;br /&gt;
&lt;br /&gt;
*[[worldmaps.xls]] - world maps for open-ended travel between areas&lt;br /&gt;
*[[plottypes.xls]] - how plots are grouped at the highest level in the game GUI (codex entry types, story, etc.)&lt;br /&gt;
*[[areadata.xls]] - sets various properties for specific areas&lt;br /&gt;
*[[rewards.xls]] - rewards for plot completion&lt;br /&gt;
&lt;br /&gt;
== Adding Strings ==&lt;br /&gt;
&lt;br /&gt;
When adding strings to a 2DA, you have two options.  The simplest is to enter **** for the StringID column.  In that case, the name column will be used in the game.&lt;br /&gt;
&lt;br /&gt;
The other approach is to use the toolset's string editor to create a new string.  When that happens, you'll get a new StringID.  Take that StringID and add 16777216 to the number.  Next enter that number into the StringID column in the 2DA.&lt;br /&gt;
&lt;br /&gt;
The second approach works better when translating your module, at the cost of portability.  If someone else wanted to reuse your 2DA, they'd have to generate their own strings, then update the StringID number based on these IDs.&lt;br /&gt;
&lt;br /&gt;
[[Category:2DAs]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=ABI_base.xls&amp;diff=7604</id>
		<title>ABI base.xls</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=ABI_base.xls&amp;diff=7604"/>
				<updated>2009-11-12T11:39:28Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* ability_effects worksheet */ moved line in table to a more appropriate row&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is the 2DA that integrates all talents and spells into the game. It sets their names, icons, prerequesites, and various standard details of how they function (animations, cooldown period, etc.).&lt;br /&gt;
&lt;br /&gt;
When making abilities the best way to proceed is to copy the nearest analogous ability and then modify the specific columns you need to.&lt;br /&gt;
&lt;br /&gt;
During Dragon Age's development this file was automatically updated from an internal database. End user builders can update it manually.&lt;br /&gt;
&lt;br /&gt;
== ABI_Base worksheet ==&lt;br /&gt;
&lt;br /&gt;
{{2da start|ABI_Base}}&lt;br /&gt;
{{2da column| label |string| Purely for readability, not accessed anywhere.}}&lt;br /&gt;
{{2da column| namestrref |int| String Ref ID of the name of the ability (put in Core Talk Table).}}&lt;br /&gt;
{{2da column| descstrref |int| String Ref ID of the description of the ability (put in Core Talk Table).}}&lt;br /&gt;
{{2da column| tooltipstrref |int| }}&lt;br /&gt;
{{2da column| strid_effect| int| String Ref ID of the buff/debuff description on mouse over (put in Core Talk Table).}}&lt;br /&gt;
{{2da column| icon|string| Name of the icon file, without extension.}}&lt;br /&gt;
{{2da column| abilitytype | int| See 2DA_Constants_H for what the numbers are. 1 - talent, 2 - spell, 3 - skill, 4 - item}}&lt;br /&gt;
{{2da column| abilitymode |int| }}&lt;br /&gt;
{{2da column| conditions |int| }}&lt;br /&gt;
{{2da column| condition_mode | int| }}&lt;br /&gt;
{{2da column| condition_group |int| This links abilities. Use the lowest integer of the group. Whenever one of these abilities is used it will turn off the other linked abilities. So it makes it so that multiple modal abilities can't be activated at once.}}&lt;br /&gt;
{{2da column| cost| float| How much Mana/Stamina an ability will cost.}}&lt;br /&gt;
{{2da column| costupkeep |float| How much from the max Mana/Stamina an ability takes away until it is deactivated (modal abilities only)}}&lt;br /&gt;
{{2da column| prereqability |int | The ID of a prereq ability.}}&lt;br /&gt;
{{2da column| prereqlevel | int| Minimum character level to pick it up.}}&lt;br /&gt;
{{2da column| prereqattribute | int | Which attribute is a prereq for the ability. See [[properties.xls]] for what this number maps to.}}&lt;br /&gt;
{{2da column| prereqattvalue | int | The value the specified attribute has to be greater than.}}&lt;br /&gt;
{{2da column| guitype | int | This is the category that the ability is grouped into. Things like, &amp;quot;Creation&amp;quot; and &amp;quot;Primal&amp;quot;. See [[guitypes.xls]].}}&lt;br /&gt;
{{2da column| targettype | int | A bit operator which indicates which classes of targets the ability will affect. Check out the &amp;quot;_Control&amp;quot; tab of ABI_base.xls. Search for &amp;quot;Friendly Creature&amp;quot; and you'll get to the right values.}}&lt;br /&gt;
{{2da column| autotarget | int| If set to TRUE then it will automatically target a selected hostile or friendly creature. }}&lt;br /&gt;
{{2da column| range | int| Range 1 means melee, 2 close spell range, 3 long spell range. 4+ should be used only with care.}}&lt;br /&gt;
{{2da column| speed |int|  This is the speed the ability is used at. 0 is instant, 1 is quick, 2 is slow, 3+ is too slow to be fun.}}&lt;br /&gt;
{{2da column| usetype |int | Whether the ability is a passive, toggle, or instant use. Check out the &amp;quot;_Control&amp;quot; tab of ABI_base.xls. Search for &amp;quot;ABILITY_USETYPE_&amp;quot;.}}&lt;br /&gt;
{{2da column| spellscript |string| This is the script that is run when the ability is used. Includes the file extension &amp;quot;.ncs&amp;quot;.}}&lt;br /&gt;
{{2da column| cooldown | float | The ability cooldown in seconds.}}&lt;br /&gt;
{{2da column| conjurevfx | int| This is the VFX that is played during the conjure stage of the ability. This is defined in [[VFX_base.xls]]. Best practices is to make one entry for each spell so that way the FX artists can make a unique VFX tweak to an ability easily.}}&lt;br /&gt;
{{2da column| blendtree | string| Set by animators for abilities that change the default animations of a PC or party member. E.g. when you use &amp;quot;Shield Wall&amp;quot; your idle becomes a defensive crouch using your shield prominently.}}&lt;br /&gt;
{{2da column| conjureanim | int | Which animation to play during the conjure sequence. A list of values is located at [[ANIM_base.xls]].}}&lt;br /&gt;
{{2da column| castanim | int | Which animation to play during the casting sequence. A list of values is located at [[ANIM_base.xls]].}}&lt;br /&gt;
{{2da column| projectile | int |  This is the model name for projectiles. See [[PRJ_base.xls]] for the integers. 1 is a common one for arrow.}}&lt;br /&gt;
{{2da column| autocancel | int| Obsolete }}&lt;br /&gt;
{{2da column| autodraw |int| Whether using this ability will automatically draw your weapon.}}&lt;br /&gt;
{{2da column| threat_use|float| Obsolete}}&lt;br /&gt;
{{2da column| threat_impact|float| This is the amount of threat generated by each impact. May be obsolete.}}&lt;br /&gt;
{{2da column| aoe_type|int| 1 is a circle, 2 is a cone.}}&lt;br /&gt;
{{2da column| aoe_idx|int| Defined areas of effect. Located at [[VFX_base.xls]].}}&lt;br /&gt;
{{2da column| aoe_param1 |float| Either the radius of the circle or degree arc of the cone.}}&lt;br /&gt;
{{2da column| aoe_param2 |float| Obsolete}}&lt;br /&gt;
{{2da column| vfx_impact0| int| The VFX that is used at each impact. [[VFX_base.xls]]}}&lt;br /&gt;
{{2da column| vfx_impact1|int| This isn't used by the engine, but can be used as a constant in the scripts if you like.}}&lt;br /&gt;
{{2da column| flags |int|{{undocumented}} }}&lt;br /&gt;
{{2da column| showintactics| int| Set to 1 for abilities that PC or party members will want to use in the tactics system.}}&lt;br /&gt;
{{2da column| showinchargen |int| {{undocumented}} }}&lt;br /&gt;
{{2da column| passive_id |int| {{undocumented}} }}&lt;br /&gt;
{{2da column| crust_id | int| Obsolete}}&lt;br /&gt;
{{2da column| resistance |int | {{undocumented}} }} &lt;br /&gt;
{{2da column| damageinfo | int| {{undocumented}} }}&lt;br /&gt;
{{2da column| condition_appgroup|int|{{undocumented}} }}&lt;br /&gt;
{{2da column| ProcessWithEvent | int| If specified this ability does not use any of the normal ability functionality but instead fires and processes and event - meaning it even works when the game is paused. Use with care. }}&lt;br /&gt;
{{2da column| fatigue | float | {{undocumented}} }}&lt;br /&gt;
{{2da end}}&lt;br /&gt;
&lt;br /&gt;
== ability_data worksheet ==&lt;br /&gt;
&lt;br /&gt;
{{2da start|ability_data}}&lt;br /&gt;
{{2da column| Label | comment | {{undocumented}} }}&lt;br /&gt;
{{2da column| bHostileint | int | {{undocumented}} }} &lt;br /&gt;
{{2da column| effectImpact | int | {{undocumented}} }} &lt;br /&gt;
{{2da column| effectResisted| int | {{undocumented}} }} &lt;br /&gt;
{{2da column| effectDuration| float | positive: temporary. 0.0 instant. negative permanent }}&lt;br /&gt;
{{2da column| dmg_function | int | {{undocumented}} }} &lt;br /&gt;
{{2da column| dmg_param0 | float | {{undocumented}} }} &lt;br /&gt;
{{2da column| dmg_param1| int | {{undocumented}} }} &lt;br /&gt;
{{2da column| dmg_type| int |&lt;br /&gt;
*const int DAMAGE_TYPE_INVALID                       - 0;&lt;br /&gt;
*const int DAMAGE_TYPE_PHYSICAL                      - 1;&lt;br /&gt;
*const int DAMAGE_TYPE_FIRE                          - 2;&lt;br /&gt;
*const int DAMAGE_TYPE_COLD                          - 3;&lt;br /&gt;
*const int DAMAGE_TYPE_ELECTRICITY                   - 4;&lt;br /&gt;
*const int DAMAGE_TYPE_POISON                        - 5;&lt;br /&gt;
*const int DAMAGE_TYPE_LETHAL                        - 6;&lt;br /&gt;
*const int DAMAGE_TYPE_TBD                           - 7;}}&lt;br /&gt;
{{2da column| dmg_flags | int |&lt;br /&gt;
*const int DAMAGE_EFFECT_FLAG_NONE        - 0x00000000 ;&lt;br /&gt;
*const int DAMAGE_EFFECT_FLAG_CRITICAL    - 0x00000001; //critical hit&lt;br /&gt;
*const int DAMAGE_EFFECT_FLAG_DEATHBLOW   - 0x00000002; //death blow&lt;br /&gt;
*const int DAMAGE_EFFECT_FLAG_UPDATE_GORE - 0x00000004; //update gore on attacker&lt;br /&gt;
*const int DAMAGE_EFFECT_FLAG_LEECH_50    - 0x00000008; //leech 50% health back to attacker&lt;br /&gt;
*const int DAMAGE_EFFECT_FLAG_LEECH_75    - 0x00000010; //leech 75% health back to attacker&lt;br /&gt;
*const int DAMAGE_EFFECT_FLAG_LEECH_100   - 0x00000020; //leech 100% health back to attacker&lt;br /&gt;
*const int DAMAGE_EFFECT_FLAG_LEECH_MANA  - 0x00000040; // mana is leeched instead of health}}&lt;br /&gt;
{{2da end}}&lt;br /&gt;
&lt;br /&gt;
== ability_effects worksheet ==&lt;br /&gt;
&lt;br /&gt;
{{2da start|ability_effects}}&lt;br /&gt;
{{2da column| Label| string | {{undocumented}} }} &lt;br /&gt;
{{2da column| effect| int | {{undocumented}} }} &lt;br /&gt;
{{2da column| effect_label| comment | {{undocumented}} }} &lt;br /&gt;
{{2da column| effect_int1| int | {{undocumented}} }} &lt;br /&gt;
{{2da column| effect_int2| int | {{undocumented}} }} &lt;br /&gt;
{{2da column| effect_int3| int | {{undocumented}} }} &lt;br /&gt;
{{2da column| effect_float0| float | {{undocumented}} }} &lt;br /&gt;
{{2da column| effect_float1| float | {{undocumented}} }} &lt;br /&gt;
{{2da column| effect_object0 |int| 0 - don't set, 1 - set to OBJECT_SELF, 2 - set to caster}}&lt;br /&gt;
{{2da column| scaled_field |int| 0 - none, 1 - float0, 2 - float1}}&lt;br /&gt;
{{2da column| vfx| int | {{undocumented}} }} &lt;br /&gt;
{{2da column| resistance| int |&lt;br /&gt;
*const int PROPERTY_ATTRIBUTE_RESISTANCE_MENTAL     - 32;&lt;br /&gt;
*const int PROPERTY_ATTRIBUTE_RESISTANCE_AVOIDANCE  - 31;&lt;br /&gt;
*const int PROPERTY_ATTRIBUTE_RESISTANCE_PHYSICAL   - 33;}}&lt;br /&gt;
{{2da end}}&lt;br /&gt;
&lt;br /&gt;
== passive_abilities worksheet ==&lt;br /&gt;
&lt;br /&gt;
{{2da start|passive_abilities}}&lt;br /&gt;
{{2da column| Label | comment | }}&lt;br /&gt;
{{2da column| Prop1 |int| link to [[properties.xls]]}}&lt;br /&gt;
{{2da column| Modifier1|float| Modifier this applies onto the property}}&lt;br /&gt;
{{2da column| Prop2| int | }} &lt;br /&gt;
{{2da column| Modifier2| float | }} &lt;br /&gt;
{{2da column| Prop3| int | }} &lt;br /&gt;
{{2da column| Modifier3| float | }} &lt;br /&gt;
{{2da column| Comment| comment | Summary of the ability in human-readable form }} &lt;br /&gt;
{{2da end}}&lt;br /&gt;
&lt;br /&gt;
[[Category:2DAs]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=2DA&amp;diff=7602</id>
		<title>2DA</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=2DA&amp;diff=7602"/>
				<updated>2009-11-12T10:53:02Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Items */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Many of the properties of objects in the toolset make reference to 2DAs (two-dimensional arrays). These are read-only arrays containing various data used by scripting and the game engine. For example, the set of local variables that an object supports is defined in a 2DA.&lt;br /&gt;
&lt;br /&gt;
The source files for 2DAs are Microsoft Excel worksheets. This allows a wide variety of sophisticated techniques to be used to generate the values of the 2DA fields, such as macros and formulas. It also makes editing much easier since the columns can be annotated and formatted in helpful ways, and multiple related worksheets can be grouped into one file.&lt;br /&gt;
&lt;br /&gt;
Data in a 2DA is identified by a row number, with the first row (row zero) usually being reserved for internal use (undefined value, etc.) by convention. Each row has an arbitrary number of columns identified by strings. &lt;br /&gt;
&lt;br /&gt;
Before they can be used by the toolset or the game, 2DAs must be converted from Excel files into a more efficient form. Processed 2DAs are stored in files with the .[[GDA]] extension.&lt;br /&gt;
&lt;br /&gt;
== Excel file formatting ==&lt;br /&gt;
&lt;br /&gt;
Cell A1 will contain &amp;quot;ID&amp;quot;. This is checked by the processor and the worksheet will fail if this is not the case.&lt;br /&gt;
&lt;br /&gt;
Column A starting at line 3 will contain an integer row ID number that is unique to that row across all files (unless creating an M2DA override). Row IDs will be listed from smallest to highest within the same file and do not need to be consecutive.&lt;br /&gt;
&lt;br /&gt;
A blank row or column will determine the dimension of the spreadsheet in that direction. Everything past that point is ignored by the binarizer.&lt;br /&gt;
&lt;br /&gt;
Column names are case sensitive. This is because of the CRC32 algorithm used to generate the hash key. Changing the case of a column name after it is in use will break the game. White space before and after a column name will be removed before hashing.&lt;br /&gt;
&lt;br /&gt;
Row 2 will be a &amp;quot;types&amp;quot; row. Each is a single word: [[int]], [[string]] (single chars as well), [[resource]], [[float]] or [[bool]]. A special type &amp;quot;[[comment]]&amp;quot; can be used to exclude a column from export.&lt;br /&gt;
&lt;br /&gt;
Any column with string data that refers to files should have a type of &amp;quot;resource&amp;quot; and not &amp;quot;string&amp;quot;. This is because the &amp;quot;resource&amp;quot; type is used to determine dependencies for the 2DA file.&lt;br /&gt;
&lt;br /&gt;
'bool' type may be one of: a zero or non-zero number, Yes or No (case insensitive), or words beginning with T or F (such as True! and False!). NOTE: You cannot use TRUE and FALSE because Excel converts those to a special keyword the binarizer can't parse properly at this time. '''Note:''' the scripting language doesn't have a function for retrieving boolean values from a 2DA, and the behavior of Get2DAInt when retrieving a boolean is untested. It is probably safer to just use an integer for scripting purposes.&lt;br /&gt;
&lt;br /&gt;
If you wish to leave a cell unfilled, the string &amp;quot;****&amp;quot; (four asterisks) can be inserted instead of a value.&lt;br /&gt;
&lt;br /&gt;
Any worksheets that are not exportable 2DA data will have an underscore prepended to their name - the resource builder will subsequently ignore them.&lt;br /&gt;
&lt;br /&gt;
Worksheets need to have unique names among all excel files, duplicates will overwrite each other as each worksheet is exported as a file&lt;br /&gt;
&lt;br /&gt;
You cannot have the workbook open in Excel at the same time as running the binarizer on it.&lt;br /&gt;
&lt;br /&gt;
Strings have a maximum length of 768 characters. Anything longer will be truncated.&lt;br /&gt;
&lt;br /&gt;
== Extending the game via M2DAs ==&lt;br /&gt;
&lt;br /&gt;
An &amp;quot;M2DA&amp;quot; is a &amp;quot;Multiple 2DA&amp;quot; that stacks a number of 2DA files into one larger table. They work much like single 2DA files except they can be patched or expanded later by adding more resources. These are useful for any table that lists other resources, such as appearance tables, so that new resources can be added later without having to modify a monolithic table.&lt;br /&gt;
&lt;br /&gt;
This is especially important for third-party modders, since BioWare might release an update to a core table at a later date that would overwrite any changes third parties had made to it. By using an M2DA with a unique name, and by using a range of ID numbers significantly separated from those already in use, you can ensure that your additions won't conflict with other portions of the M2DA.&lt;br /&gt;
&lt;br /&gt;
A list of all M2DAs used by the game can be found in [[2DA_base.xls]]. Every 2da listed in M2DA_base is treated as a M2DA, except for those with an ID between 10000 and 10999 which are handled as regular 2DAs. Each M2DA has a label that describes the subject covered by the M2DA and a worksheet prefix that all components of that M2DA must use.&lt;br /&gt;
&lt;br /&gt;
Every worksheet listed in M2DA_base is actually a prefix. The system reads this prefix and then searches through all the 2DAs for the ones starting with this prefix and merges them together as one 2DA. For example: M2DA Id 0 is &amp;quot;ANIM_&amp;quot;. The system looks through its list of 2das and finds &amp;quot;ANIM_base&amp;quot;, &amp;quot;ANIM_combat&amp;quot; and &amp;quot;ANIM_walk&amp;quot;. It will read and merge all 3 2DAs into an M2DA called &amp;quot;ANIM_&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Not all of the prefixes end in an underscore. For example, longsword variations are in worksheets prefixed with &amp;quot;longsword_variation&amp;quot;, so both &amp;quot;longsword_variation_candyland&amp;quot; and &amp;quot;longsword_variationcandyland&amp;quot; would work as M2DA worksheet names.&lt;br /&gt;
&lt;br /&gt;
2DAs are merged row by row, keyed on the ID column. If two rows in two different 2DAs to be merged have the same ID, the row in the2da with the highest priority wins.&lt;br /&gt;
&lt;br /&gt;
== 2daExporter.xls ==&lt;br /&gt;
&lt;br /&gt;
To convert an XLS file into a 2DA usable by the game, another Excel file is used; &amp;lt;code&amp;gt;2daExporter.xls&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
[[Image:2DA exporter.png]]&lt;br /&gt;
&lt;br /&gt;
It has the following settings:&lt;br /&gt;
*ResourceBuild Path: The path to ResourceBuild.exe, which is installed by default in your Dragon Age directory under tools\ResourceBuild&lt;br /&gt;
*2DA Path: The source path of the XLS files to be exported. This is the root directory, you can specify subdirectories for each individual XLS file.&lt;br /&gt;
*Override Path: The path to the override directory that the completed 2DAs should be exported to.&lt;br /&gt;
*Debug Mode:&lt;br /&gt;
&lt;br /&gt;
Simply list the xls files you wish to convert, one to a line, and then click on the &amp;quot;Export Selected&amp;quot; button. The converted 2DAs will be exported to the specified override path. Remember that the 2DAs are generated from worksheets inside the xls files so converting one xls file can produce a number of different GDA files in the output directory.&lt;br /&gt;
&lt;br /&gt;
2daExporter.xls has been tested with Microsoft Excel, it has not been tested with other compatible spreadsheet programs. It may have trouble with paths that have spaces in their names (eg, &amp;quot;C:\My Documents&amp;quot;); if your export attempt fails try moving your working directories to a directory path with no spaces.&lt;br /&gt;
&lt;br /&gt;
== Adding 2DA export to the Windows XP file explorer ==&lt;br /&gt;
&lt;br /&gt;
Here's an easy way to add a context menu item that quickly converts new or updated Dragon Age Excel files into GDA format: &lt;br /&gt;
&lt;br /&gt;
Setup: &lt;br /&gt;
&lt;br /&gt;
# Open Windows Explorer and click Tools | Folder Options.&lt;br /&gt;
# In the File Types tab, select the XLS extension from the list and click the Advanced button.&lt;br /&gt;
# Click the New button and put 'Binarize 2DA' in the Action field.&lt;br /&gt;
# Paste the following in the Application field and click OK (update the drive and folder names to match your client): &amp;lt;tt&amp;gt;C:\DA\tag\main\ResourceBuild\Processors\ExcelProcessor.exe  &amp;quot;%l&amp;quot;  -outdir=C:\DA\tag\main\build\packages\core\override&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that paths with spaces in them can cause Windows trouble, if your paths have spaces in them remember to wrap them in quotation marks.&lt;br /&gt;
&lt;br /&gt;
Usage:&lt;br /&gt;
&lt;br /&gt;
# Using Windows Explorer, navigate to your 2DA folder (in my case C:\DA\tag\main\data\Source\2DA) and select the Excel file(s) to process. Right click and select 'Binarize 2DA' from the context menu. &lt;br /&gt;
# Confirm a corresponding GDA file is created in your override folder (in my case C:\DA\tag\main\build\packages\core\override) for each Excel file processed.&lt;br /&gt;
&lt;br /&gt;
== Step-by-Step ==&lt;br /&gt;
&lt;br /&gt;
If you have problems using the 2daExporter.xls spreadsheet to generate 2DAs the following method may work instead:&lt;br /&gt;
&lt;br /&gt;
*Create two folders called C:\2DA\ and C:\2DA\Override\&lt;br /&gt;
*Copy ExcelProcessor.exe to C:\2DA\&lt;br /&gt;
*Copy the Excel spreadsheets containing the 2DA you want to use in the game to C:\2DA\&lt;br /&gt;
*Create a batch file with the following line in it (change &amp;quot;placeables.xls&amp;quot; to whatever Excel file you're working with):&lt;br /&gt;
C:\2DA\ExcelProcessor.exe placeables.xls -outdir=C:\2DA\override\&lt;br /&gt;
*Run your batch file&lt;br /&gt;
*Find the GDA file from the C:\2DA\Override\ directory and copy it to the game's override directory. Remember to take into account the naming conventions of M2DAs; you may need to rename your 2DA files with a new suffix unique to your module to allow it to add to the core 2DAs without conflict.&lt;br /&gt;
&lt;br /&gt;
== 2DA XLS files used in Dragon Age ==&lt;br /&gt;
&lt;br /&gt;
''Note: This list is very incomplete right now''&lt;br /&gt;
&lt;br /&gt;
Bear in mind that 2DAs names are actually based on the names of the worksheets inside these Excel files, not the names of the files themselves. Some of these files contain a large number of individual 2DAs within them. They are bundled together into Excel files based on the nature of the 2DAs for convenience.&lt;br /&gt;
&lt;br /&gt;
=== Creatures ===&lt;br /&gt;
&lt;br /&gt;
*[[APR_base.xls]] - appearance types for creatures&lt;br /&gt;
*[[ABI_base.xls]] - integrates all talents and spells into the game&lt;br /&gt;
*[[ANIM_base.xls]]&lt;br /&gt;
*[[ANIM_combat.xls]]&lt;br /&gt;
*[[ANIM placeables.xls]]&lt;br /&gt;
*[[SyncAnimations.xls]]&lt;br /&gt;
*[[CLA_base.xls]] - Defines the character classes used throughout the game&lt;br /&gt;
*[[background.xls]] - defines the various origin stories available to each race and class.&lt;br /&gt;
&lt;br /&gt;
=== Objects ===&lt;br /&gt;
*[[placeables.xls]] - interactive object types&lt;br /&gt;
*[[BITM base.xls]] - item types&lt;br /&gt;
*[[ItemVariations.xls]] - item appearance variations (eg, all the different ways a longsword can look)&lt;br /&gt;
*[[PRJ_base.xls]] - how various projectiles look and behave&lt;br /&gt;
*[[VFX_base.xls]] - Visual effects&lt;br /&gt;
&lt;br /&gt;
=== Areas and plots ===&lt;br /&gt;
&lt;br /&gt;
*[[worldmaps.xls]] - world maps for open-ended travel between areas&lt;br /&gt;
*[[plottypes.xls]] - how plots are grouped at the highest level in the game GUI (codex entry types, story, etc.)&lt;br /&gt;
*[[areadata.xls]] - sets various properties for specific areas&lt;br /&gt;
*[[rewards.xls]] - rewards for plot completion&lt;br /&gt;
&lt;br /&gt;
=== Items ===&lt;br /&gt;
&lt;br /&gt;
*[[filename.xls]] - description.&lt;br /&gt;
&lt;br /&gt;
== Adding Strings ==&lt;br /&gt;
&lt;br /&gt;
When adding strings to a 2DA, you have two options.  The simplest is to enter **** for the StringID column.  In that case, the name column will be used in the game.&lt;br /&gt;
&lt;br /&gt;
The other approach is to use the toolset's string editor to create a new string.  When that happens, you'll get a new StringID.  Take that StringID and add 16777216 to the number.  Next enter that number into the StringID column in the 2DA.&lt;br /&gt;
&lt;br /&gt;
The second approach works better when translating your module, at the cost of portability.  If someone else wanted to reuse your 2DA, they'd have to generate their own strings, then update the StringID number based on these IDs.&lt;br /&gt;
&lt;br /&gt;
[[Category:2DAs]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=2DA&amp;diff=7601</id>
		<title>2DA</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=2DA&amp;diff=7601"/>
				<updated>2009-11-12T10:52:20Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Items */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Many of the properties of objects in the toolset make reference to 2DAs (two-dimensional arrays). These are read-only arrays containing various data used by scripting and the game engine. For example, the set of local variables that an object supports is defined in a 2DA.&lt;br /&gt;
&lt;br /&gt;
The source files for 2DAs are Microsoft Excel worksheets. This allows a wide variety of sophisticated techniques to be used to generate the values of the 2DA fields, such as macros and formulas. It also makes editing much easier since the columns can be annotated and formatted in helpful ways, and multiple related worksheets can be grouped into one file.&lt;br /&gt;
&lt;br /&gt;
Data in a 2DA is identified by a row number, with the first row (row zero) usually being reserved for internal use (undefined value, etc.) by convention. Each row has an arbitrary number of columns identified by strings. &lt;br /&gt;
&lt;br /&gt;
Before they can be used by the toolset or the game, 2DAs must be converted from Excel files into a more efficient form. Processed 2DAs are stored in files with the .[[GDA]] extension.&lt;br /&gt;
&lt;br /&gt;
== Excel file formatting ==&lt;br /&gt;
&lt;br /&gt;
Cell A1 will contain &amp;quot;ID&amp;quot;. This is checked by the processor and the worksheet will fail if this is not the case.&lt;br /&gt;
&lt;br /&gt;
Column A starting at line 3 will contain an integer row ID number that is unique to that row across all files (unless creating an M2DA override). Row IDs will be listed from smallest to highest within the same file and do not need to be consecutive.&lt;br /&gt;
&lt;br /&gt;
A blank row or column will determine the dimension of the spreadsheet in that direction. Everything past that point is ignored by the binarizer.&lt;br /&gt;
&lt;br /&gt;
Column names are case sensitive. This is because of the CRC32 algorithm used to generate the hash key. Changing the case of a column name after it is in use will break the game. White space before and after a column name will be removed before hashing.&lt;br /&gt;
&lt;br /&gt;
Row 2 will be a &amp;quot;types&amp;quot; row. Each is a single word: [[int]], [[string]] (single chars as well), [[resource]], [[float]] or [[bool]]. A special type &amp;quot;[[comment]]&amp;quot; can be used to exclude a column from export.&lt;br /&gt;
&lt;br /&gt;
Any column with string data that refers to files should have a type of &amp;quot;resource&amp;quot; and not &amp;quot;string&amp;quot;. This is because the &amp;quot;resource&amp;quot; type is used to determine dependencies for the 2DA file.&lt;br /&gt;
&lt;br /&gt;
'bool' type may be one of: a zero or non-zero number, Yes or No (case insensitive), or words beginning with T or F (such as True! and False!). NOTE: You cannot use TRUE and FALSE because Excel converts those to a special keyword the binarizer can't parse properly at this time. '''Note:''' the scripting language doesn't have a function for retrieving boolean values from a 2DA, and the behavior of Get2DAInt when retrieving a boolean is untested. It is probably safer to just use an integer for scripting purposes.&lt;br /&gt;
&lt;br /&gt;
If you wish to leave a cell unfilled, the string &amp;quot;****&amp;quot; (four asterisks) can be inserted instead of a value.&lt;br /&gt;
&lt;br /&gt;
Any worksheets that are not exportable 2DA data will have an underscore prepended to their name - the resource builder will subsequently ignore them.&lt;br /&gt;
&lt;br /&gt;
Worksheets need to have unique names among all excel files, duplicates will overwrite each other as each worksheet is exported as a file&lt;br /&gt;
&lt;br /&gt;
You cannot have the workbook open in Excel at the same time as running the binarizer on it.&lt;br /&gt;
&lt;br /&gt;
Strings have a maximum length of 768 characters. Anything longer will be truncated.&lt;br /&gt;
&lt;br /&gt;
== Extending the game via M2DAs ==&lt;br /&gt;
&lt;br /&gt;
An &amp;quot;M2DA&amp;quot; is a &amp;quot;Multiple 2DA&amp;quot; that stacks a number of 2DA files into one larger table. They work much like single 2DA files except they can be patched or expanded later by adding more resources. These are useful for any table that lists other resources, such as appearance tables, so that new resources can be added later without having to modify a monolithic table.&lt;br /&gt;
&lt;br /&gt;
This is especially important for third-party modders, since BioWare might release an update to a core table at a later date that would overwrite any changes third parties had made to it. By using an M2DA with a unique name, and by using a range of ID numbers significantly separated from those already in use, you can ensure that your additions won't conflict with other portions of the M2DA.&lt;br /&gt;
&lt;br /&gt;
A list of all M2DAs used by the game can be found in [[2DA_base.xls]]. Every 2da listed in M2DA_base is treated as a M2DA, except for those with an ID between 10000 and 10999 which are handled as regular 2DAs. Each M2DA has a label that describes the subject covered by the M2DA and a worksheet prefix that all components of that M2DA must use.&lt;br /&gt;
&lt;br /&gt;
Every worksheet listed in M2DA_base is actually a prefix. The system reads this prefix and then searches through all the 2DAs for the ones starting with this prefix and merges them together as one 2DA. For example: M2DA Id 0 is &amp;quot;ANIM_&amp;quot;. The system looks through its list of 2das and finds &amp;quot;ANIM_base&amp;quot;, &amp;quot;ANIM_combat&amp;quot; and &amp;quot;ANIM_walk&amp;quot;. It will read and merge all 3 2DAs into an M2DA called &amp;quot;ANIM_&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Not all of the prefixes end in an underscore. For example, longsword variations are in worksheets prefixed with &amp;quot;longsword_variation&amp;quot;, so both &amp;quot;longsword_variation_candyland&amp;quot; and &amp;quot;longsword_variationcandyland&amp;quot; would work as M2DA worksheet names.&lt;br /&gt;
&lt;br /&gt;
2DAs are merged row by row, keyed on the ID column. If two rows in two different 2DAs to be merged have the same ID, the row in the2da with the highest priority wins.&lt;br /&gt;
&lt;br /&gt;
== 2daExporter.xls ==&lt;br /&gt;
&lt;br /&gt;
To convert an XLS file into a 2DA usable by the game, another Excel file is used; &amp;lt;code&amp;gt;2daExporter.xls&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
[[Image:2DA exporter.png]]&lt;br /&gt;
&lt;br /&gt;
It has the following settings:&lt;br /&gt;
*ResourceBuild Path: The path to ResourceBuild.exe, which is installed by default in your Dragon Age directory under tools\ResourceBuild&lt;br /&gt;
*2DA Path: The source path of the XLS files to be exported. This is the root directory, you can specify subdirectories for each individual XLS file.&lt;br /&gt;
*Override Path: The path to the override directory that the completed 2DAs should be exported to.&lt;br /&gt;
*Debug Mode:&lt;br /&gt;
&lt;br /&gt;
Simply list the xls files you wish to convert, one to a line, and then click on the &amp;quot;Export Selected&amp;quot; button. The converted 2DAs will be exported to the specified override path. Remember that the 2DAs are generated from worksheets inside the xls files so converting one xls file can produce a number of different GDA files in the output directory.&lt;br /&gt;
&lt;br /&gt;
2daExporter.xls has been tested with Microsoft Excel, it has not been tested with other compatible spreadsheet programs. It may have trouble with paths that have spaces in their names (eg, &amp;quot;C:\My Documents&amp;quot;); if your export attempt fails try moving your working directories to a directory path with no spaces.&lt;br /&gt;
&lt;br /&gt;
== Adding 2DA export to the Windows XP file explorer ==&lt;br /&gt;
&lt;br /&gt;
Here's an easy way to add a context menu item that quickly converts new or updated Dragon Age Excel files into GDA format: &lt;br /&gt;
&lt;br /&gt;
Setup: &lt;br /&gt;
&lt;br /&gt;
# Open Windows Explorer and click Tools | Folder Options.&lt;br /&gt;
# In the File Types tab, select the XLS extension from the list and click the Advanced button.&lt;br /&gt;
# Click the New button and put 'Binarize 2DA' in the Action field.&lt;br /&gt;
# Paste the following in the Application field and click OK (update the drive and folder names to match your client): &amp;lt;tt&amp;gt;C:\DA\tag\main\ResourceBuild\Processors\ExcelProcessor.exe  &amp;quot;%l&amp;quot;  -outdir=C:\DA\tag\main\build\packages\core\override&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that paths with spaces in them can cause Windows trouble, if your paths have spaces in them remember to wrap them in quotation marks.&lt;br /&gt;
&lt;br /&gt;
Usage:&lt;br /&gt;
&lt;br /&gt;
# Using Windows Explorer, navigate to your 2DA folder (in my case C:\DA\tag\main\data\Source\2DA) and select the Excel file(s) to process. Right click and select 'Binarize 2DA' from the context menu. &lt;br /&gt;
# Confirm a corresponding GDA file is created in your override folder (in my case C:\DA\tag\main\build\packages\core\override) for each Excel file processed.&lt;br /&gt;
&lt;br /&gt;
== Step-by-Step ==&lt;br /&gt;
&lt;br /&gt;
If you have problems using the 2daExporter.xls spreadsheet to generate 2DAs the following method may work instead:&lt;br /&gt;
&lt;br /&gt;
*Create two folders called C:\2DA\ and C:\2DA\Override\&lt;br /&gt;
*Copy ExcelProcessor.exe to C:\2DA\&lt;br /&gt;
*Copy the Excel spreadsheets containing the 2DA you want to use in the game to C:\2DA\&lt;br /&gt;
*Create a batch file with the following line in it (change &amp;quot;placeables.xls&amp;quot; to whatever Excel file you're working with):&lt;br /&gt;
C:\2DA\ExcelProcessor.exe placeables.xls -outdir=C:\2DA\override\&lt;br /&gt;
*Run your batch file&lt;br /&gt;
*Find the GDA file from the C:\2DA\Override\ directory and copy it to the game's override directory. Remember to take into account the naming conventions of M2DAs; you may need to rename your 2DA files with a new suffix unique to your module to allow it to add to the core 2DAs without conflict.&lt;br /&gt;
&lt;br /&gt;
== 2DA XLS files used in Dragon Age ==&lt;br /&gt;
&lt;br /&gt;
''Note: This list is very incomplete right now''&lt;br /&gt;
&lt;br /&gt;
Bear in mind that 2DAs names are actually based on the names of the worksheets inside these Excel files, not the names of the files themselves. Some of these files contain a large number of individual 2DAs within them. They are bundled together into Excel files based on the nature of the 2DAs for convenience.&lt;br /&gt;
&lt;br /&gt;
=== Creatures ===&lt;br /&gt;
&lt;br /&gt;
*[[APR_base.xls]] - appearance types for creatures&lt;br /&gt;
*[[ABI_base.xls]] - integrates all talents and spells into the game&lt;br /&gt;
*[[ANIM_base.xls]]&lt;br /&gt;
*[[ANIM_combat.xls]]&lt;br /&gt;
*[[ANIM placeables.xls]]&lt;br /&gt;
*[[SyncAnimations.xls]]&lt;br /&gt;
*[[CLA_base.xls]] - Defines the character classes used throughout the game&lt;br /&gt;
*[[background.xls]] - defines the various origin stories available to each race and class.&lt;br /&gt;
&lt;br /&gt;
=== Objects ===&lt;br /&gt;
*[[placeables.xls]] - interactive object types&lt;br /&gt;
*[[BITM base.xls]] - item types&lt;br /&gt;
*[[ItemVariations.xls]] - item appearance variations (eg, all the different ways a longsword can look)&lt;br /&gt;
*[[PRJ_base.xls]] - how various projectiles look and behave&lt;br /&gt;
*[[VFX_base.xls]] - Visual effects&lt;br /&gt;
&lt;br /&gt;
=== Areas and plots ===&lt;br /&gt;
&lt;br /&gt;
*[[worldmaps.xls]] - world maps for open-ended travel between areas&lt;br /&gt;
*[[plottypes.xls]] - how plots are grouped at the highest level in the game GUI (codex entry types, story, etc.)&lt;br /&gt;
*[[areadata.xls]] - sets various properties for specific areas&lt;br /&gt;
*[[rewards.xls]] - rewards for plot completion&lt;br /&gt;
&lt;br /&gt;
=== Items ===&lt;br /&gt;
&lt;br /&gt;
*[[ ]] -&lt;br /&gt;
&lt;br /&gt;
== Adding Strings ==&lt;br /&gt;
&lt;br /&gt;
When adding strings to a 2DA, you have two options.  The simplest is to enter **** for the StringID column.  In that case, the name column will be used in the game.&lt;br /&gt;
&lt;br /&gt;
The other approach is to use the toolset's string editor to create a new string.  When that happens, you'll get a new StringID.  Take that StringID and add 16777216 to the number.  Next enter that number into the StringID column in the 2DA.&lt;br /&gt;
&lt;br /&gt;
The second approach works better when translating your module, at the cost of portability.  If someone else wanted to reuse your 2DA, they'd have to generate their own strings, then update the StringID number based on these IDs.&lt;br /&gt;
&lt;br /&gt;
[[Category:2DAs]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=2DA&amp;diff=7600</id>
		<title>2DA</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=2DA&amp;diff=7600"/>
				<updated>2009-11-12T10:51:42Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: added new empty subsection for item xls files.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Many of the properties of objects in the toolset make reference to 2DAs (two-dimensional arrays). These are read-only arrays containing various data used by scripting and the game engine. For example, the set of local variables that an object supports is defined in a 2DA.&lt;br /&gt;
&lt;br /&gt;
The source files for 2DAs are Microsoft Excel worksheets. This allows a wide variety of sophisticated techniques to be used to generate the values of the 2DA fields, such as macros and formulas. It also makes editing much easier since the columns can be annotated and formatted in helpful ways, and multiple related worksheets can be grouped into one file.&lt;br /&gt;
&lt;br /&gt;
Data in a 2DA is identified by a row number, with the first row (row zero) usually being reserved for internal use (undefined value, etc.) by convention. Each row has an arbitrary number of columns identified by strings. &lt;br /&gt;
&lt;br /&gt;
Before they can be used by the toolset or the game, 2DAs must be converted from Excel files into a more efficient form. Processed 2DAs are stored in files with the .[[GDA]] extension.&lt;br /&gt;
&lt;br /&gt;
== Excel file formatting ==&lt;br /&gt;
&lt;br /&gt;
Cell A1 will contain &amp;quot;ID&amp;quot;. This is checked by the processor and the worksheet will fail if this is not the case.&lt;br /&gt;
&lt;br /&gt;
Column A starting at line 3 will contain an integer row ID number that is unique to that row across all files (unless creating an M2DA override). Row IDs will be listed from smallest to highest within the same file and do not need to be consecutive.&lt;br /&gt;
&lt;br /&gt;
A blank row or column will determine the dimension of the spreadsheet in that direction. Everything past that point is ignored by the binarizer.&lt;br /&gt;
&lt;br /&gt;
Column names are case sensitive. This is because of the CRC32 algorithm used to generate the hash key. Changing the case of a column name after it is in use will break the game. White space before and after a column name will be removed before hashing.&lt;br /&gt;
&lt;br /&gt;
Row 2 will be a &amp;quot;types&amp;quot; row. Each is a single word: [[int]], [[string]] (single chars as well), [[resource]], [[float]] or [[bool]]. A special type &amp;quot;[[comment]]&amp;quot; can be used to exclude a column from export.&lt;br /&gt;
&lt;br /&gt;
Any column with string data that refers to files should have a type of &amp;quot;resource&amp;quot; and not &amp;quot;string&amp;quot;. This is because the &amp;quot;resource&amp;quot; type is used to determine dependencies for the 2DA file.&lt;br /&gt;
&lt;br /&gt;
'bool' type may be one of: a zero or non-zero number, Yes or No (case insensitive), or words beginning with T or F (such as True! and False!). NOTE: You cannot use TRUE and FALSE because Excel converts those to a special keyword the binarizer can't parse properly at this time. '''Note:''' the scripting language doesn't have a function for retrieving boolean values from a 2DA, and the behavior of Get2DAInt when retrieving a boolean is untested. It is probably safer to just use an integer for scripting purposes.&lt;br /&gt;
&lt;br /&gt;
If you wish to leave a cell unfilled, the string &amp;quot;****&amp;quot; (four asterisks) can be inserted instead of a value.&lt;br /&gt;
&lt;br /&gt;
Any worksheets that are not exportable 2DA data will have an underscore prepended to their name - the resource builder will subsequently ignore them.&lt;br /&gt;
&lt;br /&gt;
Worksheets need to have unique names among all excel files, duplicates will overwrite each other as each worksheet is exported as a file&lt;br /&gt;
&lt;br /&gt;
You cannot have the workbook open in Excel at the same time as running the binarizer on it.&lt;br /&gt;
&lt;br /&gt;
Strings have a maximum length of 768 characters. Anything longer will be truncated.&lt;br /&gt;
&lt;br /&gt;
== Extending the game via M2DAs ==&lt;br /&gt;
&lt;br /&gt;
An &amp;quot;M2DA&amp;quot; is a &amp;quot;Multiple 2DA&amp;quot; that stacks a number of 2DA files into one larger table. They work much like single 2DA files except they can be patched or expanded later by adding more resources. These are useful for any table that lists other resources, such as appearance tables, so that new resources can be added later without having to modify a monolithic table.&lt;br /&gt;
&lt;br /&gt;
This is especially important for third-party modders, since BioWare might release an update to a core table at a later date that would overwrite any changes third parties had made to it. By using an M2DA with a unique name, and by using a range of ID numbers significantly separated from those already in use, you can ensure that your additions won't conflict with other portions of the M2DA.&lt;br /&gt;
&lt;br /&gt;
A list of all M2DAs used by the game can be found in [[2DA_base.xls]]. Every 2da listed in M2DA_base is treated as a M2DA, except for those with an ID between 10000 and 10999 which are handled as regular 2DAs. Each M2DA has a label that describes the subject covered by the M2DA and a worksheet prefix that all components of that M2DA must use.&lt;br /&gt;
&lt;br /&gt;
Every worksheet listed in M2DA_base is actually a prefix. The system reads this prefix and then searches through all the 2DAs for the ones starting with this prefix and merges them together as one 2DA. For example: M2DA Id 0 is &amp;quot;ANIM_&amp;quot;. The system looks through its list of 2das and finds &amp;quot;ANIM_base&amp;quot;, &amp;quot;ANIM_combat&amp;quot; and &amp;quot;ANIM_walk&amp;quot;. It will read and merge all 3 2DAs into an M2DA called &amp;quot;ANIM_&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Not all of the prefixes end in an underscore. For example, longsword variations are in worksheets prefixed with &amp;quot;longsword_variation&amp;quot;, so both &amp;quot;longsword_variation_candyland&amp;quot; and &amp;quot;longsword_variationcandyland&amp;quot; would work as M2DA worksheet names.&lt;br /&gt;
&lt;br /&gt;
2DAs are merged row by row, keyed on the ID column. If two rows in two different 2DAs to be merged have the same ID, the row in the2da with the highest priority wins.&lt;br /&gt;
&lt;br /&gt;
== 2daExporter.xls ==&lt;br /&gt;
&lt;br /&gt;
To convert an XLS file into a 2DA usable by the game, another Excel file is used; &amp;lt;code&amp;gt;2daExporter.xls&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
[[Image:2DA exporter.png]]&lt;br /&gt;
&lt;br /&gt;
It has the following settings:&lt;br /&gt;
*ResourceBuild Path: The path to ResourceBuild.exe, which is installed by default in your Dragon Age directory under tools\ResourceBuild&lt;br /&gt;
*2DA Path: The source path of the XLS files to be exported. This is the root directory, you can specify subdirectories for each individual XLS file.&lt;br /&gt;
*Override Path: The path to the override directory that the completed 2DAs should be exported to.&lt;br /&gt;
*Debug Mode:&lt;br /&gt;
&lt;br /&gt;
Simply list the xls files you wish to convert, one to a line, and then click on the &amp;quot;Export Selected&amp;quot; button. The converted 2DAs will be exported to the specified override path. Remember that the 2DAs are generated from worksheets inside the xls files so converting one xls file can produce a number of different GDA files in the output directory.&lt;br /&gt;
&lt;br /&gt;
2daExporter.xls has been tested with Microsoft Excel, it has not been tested with other compatible spreadsheet programs. It may have trouble with paths that have spaces in their names (eg, &amp;quot;C:\My Documents&amp;quot;); if your export attempt fails try moving your working directories to a directory path with no spaces.&lt;br /&gt;
&lt;br /&gt;
== Adding 2DA export to the Windows XP file explorer ==&lt;br /&gt;
&lt;br /&gt;
Here's an easy way to add a context menu item that quickly converts new or updated Dragon Age Excel files into GDA format: &lt;br /&gt;
&lt;br /&gt;
Setup: &lt;br /&gt;
&lt;br /&gt;
# Open Windows Explorer and click Tools | Folder Options.&lt;br /&gt;
# In the File Types tab, select the XLS extension from the list and click the Advanced button.&lt;br /&gt;
# Click the New button and put 'Binarize 2DA' in the Action field.&lt;br /&gt;
# Paste the following in the Application field and click OK (update the drive and folder names to match your client): &amp;lt;tt&amp;gt;C:\DA\tag\main\ResourceBuild\Processors\ExcelProcessor.exe  &amp;quot;%l&amp;quot;  -outdir=C:\DA\tag\main\build\packages\core\override&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that paths with spaces in them can cause Windows trouble, if your paths have spaces in them remember to wrap them in quotation marks.&lt;br /&gt;
&lt;br /&gt;
Usage:&lt;br /&gt;
&lt;br /&gt;
# Using Windows Explorer, navigate to your 2DA folder (in my case C:\DA\tag\main\data\Source\2DA) and select the Excel file(s) to process. Right click and select 'Binarize 2DA' from the context menu. &lt;br /&gt;
# Confirm a corresponding GDA file is created in your override folder (in my case C:\DA\tag\main\build\packages\core\override) for each Excel file processed.&lt;br /&gt;
&lt;br /&gt;
== Step-by-Step ==&lt;br /&gt;
&lt;br /&gt;
If you have problems using the 2daExporter.xls spreadsheet to generate 2DAs the following method may work instead:&lt;br /&gt;
&lt;br /&gt;
*Create two folders called C:\2DA\ and C:\2DA\Override\&lt;br /&gt;
*Copy ExcelProcessor.exe to C:\2DA\&lt;br /&gt;
*Copy the Excel spreadsheets containing the 2DA you want to use in the game to C:\2DA\&lt;br /&gt;
*Create a batch file with the following line in it (change &amp;quot;placeables.xls&amp;quot; to whatever Excel file you're working with):&lt;br /&gt;
C:\2DA\ExcelProcessor.exe placeables.xls -outdir=C:\2DA\override\&lt;br /&gt;
*Run your batch file&lt;br /&gt;
*Find the GDA file from the C:\2DA\Override\ directory and copy it to the game's override directory. Remember to take into account the naming conventions of M2DAs; you may need to rename your 2DA files with a new suffix unique to your module to allow it to add to the core 2DAs without conflict.&lt;br /&gt;
&lt;br /&gt;
== 2DA XLS files used in Dragon Age ==&lt;br /&gt;
&lt;br /&gt;
''Note: This list is very incomplete right now''&lt;br /&gt;
&lt;br /&gt;
Bear in mind that 2DAs names are actually based on the names of the worksheets inside these Excel files, not the names of the files themselves. Some of these files contain a large number of individual 2DAs within them. They are bundled together into Excel files based on the nature of the 2DAs for convenience.&lt;br /&gt;
&lt;br /&gt;
=== Creatures ===&lt;br /&gt;
&lt;br /&gt;
*[[APR_base.xls]] - appearance types for creatures&lt;br /&gt;
*[[ABI_base.xls]] - integrates all talents and spells into the game&lt;br /&gt;
*[[ANIM_base.xls]]&lt;br /&gt;
*[[ANIM_combat.xls]]&lt;br /&gt;
*[[ANIM placeables.xls]]&lt;br /&gt;
*[[SyncAnimations.xls]]&lt;br /&gt;
*[[CLA_base.xls]] - Defines the character classes used throughout the game&lt;br /&gt;
*[[background.xls]] - defines the various origin stories available to each race and class.&lt;br /&gt;
&lt;br /&gt;
=== Objects ===&lt;br /&gt;
*[[placeables.xls]] - interactive object types&lt;br /&gt;
*[[BITM base.xls]] - item types&lt;br /&gt;
*[[ItemVariations.xls]] - item appearance variations (eg, all the different ways a longsword can look)&lt;br /&gt;
*[[PRJ_base.xls]] - how various projectiles look and behave&lt;br /&gt;
*[[VFX_base.xls]] - Visual effects&lt;br /&gt;
&lt;br /&gt;
=== Areas and plots ===&lt;br /&gt;
&lt;br /&gt;
*[[worldmaps.xls]] - world maps for open-ended travel between areas&lt;br /&gt;
*[[plottypes.xls]] - how plots are grouped at the highest level in the game GUI (codex entry types, story, etc.)&lt;br /&gt;
*[[areadata.xls]] - sets various properties for specific areas&lt;br /&gt;
*[[rewards.xls]] - rewards for plot completion&lt;br /&gt;
&lt;br /&gt;
=== Items ===&lt;br /&gt;
&lt;br /&gt;
*[[]] - &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Adding Strings ==&lt;br /&gt;
&lt;br /&gt;
When adding strings to a 2DA, you have two options.  The simplest is to enter **** for the StringID column.  In that case, the name column will be used in the game.&lt;br /&gt;
&lt;br /&gt;
The other approach is to use the toolset's string editor to create a new string.  When that happens, you'll get a new StringID.  Take that StringID and add 16777216 to the number.  Next enter that number into the StringID column in the 2DA.&lt;br /&gt;
&lt;br /&gt;
The second approach works better when translating your module, at the cost of portability.  If someone else wanted to reuse your 2DA, they'd have to generate their own strings, then update the StringID number based on these IDs.&lt;br /&gt;
&lt;br /&gt;
[[Category:2DAs]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=GetEffectsFlags&amp;diff=7599</id>
		<title>GetEffectsFlags</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=GetEffectsFlags&amp;diff=7599"/>
				<updated>2009-11-12T10:40:21Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Description */ speeling&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Generated with errors}}&lt;br /&gt;
{{dafunction&lt;br /&gt;
|name=GetEffectsFlags&lt;br /&gt;
|brief=Returns the effect flags on a given object.&lt;br /&gt;
|param1type=object&lt;br /&gt;
|param1name=oOwner&lt;br /&gt;
|param1desc=The object that contains effects&lt;br /&gt;
|returntype=int&lt;br /&gt;
|returndesc=&lt;br /&gt;
|sourcefile=script.ldf&lt;br /&gt;
|sourcemodule=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&amp;lt;!-- This section contains the full description from the functions comments. Do not change unless you are confident these are incomplete or incorrect. --&amp;gt;&lt;br /&gt;
Effects can set effect flags. This function returns&lt;br /&gt;
an integer that contains all the effect flags on an object&lt;br /&gt;
due to the effects it currently holds.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- == Remarks == --&amp;gt;&lt;br /&gt;
&amp;lt;!-- This section contains additional comments, observations and known issues. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- == Examples == --&amp;gt;&lt;br /&gt;
&amp;lt;!-- This section contains examples transcluded from the snippet library. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- == See also == --&amp;gt;&lt;br /&gt;
&amp;lt;!-- This section contains links to articles, functions or constant groups. --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category: Effect access functions]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Placeable&amp;diff=7375</id>
		<title>Placeable</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Placeable&amp;diff=7375"/>
				<updated>2009-11-01T01:02:09Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Locked Objects */ reorganized paragraphs&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Interactive Objects are the objects placed in the designer toolset that the end-user can interact with. They are also known as placeable objects.&lt;br /&gt;
&lt;br /&gt;
Designers place interactive objects in area using the Area Editor.  Placeable and trigger templates must be created prior to being placed in an area.  In the toolset, doors are considered to be just another form of placeables.&lt;br /&gt;
&lt;br /&gt;
Interactive objects are placed in the Area Editor of the Designer toolest. They can be interacted with by the player in-game.&lt;br /&gt;
&lt;br /&gt;
Like all objects, interactive objects receive only one [[event]]. Information encoded in this event can be used to determine if this is a default action or a secondary action (for example, determining whether the player is picking the placeable's lock or simply bashing it open).&lt;br /&gt;
&lt;br /&gt;
== Locked Objects ==&lt;br /&gt;
&lt;br /&gt;
Any interactive object can be locked (though generally it only makes sense to do so with containers and doors). If the character's lockpicking skill is higher than the lock, the lock is opened.&lt;br /&gt;
&lt;br /&gt;
Interactive objects cannot be trapped in the manner that Neverwinter objects were trapped (i.e., no trapped chests or doors). Instead, a placeable object can be set as the trigger for an associated trap object; Dragon Age generally does this via floor plates that trigger when stepped on.&lt;br /&gt;
&lt;br /&gt;
== Destroying Objects ==&lt;br /&gt;
&lt;br /&gt;
All interactive objects need a destroyed animation. If a container is destroyed the contents of its inventory are transferred to a Bodybag. Some of the items may be destroyed (scripting determines the chance of this).&lt;br /&gt;
&lt;br /&gt;
== Types of Interactive Objects ==&lt;br /&gt;
&lt;br /&gt;
The function that a placeable performs when interacted with is defined by its appearance, as listed in [[Placeables.xls]].&lt;br /&gt;
&lt;br /&gt;
=== Doors ===&lt;br /&gt;
Doors can be opened and closed by the player. They restrict access between portions of an area.&lt;br /&gt;
* Examples: Door, Cage Door, Secret door&lt;br /&gt;
* Default Action: When a character clicks on the door it opens with an animation.&lt;br /&gt;
* Secondary Action: The character attacks the door with his equipped weapon&lt;br /&gt;
* Doors are special and get [[Door|their own page]] describing additional details.&lt;br /&gt;
=== Trigger-Animating ===&lt;br /&gt;
These are items that a player clicks on to activate something elsewhere on a level. Usually this means a locked or secret door somewhere on the level, though sometimes it might summon a monster or sound the alarm for the entire level.&lt;br /&gt;
* Examples: Lever, gong, turning wheel.  &lt;br /&gt;
* Default Action: When a character clicks on the object, it plays an animation and an effect. The effect can be a script, a sound, a spell or a combination.  &lt;br /&gt;
* Secondary Action: The character attacks the object with his equipped weapon.&lt;br /&gt;
=== Container-Animating ===&lt;br /&gt;
These are common containers where a player can find treasure. These objects play a simple ‘open’ animation when left clicked. &lt;br /&gt;
* Examples: Chest, Armoire, Safe.  &lt;br /&gt;
* Default Action: An open animation is played. The container’s inventory is shown on a GUI. If the container is locked, then the character’s lock picking skill is compared against the lock’s complexity.  &lt;br /&gt;
* Secondary Action: The character attacks the container with his equipped weapon.&lt;br /&gt;
=== Container-Static ===&lt;br /&gt;
These are common containers where a player can find treasure. These containers have no ‘open’ animation.  &lt;br /&gt;
* Examples: Bookshelf, bush (with material components), corpse.  &lt;br /&gt;
* Default Action: The container’s inventory is shown on a GUI. Static containers cannot be locked.  &lt;br /&gt;
* Secondary Action: The character attacks the container with his equipped weapon.&lt;br /&gt;
=== Cage ===&lt;br /&gt;
These are cages where animals or prisoners are kept. Players can release prisoners as an act of good will or simply to interrogate them for information. Animals can be released to act as temporary allies.  &lt;br /&gt;
*Examples: Animal cage, gaol.  &lt;br /&gt;
*Default Action: An open animation is played. If the cage is locked, then the character’s lock picking skill is compared against the lock’s complexity.  &lt;br /&gt;
*Secondary Action: The character attacks the cage with his equipped weapon.&lt;br /&gt;
=== Informational ===&lt;br /&gt;
These are notes or signs that a player can click on to learn important information about the game. They range from simply location signs to notes giving information about a plot. &lt;br /&gt;
*Examples: Road sign, note on wall.  &lt;br /&gt;
*Default Action: A GUI pops up displaying the text of the message.  &lt;br /&gt;
*Secondary Action: Nothing happens.&lt;br /&gt;
=== Selectable Trap ===&lt;br /&gt;
These are traps that originate from visible (and thus selectable and destroyable) objects. They can also can be disarmed by disarming their floor trigger - i.e., sinking floor piece - (see Trap Triggers). &lt;br /&gt;
*Examples: Archer statue that fires arrows (after player steps on floor piece). Dragon statue that breathes fire(after player steps on floor piece).   &lt;br /&gt;
*Default Action: Trap triggers, targeting the character that selected it.  &lt;br /&gt;
*Secondary Action: The character attacks the trap with his equipped weapon.&lt;br /&gt;
=== Non-Selectable Trap ===&lt;br /&gt;
These are hidden traps that spring from the walls, floor or ceiling. These traps cannot be selected or destroyed directly BUT they can be disarmed by disarming their floor trigger - i.e., sinking floor piece - (see Trap Triggers). &lt;br /&gt;
*Examples: Pendulum blade, scything blade.   &lt;br /&gt;
*Default Action: Cannot target trap.  &lt;br /&gt;
*Secondary Action: Cannot target trap.&lt;br /&gt;
=== Trap Trigger ===&lt;br /&gt;
All traps need to be associated with a floor trigger. When a character walks over a floor trigger, the trap will activate. If two or more characters are selected, the one with the highest trap skill is the one that moves to disarm the trap.&lt;br /&gt;
*Examples: Sinking floor piece.   &lt;br /&gt;
*Default Action: If the character has the ‘Traps’ skill, then he plays a ‘disarm’ animation and his skill is compared against the difficulty of the trap. Characters without the traps skill cannot select the trap trigger.   &lt;br /&gt;
*Secondary Action: The character attacks the trigger with his equipped weapon. This triggers the trap.&lt;br /&gt;
=== Area Effect Item/Informational ===&lt;br /&gt;
These are objects that a character can attack, triggering an event that has an immediate effect on the battlefield. When a character attacks one of these objects, the object usually falls over and deals damage to any creature in its area of effect. If a player just left clicks on one of these objects, he will receive a text message.   &lt;br /&gt;
*Examples: Weakened pillar (pillar collapses into rubble), old rotting tree (tree falls over), chandelier (rope is cut, chandelier smashes into floor and vanishes), marble statue (statue tips over), window (window smashes, leaving glass all over floor), boulder (rolls along preset path).   &lt;br /&gt;
*Default Action: A GUI pops up displaying the text of a message.   &lt;br /&gt;
*Secondary Action: The character attacks the trigger with his equipped weapon. If the player has the appropriate strength, then the item plays its ‘area effect damage’ animation.&lt;br /&gt;
=== Area Effect Item/Container ===&lt;br /&gt;
These These are objects that a character can attack, triggering an event that has an immediate effect on the battlefield. When a character attacks one of these objects, the object usually falls over and deals damage to any creature in its area of effect. If a player just left clicks on one of these objects, it will act as a container.   &lt;br /&gt;
*Examples: Bag of flour (explodes into cloud of flour), wagon with barrels (wagon tips and barrels spill over floor), bookcase (bookcase tips over).   &lt;br /&gt;
*Default Action: The container’s inventory is shown on a GUI.   &lt;br /&gt;
*Secondary Action: The character attacks the trigger with his equipped weapon. If the player has the appropriate strength, then the item plays its ‘area effect damage’ animation.&lt;br /&gt;
=== Furniture ===&lt;br /&gt;
Characters can either sit down or lie down on these objects. &lt;br /&gt;
*Examples: Chair, couch, bed, bench.   &lt;br /&gt;
*Default Action: The character either sits down or lies down on the furniture object. As soon as the player clicks to move, he will stand up.  &lt;br /&gt;
*Secondary Action: The character attacks the object with his equipped weapon.&lt;br /&gt;
=== Puzzle ===&lt;br /&gt;
The player clicks and triggers an interactive dialog with the object &lt;br /&gt;
*Examples: any puzzle object.   &lt;br /&gt;
*Default Action: Trigger dialog.  &lt;br /&gt;
*Secondary Action: The character attacks the object with his equipped weapon.&lt;br /&gt;
=== Area Transition ===&lt;br /&gt;
These are visible or invisible objects used to transition between areas.&lt;br /&gt;
*Examples: Large Gate  &lt;br /&gt;
*Default Action: Transition into destination area.  &lt;br /&gt;
*Secondary Action: Nothing happens.&lt;br /&gt;
&lt;br /&gt;
== How will designers assign appearances to interactive objects? ==&lt;br /&gt;
*This will be done through the Toolset appearance field. It refers placeables.2da&lt;br /&gt;
*Each placeable has a Type.&lt;br /&gt;
*Each TYPE corresponds to an Animation State Type (example, the AnimCnt_Door sheet in placeables.2da controls the door states). This controls the type of animations available to this object. There should be 10-15 types or so&lt;br /&gt;
**Death&lt;br /&gt;
**Damaged&lt;br /&gt;
**Normal State&lt;br /&gt;
**Others...&lt;br /&gt;
*Each Animation State Type refers to a list of animations in the Animations 2da ([[ANIM_Placeables.xls]])&lt;br /&gt;
&lt;br /&gt;
== How will battle-field damage work? ==&lt;br /&gt;
*Interactive Objects will not have DECALS or BATTLE-SCARING. &lt;br /&gt;
*Interactive Objects will have a Damage state, in addition to the Death state that they all have. Example damage states:&lt;br /&gt;
**A chest might have a chunk of wood taken out of its front&lt;br /&gt;
**A cask of ale might start leaking ale&lt;br /&gt;
&lt;br /&gt;
== Use Points ==&lt;br /&gt;
Objects will have use points to indicate where people using them stand. There will be multiple use points on an object.&lt;br /&gt;
&lt;br /&gt;
Use points will need to be activated relative to what state they are in (i.e., an overturned pillar will have different action points than an upright pillar).&lt;br /&gt;
&lt;br /&gt;
Use points may also need to be labeled and are activated relative to a players position. This seems likely how are doors will work. Since we decided that doors in Dragon Age will function like real-world doors, they will always open in the same direction every time. This means that the use point I use is NOT relative to the state, but instead to the position of the character. We might need use points labeled.&lt;br /&gt;
&lt;br /&gt;
This system will probably also be used by creatures (a dragon might have Front-Claw Use Point, Tail Use Point et cetera)&lt;br /&gt;
&lt;br /&gt;
== How Will Sitting and Sleeping Work? ==&lt;br /&gt;
* All things that can be sat on will need a consistent Height and Width&lt;br /&gt;
* All things that can be slept on will need a consistent Height and Width&lt;br /&gt;
* Animals will not be able to sit or sleep on anything&lt;br /&gt;
* Animation will create sit &amp;amp; sleep animations for Elves, Dwarves, Humans&lt;br /&gt;
* The player can’t sit —  only ambient NPCs.&lt;br /&gt;
&lt;br /&gt;
The current planned interactive object animation system should be able to handle the &amp;quot;sitting&amp;quot; and &amp;quot;lying down&amp;quot;  of creatures.&lt;br /&gt;
&lt;br /&gt;
== What happens if no animations exist for an action? ==&lt;br /&gt;
Example: E.g A creature uses an object for which there is no proper animation, like a Dog opens a chest.&lt;br /&gt;
&lt;br /&gt;
The chest will still open but if no animations were created to show Dog opening the chest, none will play.&lt;br /&gt;
&lt;br /&gt;
== Variables ==&lt;br /&gt;
&lt;br /&gt;
For var_placeable:&lt;br /&gt;
&lt;br /&gt;
{{variable table start}}&lt;br /&gt;
{{variable table row| PLC_AT_DEST_AREA_TAG | string |none| resource name of an area transition door's destination area}}&lt;br /&gt;
{{variable table row| PLC_AT_DEST_TAG | string |none| resource name of the waypoint within that area to send the PC to. }}&lt;br /&gt;
{{variable table row|PLC_AT_WORLD_MAP_ACTIVE_1 to 5 | string |none| resource name of pins on the world map that should be made active when the player uses this area transition to reach the world map. }}&lt;br /&gt;
{{variable table row|PLC_CODEX_FLAG | int | -1 | Flag within the CODEX_PLOT plot that is set when this placeable is examined. }}&lt;br /&gt;
{{variable table row|PLC_CODEX_PLOT | string |none| resource name of a plot containing a codex page that is given to the player when this placeable is examined. }}&lt;br /&gt;
{{variable table row|PLC_COUNTER_1 to 3 | int |0| generic counter variables }}&lt;br /&gt;
{{variable table row|PLC_DO_ONCE_A and B | int |0| flags for behaviors that happen only once }}&lt;br /&gt;
{{variable table row|PLC_FLIP_COVER_USE_COUNT | int |0| Flip cover has been removed from the default ruleset }}&lt;br /&gt;
{{variable table row|PLC_SPAWN_NON_INTERACTIVE | int |0| }}&lt;br /&gt;
{{variable table row|PLC_TRAP_* | || see [[Trap system]] }}&lt;br /&gt;
{{variable table row|TS_OVERRIDE_* | || See [[Treasure system]] }}&lt;br /&gt;
{{variable table row|TS_TREASURE_GENERATED | int || }}&lt;br /&gt;
{{variable table end}}&lt;br /&gt;
&lt;br /&gt;
If you use the var_placeable_react 2da instead, the above variables are all included and the following are added:&lt;br /&gt;
&lt;br /&gt;
{{variable table start}}&lt;br /&gt;
{{variable table row|PLC_REACT_DESTROY_SET_FLAG | int || When placeable is destroyed set this flag }}&lt;br /&gt;
{{variable table row|PLC_REACT_DESTROY_SET_PLOT | string ||  When placeable is destroyed set this plot}}&lt;br /&gt;
{{variable table row|PLC_REACT_INVENTORY_REMOVED_SET_FLAG | int || When the PC takes something from the placeable fire this flag}}&lt;br /&gt;
{{variable table row|PLC_REACT_INVENTORY_REMOVED_SET_PLOT | string || When the PC takes something from the placeable fire this plot}}&lt;br /&gt;
{{variable table row|PLC_REACT_OVERRIDE_USE_BEHAVIOR | int |0| Makes it so what's supposed to happen when you use the placeable doesn't happen (e.g. a door doesn't open)}}&lt;br /&gt;
{{variable table row|PLC_REACT_REPEAT | int | 1 | Whether or not the placeable reaction script will fire multiple times (default to TRUE)}}&lt;br /&gt;
{{variable table row|PLC_REACT_USE_SET_FLAG | int |0| When placeable is used fire this flag}}&lt;br /&gt;
{{variable table row|PLC_REACT_USE_SET_PLOT | string || When placeable is used fire this plot}}&lt;br /&gt;
{{variable table end}}&lt;br /&gt;
&lt;br /&gt;
== Properties ==&lt;br /&gt;
&lt;br /&gt;
{{inspector start}}&lt;br /&gt;
{{inspector section|General}}&lt;br /&gt;
{{inspector row|Appearance| Appearance type for the placeable }}&lt;br /&gt;
{{inspector row|Character| One or more placeables can be mapped to a single character. }}&lt;br /&gt;
{{inspector row|Comments| General information about this placeable. }}&lt;br /&gt;
{{inspector row|Conversation| Default conversation resource for this placeable. }}&lt;br /&gt;
{{inspector row|Group| The placeable's group as specified in groups.2da. Each group can be either hostile or non-hostile towards each other. }}&lt;br /&gt;
{{inspector row|Name| Name of the placeable as seen in the game. }}&lt;br /&gt;
{{inspector row|NameRequiresReTranslation| A true/false flag used during game development for localization work }}&lt;br /&gt;
{{inspector row|Plot| True/false, if true the placeable cannot be damaged or affected by any hostile effect. }}&lt;br /&gt;
{{inspector row|PopupText| !!Property description!! }}&lt;br /&gt;
{{inspector row|PopupTextRequiresReTranslation| A true/false flag used during game development for localization work }}&lt;br /&gt;
{{inspector row|Rank| Placeables are never involved in combat, but their combat rank is still used by the [[treasure system]] when generating treasure. }}&lt;br /&gt;
{{inspector row|Resource Name| A unique string identifier the tooleset and the game both use to refer to this resource. }}&lt;br /&gt;
{{inspector row|Script| Event script assigned to the resource. }}&lt;br /&gt;
{{inspector row|Tag| A non-unique string identifier used mostly by scripts and other resources to refer to this resource. }}&lt;br /&gt;
{{inspector row|Team| Numeric identifier of the team the placeable belongs to. Team numbers are often used in scripting. }}&lt;br /&gt;
{{inspector row|Treasure Category| Determines what variety of treasure is generated by the [[treasure system]] }}&lt;br /&gt;
{{inspector row|Variable 2da| Allows selecting a variable table. Only the values in this table can be set and retrieved by scripting. }}&lt;br /&gt;
{{inspector row|Variables| Displays the table selected in the &amp;quot;Variable 2da&amp;quot; field. Allows setting initial states for parameters. }}&lt;br /&gt;
&lt;br /&gt;
{{inspector section|Key}}&lt;br /&gt;
{{inspector row|Auto Remove Key| Sets whether the game will remove a key from inventory once used to open this placeable. }}&lt;br /&gt;
{{inspector row|Key Required| Sets whether or not a key is the only way to open this placeable }}&lt;br /&gt;
{{inspector row|Key Tag| The tag of the key needed to open this placeable }}&lt;br /&gt;
&lt;br /&gt;
{{inspector section|Sound}}&lt;br /&gt;
{{inspector row|Close to Open Sound| Sound emitted when the object changes from a closed state to an opened state }}&lt;br /&gt;
{{inspector row|Destroyed Sound| Sound emitted when the object is destroyed }}&lt;br /&gt;
{{inspector row|Hit Sound| Sound emitted when the object is hit for damage }}&lt;br /&gt;
{{inspector row|Locked Sound| Sound emitted when an attempt is made to open a locked object }}&lt;br /&gt;
{{inspector row|Open to Close Sound| Sound emitted when the object changes from an opened to a closed state. }}&lt;br /&gt;
{{inspector row|Used Sound| Sound emitted when the object is &amp;quot;used&amp;quot; (generically). }}&lt;br /&gt;
&lt;br /&gt;
{{inspector section|Stats}}&lt;br /&gt;
{{inspector row|Health| Amount of health the placeable currently has}}&lt;br /&gt;
{{inspector row|Initial State| The animation state the placeable will be in when first spawned. }}&lt;br /&gt;
{{inspector row|Interactive| Sets whether or not this placeable can be clicked on during the game. }}&lt;br /&gt;
{{inspector row|Inventory List| Opens the inventory panel and enables user to assign items to the placeable's inventory }}&lt;br /&gt;
{{inspector row|Max Health| The maximum amount of health this placeable can have.}}&lt;br /&gt;
{{inspector row|Pick Lock Level| The difficulty level to pick the lock }}&lt;br /&gt;
&lt;br /&gt;
{{inspector section|Trap}}&lt;br /&gt;
{{inspector row|Is Trapped| Sets whether or not a trap trigger is linked to this placeable }}&lt;br /&gt;
{{inspector row|Trap Detection Difficulty| Sets the skill level required to detect this trap. }}&lt;br /&gt;
{{inspector row|Trap Disarm Difficulty| Sets the skill level required to disarm this trap. }}&lt;br /&gt;
&lt;br /&gt;
{{inspector end}}&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*[[Chanter's board]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Placeables]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7374</id>
		<title>Talk:EVENT TYPE BLOCKED</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7374"/>
				<updated>2009-11-01T00:42:21Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Sent When: */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Sent When: ==&lt;br /&gt;
&lt;br /&gt;
The wording here is a little ambiguous and I don't know enough about placeables and walkmeshes in DA to resolve it.&lt;br /&gt;
&lt;br /&gt;
You could say it is implying that there can be placeables which do change the walkmesh &amp;amp; terrain and others that cannot. And this event is never sent when you bump into those that cannot. One is left to assume that it is always sent when you're blocked by those that can.&lt;br /&gt;
&lt;br /&gt;
It can also be read to be saying that because all placeables cannot change the walkmesh and terrain, this event is never sent when you get blocked by any placeable for that reason.&lt;br /&gt;
&lt;br /&gt;
If it is the latter, it should simply state it isn't sent when you bump placeables. Or, actually, take it out completely since you are really explaining, in the Sent When section, situations when you don't send it. And so it isn't all that relevant unless you plan to list along side it all the other situations when it also is not sent. Maybe it would be better to make this clarification in a Remarks section where it can be detailed better.&lt;br /&gt;
&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 00:19, 1 November 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7373</id>
		<title>Talk:EVENT TYPE BLOCKED</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7373"/>
				<updated>2009-11-01T00:38:46Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Sent When: ==&lt;br /&gt;
&lt;br /&gt;
The wording here is a little ambiguous and I don't know enough about placeables and walkmeshes in DA to resolve it.&lt;br /&gt;
&lt;br /&gt;
You could say it is implying that there can be placeables which do change the walkmesh &amp;amp; terrain and others that cannot. And this event is never sent when you bump into those that cannot. One is left to assume that it is always sent when you're blocked by those that can.&lt;br /&gt;
&lt;br /&gt;
It can also be read to be saying that because all placeables cannot change the walkmesh and terrain, this event is never sent when you get blocked by any placeable for that reason.&lt;br /&gt;
&lt;br /&gt;
If it is the latter, it should simply state it isn't sent when you bump placeables. Or, actually, take it out completely since you are really explaining, in the Sent When section, situations when you don't send it. And so it isn't all that relevant unless you plan to list all the other situations when it also is not sent along side it. Maybe it would be better to make this clarification in a Remarks section where it can be detailed better.&lt;br /&gt;
&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 00:19, 1 November 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7372</id>
		<title>Talk:EVENT TYPE BLOCKED</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7372"/>
				<updated>2009-11-01T00:37:26Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Sent When: */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Sent When: ==&lt;br /&gt;
&lt;br /&gt;
The wording here is a little ambiguous and I don't know enough about placeables and walkmeshes in DA to resolve it.&lt;br /&gt;
&lt;br /&gt;
You could say it is implying that there can be placeables which do change the walkmesh &amp;amp; terrain and others that cannot. And this event is never sent when you bump into those that cannot. One is left to assume that it is always sent when you're blocked by those that can.&lt;br /&gt;
&lt;br /&gt;
It can also be read to be saying that because all placeables cannot change the walkmesh and terrain, this event is never sent when you get blocked by any placeable for that reason.&lt;br /&gt;
&lt;br /&gt;
If it is the latter, it should simply state it isn't sent when you bump placeables. Or, actually, take it out completely since you are really explaining, in the Sent When section, situations when you don't send it. And so it isn't all that relevant unless you plan to list all the other situations when it also is not sent. Maybe it would be better to make this clarification in one of the lower sections where it can be detailed better.&lt;br /&gt;
&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 00:19, 1 November 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7371</id>
		<title>Talk:EVENT TYPE BLOCKED</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7371"/>
				<updated>2009-11-01T00:36:20Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Sent When: */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Sent When: ==&lt;br /&gt;
&lt;br /&gt;
The wording here is a little ambiguous and I don't know enough about placeables and walkmeshes in DA to resolve it.&lt;br /&gt;
&lt;br /&gt;
You could say it is implying that there can be placeables which do change the walkmesh &amp;amp; terrain and others that cannot. And this event is never sent when you bump into those that cannot. One is left to assume that it is always sent when you're blocked by those that can.&lt;br /&gt;
&lt;br /&gt;
It can also be read to be saying that because all placeables cannot change the walkmesh and terrain, this event is never sent when you get blocked by any placeable for that reason.&lt;br /&gt;
&lt;br /&gt;
If it is the latter, it should simply state it isn't sent when you bump placeables. Or, actually, take it out completely since you are really explaining, in the Sent When section, situations when you don't send it. And so it isn't all that relevant. Maybe it would be better to make this clarification in one of the lower sections where it can be detailed better.&lt;br /&gt;
&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 00:19, 1 November 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=EVENT_TYPE_BLOCKED&amp;diff=7370</id>
		<title>EVENT TYPE BLOCKED</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=EVENT_TYPE_BLOCKED&amp;diff=7370"/>
				<updated>2009-11-01T00:31:42Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: spelling&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{event&lt;br /&gt;
|sourcefile=script.ldf&lt;br /&gt;
|when=The current creature's path has been blocked while moving by a creature or door. This event will NOT fire when blocked by placeables which cannot change the walk mesh or terrain.&lt;br /&gt;
|from=engine&lt;br /&gt;
|to=[[creature]]s&lt;br /&gt;
|tocategory1=creature&lt;br /&gt;
|sortkey=BLOCKED&lt;br /&gt;
|creatorname=oBlocker&lt;br /&gt;
|creatordesc=blocking object&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Also, this doesn't exist yet, but we'll need this event to fire for any time that the pathfinding failed.{{undocumented}}&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7369</id>
		<title>Talk:EVENT TYPE BLOCKED</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7369"/>
				<updated>2009-11-01T00:30:15Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Sent When: */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Sent When: ==&lt;br /&gt;
&lt;br /&gt;
The wording here is a little ambiguous and I don't know enough about placeables and walkmeshes in DA to resolve it.&lt;br /&gt;
&lt;br /&gt;
You could say it is implying that there can be placeables which do change the walkmesh &amp;amp; terrain and others that cannot. And this event is never sent when you bump into those that cannot. One is left to assume that it is always sent when you're blocked by those that can.&lt;br /&gt;
&lt;br /&gt;
It can also be read to be saying that because all placeables cannot change the walkmesh and terrain, this event is never sent when you get blocked by any placeable for that reason.&lt;br /&gt;
&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 00:19, 1 November 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7368</id>
		<title>Talk:EVENT TYPE BLOCKED</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7368"/>
				<updated>2009-11-01T00:28:06Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Sent When: */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Sent When: ==&lt;br /&gt;
&lt;br /&gt;
The wording here is a little ambiguous and I don't know enough about placeables and walkmeshes in DA to resolve it.&lt;br /&gt;
&lt;br /&gt;
You could say it is implying that there can be placeables which do change the walkmesh &amp;amp; terrain and others that cannot. And this event is never sent when you bump into those that cannot. One is left to assume that its always sent when you're blocked by those that can.&lt;br /&gt;
&lt;br /&gt;
It can also be read to be saying that because all placeables cannot change the walkmesh and terrain, this event is never sent when you get blocked by any placeable for that reason.&lt;br /&gt;
&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 00:19, 1 November 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7367</id>
		<title>Talk:EVENT TYPE BLOCKED</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7367"/>
				<updated>2009-11-01T00:27:46Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Sent When: */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Sent When: ==&lt;br /&gt;
&lt;br /&gt;
The wording here is a little ambiguous and I don't know enough about placeables and walkmeshes in DA to resolve it.&lt;br /&gt;
&lt;br /&gt;
  You could say it is implying that there can be placeables which do change the walkmesh &amp;amp; terrain and others that cannot. And this event is never sent when you bump into those that cannot. One is left to assume that its always sent when you're blocked by those that can.&lt;br /&gt;
&lt;br /&gt;
  It can also be read to be saying that because all placeables cannot change the walkmesh and terrain, this event is never sent when you get blocked by any placeable for that reason.&lt;br /&gt;
&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 00:19, 1 November 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7366</id>
		<title>Talk:EVENT TYPE BLOCKED</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:EVENT_TYPE_BLOCKED&amp;diff=7366"/>
				<updated>2009-11-01T00:19:24Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: Sent When:&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Sent When: ==&lt;br /&gt;
&lt;br /&gt;
The wording here seems to imply that there can be placeables which do change the walkmesh and terrain and others that cannot. And this event is never sent when you bump into those that cannot. One is left to assume that its always sent when you're blocked by those that can.&lt;br /&gt;
&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 00:19, 1 November 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=EVENT_TYPE_BLOCKED&amp;diff=7365</id>
		<title>EVENT TYPE BLOCKED</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=EVENT_TYPE_BLOCKED&amp;diff=7365"/>
				<updated>2009-11-01T00:09:00Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: grammar&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{event&lt;br /&gt;
|sourcefile=script.ldf&lt;br /&gt;
|when=The current creature's path has been blocked while moving by a creature or door. This event will NOT fire when blocked by placeables which can not change the walk mesh or terrain.&lt;br /&gt;
|from=engine&lt;br /&gt;
|to=[[creature]]s&lt;br /&gt;
|tocategory1=creature&lt;br /&gt;
|sortkey=BLOCKED&lt;br /&gt;
|creatorname=oBlocker&lt;br /&gt;
|creatordesc=blocking object&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Also, this doesn't exist yet, but we'll need this event to fire for any time that the pathfinding failed.{{undocumented}}&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Ability&amp;diff=7361</id>
		<title>Ability</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Ability&amp;diff=7361"/>
				<updated>2009-10-31T03:49:14Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Q: How does Rank Based Mitigation Work ? */ formatting&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=== Overview ===&lt;br /&gt;
The Ability System is used to handle Spells, Talents, Skills, and Item Abilities in Dragon Age.&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Spells, Talents, Skills and item abilities all use the same backend in the game, a mostly script implemented system relying heavily on two dimensional data arrays. &lt;br /&gt;
&lt;br /&gt;
The most important 2da file for abilities is '''[[ABI_base.xls]]''', as it defines each ability and all aspects of execution and handling in both scripting and engine code.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Ability Design Notes''' &lt;br /&gt;
&lt;br /&gt;
When creating an ability in Dragon Age: Origins, we generally stick to the following guidelines&lt;br /&gt;
&lt;br /&gt;
* Keep it useful. &lt;br /&gt;
Some constant benefits (such as an increase in Attack or Defense) stay useful for the duration of the game as the progression of the related properties are slow. &lt;br /&gt;
For other effects, such as damage, a constant value would mean that the ability will become progressively worse through the game as damage needed to drop enemies increases from level to level. In such cases, the ability should be tied in some fashion to a Spellpower (for spells) or another relevant trait (such as cunning for rogues) to ensure they stay useful throughout the game. &lt;br /&gt;
&lt;br /&gt;
* No repetition. &lt;br /&gt;
Each ability in Dragon Age: Origins is unique. No incremental abilities such as 'fireball I, fireball II, etc.'. Skills are exempt from this rule. Remember that the Damage Types dramatically alter the actual effect of an ability (such as lightning always draining stamina alongside doing damage), so having similar damaging abilities in different trees is usually fine.&lt;br /&gt;
&lt;br /&gt;
* Thematic matching.&lt;br /&gt;
Abilities within the same chain should follow a common theme. &lt;br /&gt;
&lt;br /&gt;
* Avoid binary abilities. Design hit heavy.&lt;br /&gt;
Avoid abilities that are hit-or-miss. Generally, abilities should hit whenever possible and use target side mitigation of effects (resistance checks, damage mitigation) instead of 'hit or miss' mechanics. Melee abilities may use the normal attack resolution routines but should always perform their attacks at a bonus. Use rank based mitigation and resistances to allow for very powerful effects that do not trivialize boss battles. &lt;br /&gt;
&lt;br /&gt;
* Use meaningful effects&lt;br /&gt;
Abilities should always be worth it. Don't do minor effects (+1 attack). The player should always be able to see the effect of the ability in game (not necessarily visually, but at least through increased damage, etc.). The first ability in a chain should, whenever possible, be active. The fourth ability in a chain should always have the biggest 'bang-for-the-buck' factor. Abilities lower in the chain should have shorter cooldowns. Do not allow instant death on bosses and elite bosses.&lt;br /&gt;
&lt;br /&gt;
* Avoid 'zero-sum' abilities&lt;br /&gt;
When possible, avoid 'zero-sum' abilities that trade a penalty for a benefit (e.g. increase defense but decrease attack). There are a number of these abilities that are valid (such as aim), but balancing them and keeping them useful is hard and requires a lot of work. This obviously does not apply to drastic abilities such as blood magic.&lt;br /&gt;
&lt;br /&gt;
* No emulation of defining class capabilities&lt;br /&gt;
Never ever grant a basic class capability from one class to another class via abilities. This means no invisibility or magical unlock spells for mages, as these are defining capabilities of the rogue class. No weapon talents for mages. No magic spells or large, targeted area of effects for warriors or rogues. Items might blur this line if the cost is balanced properly (e.g. grenades).&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Basic Ability Types ====&lt;br /&gt;
&lt;br /&gt;
Abilities are divided into 4 subtypes, as defined in the 'abilitytype' column in [[ABI_base.xls]]:&lt;br /&gt;
&lt;br /&gt;
* Talents - Abilities used by warriors and rogues, usually non magical in nature. (abilitytype=1)&lt;br /&gt;
* Spells - Abilities used by mages, either spell or passive abilities.  (abilitytype=2)&lt;br /&gt;
* Skills - Abilities usable by all classes, such as Survival and Combat training (abilitytype=3).&lt;br /&gt;
* Items  - Abilities present on an item that are triggered when the item is used on the quickbar. (ability_type=4)&lt;br /&gt;
&lt;br /&gt;
Note: Talents do not show up on mages and spells do not show up on rogue or warrior characters, so to create abilities that can be used by all classes, abilitytype 3 (Skill) must be used. To define under which heading an ability shows up on the character's talent/spell page, the field 'guitype' is used. It resolves against [[guitype.xls]] which lists all known headings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are 3 basic ability types in the game, defined by the field 'use_type' in [[ABI_base.xls]].&lt;br /&gt;
&lt;br /&gt;
'''Passive Abilities''' &lt;br /&gt;
&lt;br /&gt;
Passive abilities (use_type = 3) grant persistent or conditionally persistent bonuses or penalties to the creature that has the ability. &lt;br /&gt;
&lt;br /&gt;
A passive ability may grant up to 3 modifications to creature properties ([[properties.xls]]). Those modifications are defined in the passive_abilities worksheet of [[ABI_base.xls]] and linked to the ability through the passive_id column in ABI_base.xls.&lt;br /&gt;
&lt;br /&gt;
Additionally, the bonuses of an ability can be made conditional on the character's current 'wield mode' (2-handed, dual, weapon &amp;amp; shield, or universal) through the conditional integer field on the passive_abilities worksheet.&lt;br /&gt;
&lt;br /&gt;
Finally, a number of passive abilities do not define any property modifications in passive_abilites but instead have checks coded against their Ids directly in the combat resolution scripts (e.g. HasAbility( oCreature, ABILITY_TALENT_LETHALITY )). The mere presence of the ability on a creature causes a different code path to be taken in the scripts in those cases.&lt;br /&gt;
&lt;br /&gt;
Note that passive_ability benefits are not limited to abilities with use_type 3. Some active abilities also grant additional property modifying benefits to the owner.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sustained Abilities'''&lt;br /&gt;
&lt;br /&gt;
Sustained abilities (use_type = 2) are turned on and off per character and, while turned on, grant effects or property modifications to the user. &lt;br /&gt;
Most 'buffs' are implemented this way.&lt;br /&gt;
&lt;br /&gt;
Only members of the player's party are using sustained ability as the code overhead required to track them is too expensive to be used on monsters that only exist to die in an encounter with the player's party. (These creatures use duration based effects to emulate similar abilities instead).&lt;br /&gt;
&lt;br /&gt;
Most sustained abilities follow the same pattern:&lt;br /&gt;
* They do not have any activation cost, encouraging tactical use of buffs.&lt;br /&gt;
* They increase the users [[Fatigue]] property, therefore increasing the activation cost of all other abilities.&lt;br /&gt;
* They reduce the users maximum available mana or stamina by a constant value.&lt;br /&gt;
* They use cooldown to prevent the user from being too opportunistic with their use.&lt;br /&gt;
* Some abilities shut down when the user reaches 0 mana/stamina. Very powerful abilities (such as Momentum) have an associated stamina/mana drain effect to limit their use to a short or medium period of time. Creative item / buff use can be used to increase the length such an ability can be sustained.&lt;br /&gt;
&lt;br /&gt;
The benefits from sustained abilities are calculated when the ability is activated. So if a character levels up or otherwise changes stats that influence the magnitude of a sustained ability, they will not update until the ability is reactivated the next time.&lt;br /&gt;
&lt;br /&gt;
Some sustained abilities (such as Flaming Weapons) are active 'party-wide' - the caster not only sustains the ability on himself but on all his party members as well. This is controlled by the 'bPartyWide' flag in [[ABI_base.xls]]. Due to implementation limitations, party members who die or otherwise enter/exit the current party will not be affected by these abilities until they are recast. (we put low cooldown times on these abilities for that very reason).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Gameplay Design Note''' &lt;br /&gt;
* Unlike in games like Baldur's Gate, the system in DA: Origins is designed to encourage tactical use of buffs over strategical. We wanted to put an emphasis on the player making smart choices during an encounter vs. the player guessing which buffs might be useful ahead of time or having to employ save-die-reload to find out. &lt;br /&gt;
&lt;br /&gt;
* It is generally wise to run only one or two buffs all around and activate additional buffs only when needed. &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Activated Abilities'''&lt;br /&gt;
&lt;br /&gt;
Activated abilities (use_type = 4) are abilities that instantly execute their effect (see Targeting Behavior below). Most melee talents or targeted spells fall in this category. There are several sub-types of activated abilies, such as&lt;br /&gt;
&lt;br /&gt;
* Targeted, single target spells and talents (such as Winter's Grasp or Flurry)&lt;br /&gt;
* Ground targeted abilities (such as Blizzard or various Glyphs)&lt;br /&gt;
* Self targeted activated abilities.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Targeting Behavior ====&lt;br /&gt;
&lt;br /&gt;
An abilities targeting behavior is controlled by several settings in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoTarget''' is a boolean field that defines how the UI resolves targeting.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The UI will always bring up a targeting cursor. &lt;br /&gt;
|-&lt;br /&gt;
| 1 || The UI will only produce a targeting cursor if no suitable target is currently selected. e.g if the player currently has a hostile creature targeted and if the spells TargetType includes 0x4 (hostile), the ability will trigger immediately, not producing a targeting cursor. Most single target spells and talents use this setting.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Regardless of AutoTarget setting, the UI will never produce a targeting cursor if an ability is type 0x1 (self) -&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''TargetType''' is a bit mask derived from the following table and controls the behavior of the UI's targeting cursor.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
|'''Bitmask''' || '''Effect'''&lt;br /&gt;
|-&lt;br /&gt;
| 0x1  ||  Self&lt;br /&gt;
|-&lt;br /&gt;
| 0x2 || Friendly Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x4 || Hostile Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x8 || Placeable Object&lt;br /&gt;
|-&lt;br /&gt;
| 0x10 || Area of Effect Object (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20 || Ground (see details)&lt;br /&gt;
|-&lt;br /&gt;
| 0x40 || Dead Body (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x80 || Party Member&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoDraw''' is an integer boolean field that defines how a character's weapons are handled when the ability is triggered.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The ability will not affect the player's weapon sheath status.&lt;br /&gt;
|-&lt;br /&gt;
| 1 || The engine will force the player to draw/unsheathe his weapon before executing the ability. This is used for most bow and melee weapon abilities. &lt;br /&gt;
|-&lt;br /&gt;
| 2 || The engine will force the player to stow away any non staff melee weapons before executing the ability. This is used to ensure that no inappropriate animations play with weapons drawn (e.g. the player conjuring with a sword clipping through his body) and to discourage switching between melee and spellcasting on the fly.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Balancing (Cost, Cooldown, etc) ====&lt;br /&gt;
&lt;br /&gt;
Abilities in Dragon Age are balanced along several vectors, most of which boil down to simple 'use frequency'. As a general rule of thumb, the more specialized and limited the effect of an ability is, the more outrageously powerful an ability can be.&lt;br /&gt;
&lt;br /&gt;
Use frequency of abilities can be adjusted by modifying the following field in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
* Cost: This is the simple mana (spells) or stamina (talents) activation cost of an ability. It is subtracted when the conjure phase of the spell has succesfully completed (e.g. no cost for spell interruptions). Without sufficient resources to cover activation cost, the UI will not allow the player to execute the ability. The value is a constant integer and is multiplied with 1+(Current Fatigue) of the caster. &lt;br /&gt;
&lt;br /&gt;
* Cooldown: Cooldown is a constant float in seconds that defines how long the player has to wait after the successful activation of an ability until he can use it again. For abilities that apply duration based debuffs or effects to a target, cooldown is usually set slightly higher than the duration of the effect to avoid stacking by the same caster.&lt;br /&gt;
&lt;br /&gt;
* Upkeep: Defines how much mana or stamina is removed from the casters overall pool while a sustained ability is active. This naturally limits the number of sustained abilities present on a creature and ensures that the more beneficial buffs are active on the caster, the less mana is available for immediate use.&lt;br /&gt;
&lt;br /&gt;
* [[Fatigue]]: Fatigue affects use frequency only indirectly, but it prevents characters from stacking too many buffs on each other, as each sustained ability active usually adds around 5-10% fatigue to the caster.&lt;br /&gt;
&lt;br /&gt;
* Mana/Stamina drain: By reducing the mana/stamina regeneration rate on a creature, the duration for which a sustained ability can be used can be restricted. This mechanic is used only for the most powerful sustained abilities in the game, which are flagged to turn off when the caster sustaining them reaches 0 mana/stamina.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Other balancing vectors:&lt;br /&gt;
&lt;br /&gt;
* AoESize and AoeShape: Area of effect spells that deal friendly fire are location and situation restricted on normal+ difficulty (hard+ on the consoles). Since dropping an Inferno on your own party members is hardly a good idea in most cases, the usefulness of the spell becomes restricted to careful positioning and the earlier stages of combat. &lt;br /&gt;
&lt;br /&gt;
* Threat Generation: Abilities apply threat not just by damage but often by activation. Higher activation threat of an ability can balance out outrageously powerful effects by making it harder for the player to use the spell. The prime example is the Walking Bomb kind of spells which deal excellent damage, but, on higher difficulties, also make the targets very very angry at the caster.  Using these spells effectively often requires a tactical approach by the player, thus limiting their universal usefulness and offsetting their very powerful effects.&lt;br /&gt;
&lt;br /&gt;
* Threat Removal: Some abilities are designed to only provide a short term benefit (Such as 3s stun on Mindblast) but offset their weakness by removing threat from the caster, often by reinitializing the threat tables on the target, causing enemies to randomly seek new targets.&lt;br /&gt;
&lt;br /&gt;
* Conjure time: Spells with a conjure time of 1+ (Speed in [[ABI_base.xls]]) can be interrupted by damage, limiting their usefulness in melee situations or when only one party member remains on the battlefield. Many of the very powerful Area of Effect type spells use this feature. Most activated spells have a conjure time of 0, making them instant cast.&lt;br /&gt;
&lt;br /&gt;
* Range: Lower ranges force the ability user into potentially more dangerous situations, adding additional risk to the use of an ability.&lt;br /&gt;
&lt;br /&gt;
=== Q&amp;amp;A ===&lt;br /&gt;
&lt;br /&gt;
==== Q: Where do we find the exact formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Due to most abilities being unique, the only place to find the exact details on each spell is in the scripts. While a lot of data can be glanced from [[ABI_base.xls]], a lot of the detailed mechanics are very different between abilities and can only be found in the appropriate spellscript. The *_constant.nss files hold some basic values, but often get further modified in the scripts. &lt;br /&gt;
&lt;br /&gt;
This is also one of the reasons why some elements of a talent are not displayed in the UI description in game. While we can calculate cost and cooldown based on the casting character and his fatigue and other properties (and consequently display it), we can usually not calculate damage or duration as they are mitigated on the target creature: &lt;br /&gt;
&lt;br /&gt;
Displaying those values results in very misleading information (e.g. while damage seems to be higher on one ability, the mitigation mechanisms and unique side effects of another ability will make it just as good or better - in certain situations) and it turned out to be better to provide the player with general guidance than the misleading information.&lt;br /&gt;
&lt;br /&gt;
==== Q: What is Spellpower and how does it interact with abilities ====&lt;br /&gt;
&lt;br /&gt;
Spellpower is probably the most important stat for a mage character (and only exists on mage characters). It is calculated as max(Magic - 10,0) and therefore increases by one point for every point a mage spends on his Magic attribute.&lt;br /&gt;
&lt;br /&gt;
Most mage spells benefit directly from higher spellpower by increased damage, effect magnitude and duration. It also plays a role in a mages ability to overcome mental or physical resistance on a target (where applicable). The actual impact of spellpower on an ability varies from spell to spell but the most common construct equates to something like 1% increase in spell potency per point of Spellpower. Thus, items and spells that increase spellpower are very powerful as they increase the potency of every spell the mage can cast.&lt;br /&gt;
&lt;br /&gt;
Spellpower is the only factor that causes an increase of a spells potency over time, so a level 20 mage with neglected the Magic attribute would be much less powerful than a mage that didn't neglect Magic.&lt;br /&gt;
&lt;br /&gt;
Some examples:&lt;br /&gt;
&lt;br /&gt;
* The damage potential for Winter's Grasp is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.36f;&lt;br /&gt;
* The healing potential for the heal spell is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.40f;&lt;br /&gt;
* The damage over time component of blizzard is executed as ApplyEffectDamageOverTime(a[i], oCreator, ABILITY_SPELL_BLIZZARD,  (100.0f + GetCreatureSpellPower(oCreator)) * 0.1, (BLIZZARD_INTERVAL_DURATION - 0.5f), DAMAGE_TYPE_COLD);&lt;br /&gt;
&lt;br /&gt;
Note that these formulas only list the raw damage potential and do not take into account the effects of damage types, difficulty, rank, resistances, magical shields and any other mitigating factors on the target or enhancing factors on the caster. This means that just comparing the numbers will not give you an idea which spell is better or worse.&lt;br /&gt;
&lt;br /&gt;
For non-mage spells and abilities, spellpower is often substituted by an appropriate other construct (such as max(Cunning-10,0) for rogue abilities).&lt;br /&gt;
&lt;br /&gt;
==== Q: Can we have the damage formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is no damage formula for abilities, as mentioned before, each ability follows their own rules.&lt;br /&gt;
&lt;br /&gt;
In general, talent damage is based on the weapon being used (e.g. Assault does 3 melee attacks that deal weapon damage with some additional bonuses) and are modified by external cirumstances such as location, critical chance and ability to deliver a backstab and are mitigated by armor on the target.&lt;br /&gt;
&lt;br /&gt;
Spells deal damage of different damage types following a rough rule of (Constant * (Spellpower / Variable)) / [Variables] ) + Modifiers but this only tells part of the story as actual damage is dependent on the target, it's resistances, rank and a number of other factors.&lt;br /&gt;
&lt;br /&gt;
Some additional factors affecting spell damage are:&lt;br /&gt;
&lt;br /&gt;
* damage resistance.&lt;br /&gt;
* magical shields.&lt;br /&gt;
* difficulty level.&lt;br /&gt;
* elemental damage bonuses from spells or items &lt;br /&gt;
* Environmental conditions (frozen targets take less damage from fire, etc.)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the differences between damage types? ====&lt;br /&gt;
&lt;br /&gt;
A: Creatures have variable damage resistances based on their type and rank. Dragons might get 60% less damage from fire (60% fire resistance), other creatures will have different immunities. Additional effects are:&lt;br /&gt;
&lt;br /&gt;
* Electricity: In addition to normal damage, these also reduce the targets stamina (but not mana) by the same amount, making them very effective boss killers.&lt;br /&gt;
&lt;br /&gt;
* Fire: Cancels Cold based damage over time effects and applies damage over time.&lt;br /&gt;
&lt;br /&gt;
* Cold: Cancel Fire based damage over time effects and often is accompanied by slow or slipping effects.&lt;br /&gt;
&lt;br /&gt;
* Spirit: There are very few ways of increasing spirit resistance in the game, so spells dealing spirit damage are universally useful...&lt;br /&gt;
&lt;br /&gt;
* Nature: Rarely found on spells. Many creatures are resistant to this.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(This should probably go on its own wiki page)&lt;br /&gt;
&lt;br /&gt;
==== Q: Are sustained abilities mutually exclusive ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is a very limited number of sustained abilities that are mutually exclusive, usually because it makes sense. Mutually exclusive abilities cancel each other upon activation.&lt;br /&gt;
&lt;br /&gt;
* Shield stances (Shield Wall, Shield Cover, Shield Defense) are mutually exclusive.&lt;br /&gt;
* Archery stances (Aim, Rapid Fire, Defensive Fire) are mutually exclusive.&lt;br /&gt;
* Shapeshifting forms (Sorry, no Bear-Wolfspider) are mutually exclusive.&lt;br /&gt;
* Weapon Enhancement spells are too, but only for the same caster (so two mages can run two different weapon enhancements if they want to).&lt;br /&gt;
* Bard Songs are mutually exclusive.&lt;br /&gt;
* The Death Syphon and Death Magic spells are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
Technically, all abilities in [[ABI_base.xls]] that share the same 'condition_group' value are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the rules for stacking effects and damage ? ====&lt;br /&gt;
&lt;br /&gt;
A: The general rules of stacking for abilities are:&lt;br /&gt;
&lt;br /&gt;
* Identical effect from different abilities stack (e.g. getting +10 attack from one ability and +10 attack from another nets +20 attack).&lt;br /&gt;
* The effects of identical abilities stack as long as they are from different caster. (Same caster usually does not apply as cooldown often exceeds duration).&lt;br /&gt;
* Weapon enhancement spells of the same type (e.g. 2 mages with flame weapons) do not stack. The sword does not get more flaming, sorry :)&lt;br /&gt;
* Animation based effects (knockdown, stun, etc.) stack, but only the one with the highest priority is played. This is defined in the priority column in [[effects.xls]].&lt;br /&gt;
* Glyphs do stack but there is a limit of 5 active glyphs per caster.&lt;br /&gt;
* Fire and Cold DoT effects do not stack, the spell cast last will cancel any existing spell of the opposite type.&lt;br /&gt;
* Fire and Cold AoEs cancel each other, other AoEs might interact rather violently, handle with care :)&lt;br /&gt;
&lt;br /&gt;
For equipment and item based effects, the game usually stacks within the minumum and maximum clamp values of a property ([[properties.xls]]). This means that you can accumulate a lot of +damage or +critical critical chance effects, but for some stat types there is a point where you are no longer gaining any benefits (e.g. speed modification - animations can only be sped up to a certain point before breaking, so stacking momentum, haste and a weapon with a speed based effect will not result in a -3.0s attack time, sorry :p)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
For almost all effects, the total result of all property modifications on a creature are visible on the main character UI by hovering over the individual stats.&lt;br /&gt;
&lt;br /&gt;
==== Q: How does game difficulty affect abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Our approach to game difficulty dictates that the effect of your chosen setting are&lt;br /&gt;
&lt;br /&gt;
a) non punishing - You do not get less XP for chosing a lower difficulty mode, etc.&lt;br /&gt;
b) challenge scaling - Higher difficulty will reward you with greater obstacles to overcome.&lt;br /&gt;
c) fair - Lower difficulties grant benefits that gradually get removed. (This does not mean the rules are symmetric and is not true on nightmare at all. Nightmare is evil. And unfair.)&lt;br /&gt;
d) non persistent - Difficulty changes are possible on the fly, at any time and take immediate effect.&lt;br /&gt;
&lt;br /&gt;
The game is balanced so that Hard mode is challenging for a Baldur's gate veteran.&lt;br /&gt;
&lt;br /&gt;
Based on these guidelines, you can expect the following ability behaviors in game:&lt;br /&gt;
&lt;br /&gt;
* The lower the difficulty, the longer your hostile effects such as stuns will last on enemies and the shorter they will last on you.&lt;br /&gt;
* The lower the difficulty, the more damage your abilities will do.&lt;br /&gt;
* The lower the difficulty, the less likely the enemy AI will use devastating special abilities (Note: less likely does not mean 'does not use').&lt;br /&gt;
* Casual and Normal have reduced friendly or nullified fire damage damage from area effect spells. Hard and Nightmare require careful positioning and tactical use of spells.&lt;br /&gt;
* The higher the difficulty, the more careful you need to manage threat when using spells and abilities (The AI becomes smarter about picking targets).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What is spell affinity ? ====&lt;br /&gt;
&lt;br /&gt;
A: Spell Affinity was a design we toyed with for a while during development but decided not to implement.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: How does Rank Based Mitigation Work ? ====&lt;br /&gt;
&lt;br /&gt;
A: In line with Dragon Age: Origin's asymmetric approach to rules, the game uses creature ranks (instead of levels) in addition to stats and resistances to define how creatures get affected by abilities. In short: Boss monsters get affected differently by abilities and effects than Lieutenants or Critters. &lt;br /&gt;
&lt;br /&gt;
The rank system is the primary balancing vector for the games difficulty levels and profoundly affects all aspects of combat. The gory details of this system are defined in [[creature_ranks.xls]] and [[difficulty.xls]].&lt;br /&gt;
&lt;br /&gt;
Rank mitigation affects not just damage in- and output of a creature, but also the duration that hostile effects persist on it and is different for each difficulty level of the game. Note that party members have their own rank in this system and are handled differently from other creatures in some cases. &lt;br /&gt;
&lt;br /&gt;
Below is the formula used for rank based effect duration mitigation: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
// sys_resistances_h&lt;br /&gt;
// @brief Returns an effect duration scaled by rank of oCreature and game difficulty&lt;br /&gt;
// @author Georg&lt;br /&gt;
float GetRankAdjustedEffectDuration(object oCreature, float fDur)&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    // Georg: This deserves some explanation:&lt;br /&gt;
    //&lt;br /&gt;
    //        One of the core issues when designing the combat system was always&lt;br /&gt;
    //        the fact that the story called for sequences during the game in which&lt;br /&gt;
    //        your main character acts solo.&lt;br /&gt;
    //&lt;br /&gt;
    //        Characters reliant on special abilities, such as rogues, would require&lt;br /&gt;
    //        them to be very effective in order to beat enemies that a standard tank&lt;br /&gt;
    //        can plow through. However, if these abilities would maintain the same&lt;br /&gt;
    //        effectiveness in a full party, most encounters would turn into a stunfest.&lt;br /&gt;
    //&lt;br /&gt;
    //        The solution is to add 1 second flat to each detrimental effect duration&lt;br /&gt;
    //        lasting at least 1 second for each unoccupied slot in the party - before applying&lt;br /&gt;
    //        rank and difficulty modifiers. This also makes solo play a bit more viable.&lt;br /&gt;
    //&lt;br /&gt;
    //        This is in addition to the diminishing returns on quickly successive stuns.&lt;br /&gt;
    //&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    if (!IsPartyMember(oCreature))&lt;br /&gt;
    {&lt;br /&gt;
        float fPartySizeModifier = IntToFloat(Max(0,4 - GetArraySize(GetPartyList())));&lt;br /&gt;
&lt;br /&gt;
        if (fDur &amp;gt;= 1.0f)&lt;br /&gt;
        {&lt;br /&gt;
            fDur += fPartySizeModifier;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    float fRankDurMod = Diff_GetDurationModifier(oCreature);&lt;br /&gt;
    if (fRankDurMod &amp;gt;0.0f)&lt;br /&gt;
    {&lt;br /&gt;
        return (fDur * fRankDurMod);&lt;br /&gt;
    }&lt;br /&gt;
    else&lt;br /&gt;
    {&lt;br /&gt;
     return fDur;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripts]]&lt;br /&gt;
&lt;br /&gt;
==== Q: What does 'asymmetric rules system' mean ? ====&lt;br /&gt;
&lt;br /&gt;
The goal behind Dragon Age: Origin's rule system was to create a fun and challenging video game experience first and foremost. &lt;br /&gt;
&lt;br /&gt;
We describe the rules as 'asymmetric' because a subset of the game rules treats player controlled characters and monsters differently, which is a deviation from pen and paper rule design that often require player and opponents to be treated exactly the same. &lt;br /&gt;
&lt;br /&gt;
Notable Examples:&lt;br /&gt;
* Party members never die permanently (get shattered, etc.)&lt;br /&gt;
* Differently ranked creatures (including party members) get affected for different durations by effects&lt;br /&gt;
* In limited situations in the game, we apply benefits to the player to overcome greater odds than they would usually be able to. &lt;br /&gt;
* Some abilities will work diferently when deployed against the party (although the visual results might be identical).&lt;br /&gt;
* Elimination of instant death situations (not fun!) against players but not against monsters (fun!).&lt;br /&gt;
* Sustained abilities only work for players (the overhead is not justified for monsters that won't ever reappear after they die).&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Ability&amp;diff=7360</id>
		<title>Ability</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Ability&amp;diff=7360"/>
				<updated>2009-10-31T03:05:19Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Q: What are the rules for stacking effects and damage ? */ formatting&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=== Overview ===&lt;br /&gt;
The Ability System is used to handle Spells, Talents, Skills, and Item Abilities in Dragon Age.&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Spells, Talents, Skills and item abilities all use the same backend in the game, a mostly script implemented system relying heavily on two dimensional data arrays. &lt;br /&gt;
&lt;br /&gt;
The most important 2da file for abilities is '''[[ABI_base.xls]]''', as it defines each ability and all aspects of execution and handling in both scripting and engine code.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Ability Design Notes''' &lt;br /&gt;
&lt;br /&gt;
When creating an ability in Dragon Age: Origins, we generally stick to the following guidelines&lt;br /&gt;
&lt;br /&gt;
* Keep it useful. &lt;br /&gt;
Some constant benefits (such as an increase in Attack or Defense) stay useful for the duration of the game as the progression of the related properties are slow. &lt;br /&gt;
For other effects, such as damage, a constant value would mean that the ability will become progressively worse through the game as damage needed to drop enemies increases from level to level. In such cases, the ability should be tied in some fashion to a Spellpower (for spells) or another relevant trait (such as cunning for rogues) to ensure they stay useful throughout the game. &lt;br /&gt;
&lt;br /&gt;
* No repetition. &lt;br /&gt;
Each ability in Dragon Age: Origins is unique. No incremental abilities such as 'fireball I, fireball II, etc.'. Skills are exempt from this rule. Remember that the Damage Types dramatically alter the actual effect of an ability (such as lightning always draining stamina alongside doing damage), so having similar damaging abilities in different trees is usually fine.&lt;br /&gt;
&lt;br /&gt;
* Thematic matching.&lt;br /&gt;
Abilities within the same chain should follow a common theme. &lt;br /&gt;
&lt;br /&gt;
* Avoid binary abilities. Design hit heavy.&lt;br /&gt;
Avoid abilities that are hit-or-miss. Generally, abilities should hit whenever possible and use target side mitigation of effects (resistance checks, damage mitigation) instead of 'hit or miss' mechanics. Melee abilities may use the normal attack resolution routines but should always perform their attacks at a bonus. Use rank based mitigation and resistances to allow for very powerful effects that do not trivialize boss battles. &lt;br /&gt;
&lt;br /&gt;
* Use meaningful effects&lt;br /&gt;
Abilities should always be worth it. Don't do minor effects (+1 attack). The player should always be able to see the effect of the ability in game (not necessarily visually, but at least through increased damage, etc.). The first ability in a chain should, whenever possible, be active. The fourth ability in a chain should always have the biggest 'bang-for-the-buck' factor. Abilities lower in the chain should have shorter cooldowns. Do not allow instant death on bosses and elite bosses.&lt;br /&gt;
&lt;br /&gt;
* Avoid 'zero-sum' abilities&lt;br /&gt;
When possible, avoid 'zero-sum' abilities that trade a penalty for a benefit (e.g. increase defense but decrease attack). There are a number of these abilities that are valid (such as aim), but balancing them and keeping them useful is hard and requires a lot of work. This obviously does not apply to drastic abilities such as blood magic.&lt;br /&gt;
&lt;br /&gt;
* No emulation of defining class capabilities&lt;br /&gt;
Never ever grant a basic class capability from one class to another class via abilities. This means no invisibility or magical unlock spells for mages, as these are defining capabilities of the rogue class. No weapon talents for mages. No magic spells or large, targeted area of effects for warriors or rogues. Items might blur this line if the cost is balanced properly (e.g. grenades).&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Basic Ability Types ====&lt;br /&gt;
&lt;br /&gt;
Abilities are divided into 4 subtypes, as defined in the 'abilitytype' column in [[ABI_base.xls]]:&lt;br /&gt;
&lt;br /&gt;
* Talents - Abilities used by warriors and rogues, usually non magical in nature. (abilitytype=1)&lt;br /&gt;
* Spells - Abilities used by mages, either spell or passive abilities.  (abilitytype=2)&lt;br /&gt;
* Skills - Abilities usable by all classes, such as Survival and Combat training (abilitytype=3).&lt;br /&gt;
* Items  - Abilities present on an item that are triggered when the item is used on the quickbar. (ability_type=4)&lt;br /&gt;
&lt;br /&gt;
Note: Talents do not show up on mages and spells do not show up on rogue or warrior characters, so to create abilities that can be used by all classes, abilitytype 3 (Skill) must be used. To define under which heading an ability shows up on the character's talent/spell page, the field 'guitype' is used. It resolves against [[guitype.xls]] which lists all known headings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are 3 basic ability types in the game, defined by the field 'use_type' in [[ABI_base.xls]].&lt;br /&gt;
&lt;br /&gt;
'''Passive Abilities''' &lt;br /&gt;
&lt;br /&gt;
Passive abilities (use_type = 3) grant persistent or conditionally persistent bonuses or penalties to the creature that has the ability. &lt;br /&gt;
&lt;br /&gt;
A passive ability may grant up to 3 modifications to creature properties ([[properties.xls]]). Those modifications are defined in the passive_abilities worksheet of [[ABI_base.xls]] and linked to the ability through the passive_id column in ABI_base.xls.&lt;br /&gt;
&lt;br /&gt;
Additionally, the bonuses of an ability can be made conditional on the character's current 'wield mode' (2-handed, dual, weapon &amp;amp; shield, or universal) through the conditional integer field on the passive_abilities worksheet.&lt;br /&gt;
&lt;br /&gt;
Finally, a number of passive abilities do not define any property modifications in passive_abilites but instead have checks coded against their Ids directly in the combat resolution scripts (e.g. HasAbility( oCreature, ABILITY_TALENT_LETHALITY )). The mere presence of the ability on a creature causes a different code path to be taken in the scripts in those cases.&lt;br /&gt;
&lt;br /&gt;
Note that passive_ability benefits are not limited to abilities with use_type 3. Some active abilities also grant additional property modifying benefits to the owner.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sustained Abilities'''&lt;br /&gt;
&lt;br /&gt;
Sustained abilities (use_type = 2) are turned on and off per character and, while turned on, grant effects or property modifications to the user. &lt;br /&gt;
Most 'buffs' are implemented this way.&lt;br /&gt;
&lt;br /&gt;
Only members of the player's party are using sustained ability as the code overhead required to track them is too expensive to be used on monsters that only exist to die in an encounter with the player's party. (These creatures use duration based effects to emulate similar abilities instead).&lt;br /&gt;
&lt;br /&gt;
Most sustained abilities follow the same pattern:&lt;br /&gt;
* They do not have any activation cost, encouraging tactical use of buffs.&lt;br /&gt;
* They increase the users [[Fatigue]] property, therefore increasing the activation cost of all other abilities.&lt;br /&gt;
* They reduce the users maximum available mana or stamina by a constant value.&lt;br /&gt;
* They use cooldown to prevent the user from being too opportunistic with their use.&lt;br /&gt;
* Some abilities shut down when the user reaches 0 mana/stamina. Very powerful abilities (such as Momentum) have an associated stamina/mana drain effect to limit their use to a short or medium period of time. Creative item / buff use can be used to increase the length such an ability can be sustained.&lt;br /&gt;
&lt;br /&gt;
The benefits from sustained abilities are calculated when the ability is activated. So if a character levels up or otherwise changes stats that influence the magnitude of a sustained ability, they will not update until the ability is reactivated the next time.&lt;br /&gt;
&lt;br /&gt;
Some sustained abilities (such as Flaming Weapons) are active 'party-wide' - the caster not only sustains the ability on himself but on all his party members as well. This is controlled by the 'bPartyWide' flag in [[ABI_base.xls]]. Due to implementation limitations, party members who die or otherwise enter/exit the current party will not be affected by these abilities until they are recast. (we put low cooldown times on these abilities for that very reason).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Gameplay Design Note''' &lt;br /&gt;
* Unlike in games like Baldur's Gate, the system in DA: Origins is designed to encourage tactical use of buffs over strategical. We wanted to put an emphasis on the player making smart choices during an encounter vs. the player guessing which buffs might be useful ahead of time or having to employ save-die-reload to find out. &lt;br /&gt;
&lt;br /&gt;
* It is generally wise to run only one or two buffs all around and activate additional buffs only when needed. &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Activated Abilities'''&lt;br /&gt;
&lt;br /&gt;
Activated abilities (use_type = 4) are abilities that instantly execute their effect (see Targeting Behavior below). Most melee talents or targeted spells fall in this category. There are several sub-types of activated abilies, such as&lt;br /&gt;
&lt;br /&gt;
* Targeted, single target spells and talents (such as Winter's Grasp or Flurry)&lt;br /&gt;
* Ground targeted abilities (such as Blizzard or various Glyphs)&lt;br /&gt;
* Self targeted activated abilities.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Targeting Behavior ====&lt;br /&gt;
&lt;br /&gt;
An abilities targeting behavior is controlled by several settings in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoTarget''' is a boolean field that defines how the UI resolves targeting.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The UI will always bring up a targeting cursor. &lt;br /&gt;
|-&lt;br /&gt;
| 1 || The UI will only produce a targeting cursor if no suitable target is currently selected. e.g if the player currently has a hostile creature targeted and if the spells TargetType includes 0x4 (hostile), the ability will trigger immediately, not producing a targeting cursor. Most single target spells and talents use this setting.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Regardless of AutoTarget setting, the UI will never produce a targeting cursor if an ability is type 0x1 (self) -&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''TargetType''' is a bit mask derived from the following table and controls the behavior of the UI's targeting cursor.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
|'''Bitmask''' || '''Effect'''&lt;br /&gt;
|-&lt;br /&gt;
| 0x1  ||  Self&lt;br /&gt;
|-&lt;br /&gt;
| 0x2 || Friendly Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x4 || Hostile Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x8 || Placeable Object&lt;br /&gt;
|-&lt;br /&gt;
| 0x10 || Area of Effect Object (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20 || Ground (see details)&lt;br /&gt;
|-&lt;br /&gt;
| 0x40 || Dead Body (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x80 || Party Member&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoDraw''' is an integer boolean field that defines how a character's weapons are handled when the ability is triggered.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The ability will not affect the player's weapon sheath status.&lt;br /&gt;
|-&lt;br /&gt;
| 1 || The engine will force the player to draw/unsheathe his weapon before executing the ability. This is used for most bow and melee weapon abilities. &lt;br /&gt;
|-&lt;br /&gt;
| 2 || The engine will force the player to stow away any non staff melee weapons before executing the ability. This is used to ensure that no inappropriate animations play with weapons drawn (e.g. the player conjuring with a sword clipping through his body) and to discourage switching between melee and spellcasting on the fly.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Balancing (Cost, Cooldown, etc) ====&lt;br /&gt;
&lt;br /&gt;
Abilities in Dragon Age are balanced along several vectors, most of which boil down to simple 'use frequency'. As a general rule of thumb, the more specialized and limited the effect of an ability is, the more outrageously powerful an ability can be.&lt;br /&gt;
&lt;br /&gt;
Use frequency of abilities can be adjusted by modifying the following field in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
* Cost: This is the simple mana (spells) or stamina (talents) activation cost of an ability. It is subtracted when the conjure phase of the spell has succesfully completed (e.g. no cost for spell interruptions). Without sufficient resources to cover activation cost, the UI will not allow the player to execute the ability. The value is a constant integer and is multiplied with 1+(Current Fatigue) of the caster. &lt;br /&gt;
&lt;br /&gt;
* Cooldown: Cooldown is a constant float in seconds that defines how long the player has to wait after the successful activation of an ability until he can use it again. For abilities that apply duration based debuffs or effects to a target, cooldown is usually set slightly higher than the duration of the effect to avoid stacking by the same caster.&lt;br /&gt;
&lt;br /&gt;
* Upkeep: Defines how much mana or stamina is removed from the casters overall pool while a sustained ability is active. This naturally limits the number of sustained abilities present on a creature and ensures that the more beneficial buffs are active on the caster, the less mana is available for immediate use.&lt;br /&gt;
&lt;br /&gt;
* [[Fatigue]]: Fatigue affects use frequency only indirectly, but it prevents characters from stacking too many buffs on each other, as each sustained ability active usually adds around 5-10% fatigue to the caster.&lt;br /&gt;
&lt;br /&gt;
* Mana/Stamina drain: By reducing the mana/stamina regeneration rate on a creature, the duration for which a sustained ability can be used can be restricted. This mechanic is used only for the most powerful sustained abilities in the game, which are flagged to turn off when the caster sustaining them reaches 0 mana/stamina.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Other balancing vectors:&lt;br /&gt;
&lt;br /&gt;
* AoESize and AoeShape: Area of effect spells that deal friendly fire are location and situation restricted on normal+ difficulty (hard+ on the consoles). Since dropping an Inferno on your own party members is hardly a good idea in most cases, the usefulness of the spell becomes restricted to careful positioning and the earlier stages of combat. &lt;br /&gt;
&lt;br /&gt;
* Threat Generation: Abilities apply threat not just by damage but often by activation. Higher activation threat of an ability can balance out outrageously powerful effects by making it harder for the player to use the spell. The prime example is the Walking Bomb kind of spells which deal excellent damage, but, on higher difficulties, also make the targets very very angry at the caster.  Using these spells effectively often requires a tactical approach by the player, thus limiting their universal usefulness and offsetting their very powerful effects.&lt;br /&gt;
&lt;br /&gt;
* Threat Removal: Some abilities are designed to only provide a short term benefit (Such as 3s stun on Mindblast) but offset their weakness by removing threat from the caster, often by reinitializing the threat tables on the target, causing enemies to randomly seek new targets.&lt;br /&gt;
&lt;br /&gt;
* Conjure time: Spells with a conjure time of 1+ (Speed in [[ABI_base.xls]]) can be interrupted by damage, limiting their usefulness in melee situations or when only one party member remains on the battlefield. Many of the very powerful Area of Effect type spells use this feature. Most activated spells have a conjure time of 0, making them instant cast.&lt;br /&gt;
&lt;br /&gt;
* Range: Lower ranges force the ability user into potentially more dangerous situations, adding additional risk to the use of an ability.&lt;br /&gt;
&lt;br /&gt;
=== Q&amp;amp;A ===&lt;br /&gt;
&lt;br /&gt;
==== Q: Where do we find the exact formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Due to most abilities being unique, the only place to find the exact details on each spell is in the scripts. While a lot of data can be glanced from [[ABI_base.xls]], a lot of the detailed mechanics are very different between abilities and can only be found in the appropriate spellscript. The *_constant.nss files hold some basic values, but often get further modified in the scripts. &lt;br /&gt;
&lt;br /&gt;
This is also one of the reasons why some elements of a talent are not displayed in the UI description in game. While we can calculate cost and cooldown based on the casting character and his fatigue and other properties (and consequently display it), we can usually not calculate damage or duration as they are mitigated on the target creature: &lt;br /&gt;
&lt;br /&gt;
Displaying those values results in very misleading information (e.g. while damage seems to be higher on one ability, the mitigation mechanisms and unique side effects of another ability will make it just as good or better - in certain situations) and it turned out to be better to provide the player with general guidance than the misleading information.&lt;br /&gt;
&lt;br /&gt;
==== Q: What is Spellpower and how does it interact with abilities ====&lt;br /&gt;
&lt;br /&gt;
Spellpower is probably the most important stat for a mage character (and only exists on mage characters). It is calculated as max(Magic - 10,0) and therefore increases by one point for every point a mage spends on his Magic attribute.&lt;br /&gt;
&lt;br /&gt;
Most mage spells benefit directly from higher spellpower by increased damage, effect magnitude and duration. It also plays a role in a mages ability to overcome mental or physical resistance on a target (where applicable). The actual impact of spellpower on an ability varies from spell to spell but the most common construct equates to something like 1% increase in spell potency per point of Spellpower. Thus, items and spells that increase spellpower are very powerful as they increase the potency of every spell the mage can cast.&lt;br /&gt;
&lt;br /&gt;
Spellpower is the only factor that causes an increase of a spells potency over time, so a level 20 mage with neglected the Magic attribute would be much less powerful than a mage that didn't neglect Magic.&lt;br /&gt;
&lt;br /&gt;
Some examples:&lt;br /&gt;
&lt;br /&gt;
* The damage potential for Winter's Grasp is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.36f;&lt;br /&gt;
* The healing potential for the heal spell is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.40f;&lt;br /&gt;
* The damage over time component of blizzard is executed as ApplyEffectDamageOverTime(a[i], oCreator, ABILITY_SPELL_BLIZZARD,  (100.0f + GetCreatureSpellPower(oCreator)) * 0.1, (BLIZZARD_INTERVAL_DURATION - 0.5f), DAMAGE_TYPE_COLD);&lt;br /&gt;
&lt;br /&gt;
Note that these formulas only list the raw damage potential and do not take into account the effects of damage types, difficulty, rank, resistances, magical shields and any other mitigating factors on the target or enhancing factors on the caster. This means that just comparing the numbers will not give you an idea which spell is better or worse.&lt;br /&gt;
&lt;br /&gt;
For non-mage spells and abilities, spellpower is often substituted by an appropriate other construct (such as max(Cunning-10,0) for rogue abilities).&lt;br /&gt;
&lt;br /&gt;
==== Q: Can we have the damage formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is no damage formula for abilities, as mentioned before, each ability follows their own rules.&lt;br /&gt;
&lt;br /&gt;
In general, talent damage is based on the weapon being used (e.g. Assault does 3 melee attacks that deal weapon damage with some additional bonuses) and are modified by external cirumstances such as location, critical chance and ability to deliver a backstab and are mitigated by armor on the target.&lt;br /&gt;
&lt;br /&gt;
Spells deal damage of different damage types following a rough rule of (Constant * (Spellpower / Variable)) / [Variables] ) + Modifiers but this only tells part of the story as actual damage is dependent on the target, it's resistances, rank and a number of other factors.&lt;br /&gt;
&lt;br /&gt;
Some additional factors affecting spell damage are:&lt;br /&gt;
&lt;br /&gt;
* damage resistance.&lt;br /&gt;
* magical shields.&lt;br /&gt;
* difficulty level.&lt;br /&gt;
* elemental damage bonuses from spells or items &lt;br /&gt;
* Environmental conditions (frozen targets take less damage from fire, etc.)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the differences between damage types? ====&lt;br /&gt;
&lt;br /&gt;
A: Creatures have variable damage resistances based on their type and rank. Dragons might get 60% less damage from fire (60% fire resistance), other creatures will have different immunities. Additional effects are:&lt;br /&gt;
&lt;br /&gt;
* Electricity: In addition to normal damage, these also reduce the targets stamina (but not mana) by the same amount, making them very effective boss killers.&lt;br /&gt;
&lt;br /&gt;
* Fire: Cancels Cold based damage over time effects and applies damage over time.&lt;br /&gt;
&lt;br /&gt;
* Cold: Cancel Fire based damage over time effects and often is accompanied by slow or slipping effects.&lt;br /&gt;
&lt;br /&gt;
* Spirit: There are very few ways of increasing spirit resistance in the game, so spells dealing spirit damage are universally useful...&lt;br /&gt;
&lt;br /&gt;
* Nature: Rarely found on spells. Many creatures are resistant to this.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(This should probably go on its own wiki page)&lt;br /&gt;
&lt;br /&gt;
==== Q: Are sustained abilities mutually exclusive ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is a very limited number of sustained abilities that are mutually exclusive, usually because it makes sense. Mutually exclusive abilities cancel each other upon activation.&lt;br /&gt;
&lt;br /&gt;
* Shield stances (Shield Wall, Shield Cover, Shield Defense) are mutually exclusive.&lt;br /&gt;
* Archery stances (Aim, Rapid Fire, Defensive Fire) are mutually exclusive.&lt;br /&gt;
* Shapeshifting forms (Sorry, no Bear-Wolfspider) are mutually exclusive.&lt;br /&gt;
* Weapon Enhancement spells are too, but only for the same caster (so two mages can run two different weapon enhancements if they want to).&lt;br /&gt;
* Bard Songs are mutually exclusive.&lt;br /&gt;
* The Death Syphon and Death Magic spells are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
Technically, all abilities in [[ABI_base.xls]] that share the same 'condition_group' value are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the rules for stacking effects and damage ? ====&lt;br /&gt;
&lt;br /&gt;
A: The general rules of stacking for abilities are:&lt;br /&gt;
&lt;br /&gt;
* Identical effect from different abilities stack (e.g. getting +10 attack from one ability and +10 attack from another nets +20 attack).&lt;br /&gt;
* The effects of identical abilities stack as long as they are from different caster. (Same caster usually does not apply as cooldown often exceeds duration).&lt;br /&gt;
* Weapon enhancement spells of the same type (e.g. 2 mages with flame weapons) do not stack. The sword does not get more flaming, sorry :)&lt;br /&gt;
* Animation based effects (knockdown, stun, etc.) stack, but only the one with the highest priority is played. This is defined in the priority column in [[effects.xls]].&lt;br /&gt;
* Glyphs do stack but there is a limit of 5 active glyphs per caster.&lt;br /&gt;
* Fire and Cold DoT effects do not stack, the spell cast last will cancel any existing spell of the opposite type.&lt;br /&gt;
* Fire and Cold AoEs cancel each other, other AoEs might interact rather violently, handle with care :)&lt;br /&gt;
&lt;br /&gt;
For equipment and item based effects, the game usually stacks within the minumum and maximum clamp values of a property ([[properties.xls]]). This means that you can accumulate a lot of +damage or +critical critical chance effects, but for some stat types there is a point where you are no longer gaining any benefits (e.g. speed modification - animations can only be sped up to a certain point before breaking, so stacking momentum, haste and a weapon with a speed based effect will not result in a -3.0s attack time, sorry :p)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
For almost all effects, the total result of all property modifications on a creature are visible on the main character UI by hovering over the individual stats.&lt;br /&gt;
&lt;br /&gt;
==== Q: How does game difficulty affect abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Our approach to game difficulty dictates that the effect of your chosen setting are&lt;br /&gt;
&lt;br /&gt;
a) non punishing - You do not get less XP for chosing a lower difficulty mode, etc.&lt;br /&gt;
b) challenge scaling - Higher difficulty will reward you with greater obstacles to overcome.&lt;br /&gt;
c) fair - Lower difficulties grant benefits that gradually get removed. (This does not mean the rules are symmetric and is not true on nightmare at all. Nightmare is evil. And unfair.)&lt;br /&gt;
d) non persistent - Difficulty changes are possible on the fly, at any time and take immediate effect.&lt;br /&gt;
&lt;br /&gt;
The game is balanced so that Hard mode is challenging for a Baldur's gate veteran.&lt;br /&gt;
&lt;br /&gt;
Based on these guidelines, you can expect the following ability behaviors in game:&lt;br /&gt;
&lt;br /&gt;
* The lower the difficulty, the longer your hostile effects such as stuns will last on enemies and the shorter they will last on you.&lt;br /&gt;
* The lower the difficulty, the more damage your abilities will do.&lt;br /&gt;
* The lower the difficulty, the less likely the enemy AI will use devastating special abilities (Note: less likely does not mean 'does not use').&lt;br /&gt;
* Casual and Normal have reduced friendly or nullified fire damage damage from area effect spells. Hard and Nightmare require careful positioning and tactical use of spells.&lt;br /&gt;
* The higher the difficulty, the more careful you need to manage threat when using spells and abilities (The AI becomes smarter about picking targets).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What is spell affinity ? ====&lt;br /&gt;
&lt;br /&gt;
A: Spell Affinity was a design we toyed with for a while during development but decided not to implement.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: How does Rank Based Mitigation Work ? ====&lt;br /&gt;
&lt;br /&gt;
A: In line with Dragon Age: Origin's asymmetric approach to rules, the game uses creature ranks (instead of levels) in addition to stats and resistances to define how creatures get affected by abilities. In short: Boss monsters get affected differently by abilities and effects than Lieutenants or Critters. &lt;br /&gt;
&lt;br /&gt;
The rank system is the primary balancing vector for the games difficulty levels and profoundly affects all aspects of combat. The gory details of this system are defined in creature_ranks.xls and difficulty.xls.&lt;br /&gt;
&lt;br /&gt;
Rank mitigation affects not just damage in- and output of a creature, but also the duration that hostile effects persist on it and is different for each difficulty level of the game. Note that party members have their own rank in this system and are handled differently from other creatures in some cases. &lt;br /&gt;
&lt;br /&gt;
Below is the formula used for rank based effect duration mitigation: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
// sys_resistances_h&lt;br /&gt;
// @brief Returns an effect duration scaled by rank of oCreature and game difficulty&lt;br /&gt;
// @author Georg&lt;br /&gt;
float GetRankAdjustedEffectDuration(object oCreature, float fDur)&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    // Georg: This deserves some explanation:&lt;br /&gt;
    //&lt;br /&gt;
    //        One of the core issues when designing the combat system was always&lt;br /&gt;
    //        the fact that the story called for sequences during the game in which&lt;br /&gt;
    //        your main character acts solo.&lt;br /&gt;
    //&lt;br /&gt;
    //        Characters reliant on special abilities, such as rogues, would require&lt;br /&gt;
    //        them to be very effective in order to beat enemies that a standard tank&lt;br /&gt;
    //        can plow through. However, if these abilities would maintain the same&lt;br /&gt;
    //        effectiveness in a full party, most encounters would turn into a stunfest.&lt;br /&gt;
    //&lt;br /&gt;
    //        The solution is to add 1 second flat to each detrimental effect duration&lt;br /&gt;
    //        lasting at least 1 second for each unoccupied slot in the party - before applying&lt;br /&gt;
    //        rank and difficulty modifiers. This also makes solo play a bit more viable.&lt;br /&gt;
    //&lt;br /&gt;
    //        This is in addition to the diminishing returns on quickly successive stuns.&lt;br /&gt;
    //&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    if (!IsPartyMember(oCreature))&lt;br /&gt;
    {&lt;br /&gt;
        float fPartySizeModifier = IntToFloat(Max(0,4 - GetArraySize(GetPartyList())));&lt;br /&gt;
&lt;br /&gt;
        if (fDur &amp;gt;= 1.0f)&lt;br /&gt;
        {&lt;br /&gt;
            fDur += fPartySizeModifier;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    float fRankDurMod = Diff_GetDurationModifier(oCreature);&lt;br /&gt;
    if (fRankDurMod &amp;gt;0.0f)&lt;br /&gt;
    {&lt;br /&gt;
        return (fDur * fRankDurMod);&lt;br /&gt;
    }&lt;br /&gt;
    else&lt;br /&gt;
    {&lt;br /&gt;
     return fDur;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripts]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What does 'asymmetric rules system' mean ? ====&lt;br /&gt;
&lt;br /&gt;
The goal behind Dragon Age: Origin's rule system was to create a fun and challenging video game experience first and foremost. &lt;br /&gt;
&lt;br /&gt;
We describe the rules as 'asymmetric' because a subset of the game rules treats player controlled characters and monsters differently, which is a deviation from pen and paper rule design that often require player and opponents to be treated exactly the same. &lt;br /&gt;
&lt;br /&gt;
Notable Examples:&lt;br /&gt;
* Party members never die permanently (get shattered, etc.)&lt;br /&gt;
* Differently ranked creatures (including party members) get affected for different durations by effects&lt;br /&gt;
* In limited situations in the game, we apply benefits to the player to overcome greater odds than they would usually be able to. &lt;br /&gt;
* Some abilities will work diferently when deployed against the party (although the visual results might be identical).&lt;br /&gt;
* Elimination of instant death situations (not fun!) against players but not against monsters (fun!).&lt;br /&gt;
* Sustained abilities only work for players (the overhead is not justified for monsters that won't ever reappear after they die).&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Ability&amp;diff=7359</id>
		<title>Ability</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Ability&amp;diff=7359"/>
				<updated>2009-10-31T02:37:03Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Q: Are sustained abilities mutually exclusive ? */ formatting&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=== Overview ===&lt;br /&gt;
The Ability System is used to handle Spells, Talents, Skills, and Item Abilities in Dragon Age.&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Spells, Talents, Skills and item abilities all use the same backend in the game, a mostly script implemented system relying heavily on two dimensional data arrays. &lt;br /&gt;
&lt;br /&gt;
The most important 2da file for abilities is '''[[ABI_base.xls]]''', as it defines each ability and all aspects of execution and handling in both scripting and engine code.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Ability Design Notes''' &lt;br /&gt;
&lt;br /&gt;
When creating an ability in Dragon Age: Origins, we generally stick to the following guidelines&lt;br /&gt;
&lt;br /&gt;
* Keep it useful. &lt;br /&gt;
Some constant benefits (such as an increase in Attack or Defense) stay useful for the duration of the game as the progression of the related properties are slow. &lt;br /&gt;
For other effects, such as damage, a constant value would mean that the ability will become progressively worse through the game as damage needed to drop enemies increases from level to level. In such cases, the ability should be tied in some fashion to a Spellpower (for spells) or another relevant trait (such as cunning for rogues) to ensure they stay useful throughout the game. &lt;br /&gt;
&lt;br /&gt;
* No repetition. &lt;br /&gt;
Each ability in Dragon Age: Origins is unique. No incremental abilities such as 'fireball I, fireball II, etc.'. Skills are exempt from this rule. Remember that the Damage Types dramatically alter the actual effect of an ability (such as lightning always draining stamina alongside doing damage), so having similar damaging abilities in different trees is usually fine.&lt;br /&gt;
&lt;br /&gt;
* Thematic matching.&lt;br /&gt;
Abilities within the same chain should follow a common theme. &lt;br /&gt;
&lt;br /&gt;
* Avoid binary abilities. Design hit heavy.&lt;br /&gt;
Avoid abilities that are hit-or-miss. Generally, abilities should hit whenever possible and use target side mitigation of effects (resistance checks, damage mitigation) instead of 'hit or miss' mechanics. Melee abilities may use the normal attack resolution routines but should always perform their attacks at a bonus. Use rank based mitigation and resistances to allow for very powerful effects that do not trivialize boss battles. &lt;br /&gt;
&lt;br /&gt;
* Use meaningful effects&lt;br /&gt;
Abilities should always be worth it. Don't do minor effects (+1 attack). The player should always be able to see the effect of the ability in game (not necessarily visually, but at least through increased damage, etc.). The first ability in a chain should, whenever possible, be active. The fourth ability in a chain should always have the biggest 'bang-for-the-buck' factor. Abilities lower in the chain should have shorter cooldowns. Do not allow instant death on bosses and elite bosses.&lt;br /&gt;
&lt;br /&gt;
* Avoid 'zero-sum' abilities&lt;br /&gt;
When possible, avoid 'zero-sum' abilities that trade a penalty for a benefit (e.g. increase defense but decrease attack). There are a number of these abilities that are valid (such as aim), but balancing them and keeping them useful is hard and requires a lot of work. This obviously does not apply to drastic abilities such as blood magic.&lt;br /&gt;
&lt;br /&gt;
* No emulation of defining class capabilities&lt;br /&gt;
Never ever grant a basic class capability from one class to another class via abilities. This means no invisibility or magical unlock spells for mages, as these are defining capabilities of the rogue class. No weapon talents for mages. No magic spells or large, targeted area of effects for warriors or rogues. Items might blur this line if the cost is balanced properly (e.g. grenades).&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Basic Ability Types ====&lt;br /&gt;
&lt;br /&gt;
Abilities are divided into 4 subtypes, as defined in the 'abilitytype' column in [[ABI_base.xls]]:&lt;br /&gt;
&lt;br /&gt;
* Talents - Abilities used by warriors and rogues, usually non magical in nature. (abilitytype=1)&lt;br /&gt;
* Spells - Abilities used by mages, either spell or passive abilities.  (abilitytype=2)&lt;br /&gt;
* Skills - Abilities usable by all classes, such as Survival and Combat training (abilitytype=3).&lt;br /&gt;
* Items  - Abilities present on an item that are triggered when the item is used on the quickbar. (ability_type=4)&lt;br /&gt;
&lt;br /&gt;
Note: Talents do not show up on mages and spells do not show up on rogue or warrior characters, so to create abilities that can be used by all classes, abilitytype 3 (Skill) must be used. To define under which heading an ability shows up on the character's talent/spell page, the field 'guitype' is used. It resolves against [[guitype.xls]] which lists all known headings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are 3 basic ability types in the game, defined by the field 'use_type' in [[ABI_base.xls]].&lt;br /&gt;
&lt;br /&gt;
'''Passive Abilities''' &lt;br /&gt;
&lt;br /&gt;
Passive abilities (use_type = 3) grant persistent or conditionally persistent bonuses or penalties to the creature that has the ability. &lt;br /&gt;
&lt;br /&gt;
A passive ability may grant up to 3 modifications to creature properties ([[properties.xls]]). Those modifications are defined in the passive_abilities worksheet of [[ABI_base.xls]] and linked to the ability through the passive_id column in ABI_base.xls.&lt;br /&gt;
&lt;br /&gt;
Additionally, the bonuses of an ability can be made conditional on the character's current 'wield mode' (2-handed, dual, weapon &amp;amp; shield, or universal) through the conditional integer field on the passive_abilities worksheet.&lt;br /&gt;
&lt;br /&gt;
Finally, a number of passive abilities do not define any property modifications in passive_abilites but instead have checks coded against their Ids directly in the combat resolution scripts (e.g. HasAbility( oCreature, ABILITY_TALENT_LETHALITY )). The mere presence of the ability on a creature causes a different code path to be taken in the scripts in those cases.&lt;br /&gt;
&lt;br /&gt;
Note that passive_ability benefits are not limited to abilities with use_type 3. Some active abilities also grant additional property modifying benefits to the owner.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sustained Abilities'''&lt;br /&gt;
&lt;br /&gt;
Sustained abilities (use_type = 2) are turned on and off per character and, while turned on, grant effects or property modifications to the user. &lt;br /&gt;
Most 'buffs' are implemented this way.&lt;br /&gt;
&lt;br /&gt;
Only members of the player's party are using sustained ability as the code overhead required to track them is too expensive to be used on monsters that only exist to die in an encounter with the player's party. (These creatures use duration based effects to emulate similar abilities instead).&lt;br /&gt;
&lt;br /&gt;
Most sustained abilities follow the same pattern:&lt;br /&gt;
* They do not have any activation cost, encouraging tactical use of buffs.&lt;br /&gt;
* They increase the users [[Fatigue]] property, therefore increasing the activation cost of all other abilities.&lt;br /&gt;
* They reduce the users maximum available mana or stamina by a constant value.&lt;br /&gt;
* They use cooldown to prevent the user from being too opportunistic with their use.&lt;br /&gt;
* Some abilities shut down when the user reaches 0 mana/stamina. Very powerful abilities (such as Momentum) have an associated stamina/mana drain effect to limit their use to a short or medium period of time. Creative item / buff use can be used to increase the length such an ability can be sustained.&lt;br /&gt;
&lt;br /&gt;
The benefits from sustained abilities are calculated when the ability is activated. So if a character levels up or otherwise changes stats that influence the magnitude of a sustained ability, they will not update until the ability is reactivated the next time.&lt;br /&gt;
&lt;br /&gt;
Some sustained abilities (such as Flaming Weapons) are active 'party-wide' - the caster not only sustains the ability on himself but on all his party members as well. This is controlled by the 'bPartyWide' flag in [[ABI_base.xls]]. Due to implementation limitations, party members who die or otherwise enter/exit the current party will not be affected by these abilities until they are recast. (we put low cooldown times on these abilities for that very reason).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Gameplay Design Note''' &lt;br /&gt;
* Unlike in games like Baldur's Gate, the system in DA: Origins is designed to encourage tactical use of buffs over strategical. We wanted to put an emphasis on the player making smart choices during an encounter vs. the player guessing which buffs might be useful ahead of time or having to employ save-die-reload to find out. &lt;br /&gt;
&lt;br /&gt;
* It is generally wise to run only one or two buffs all around and activate additional buffs only when needed. &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Activated Abilities'''&lt;br /&gt;
&lt;br /&gt;
Activated abilities (use_type = 4) are abilities that instantly execute their effect (see Targeting Behavior below). Most melee talents or targeted spells fall in this category. There are several sub-types of activated abilies, such as&lt;br /&gt;
&lt;br /&gt;
* Targeted, single target spells and talents (such as Winter's Grasp or Flurry)&lt;br /&gt;
* Ground targeted abilities (such as Blizzard or various Glyphs)&lt;br /&gt;
* Self targeted activated abilities.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Targeting Behavior ====&lt;br /&gt;
&lt;br /&gt;
An abilities targeting behavior is controlled by several settings in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoTarget''' is a boolean field that defines how the UI resolves targeting.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The UI will always bring up a targeting cursor. &lt;br /&gt;
|-&lt;br /&gt;
| 1 || The UI will only produce a targeting cursor if no suitable target is currently selected. e.g if the player currently has a hostile creature targeted and if the spells TargetType includes 0x4 (hostile), the ability will trigger immediately, not producing a targeting cursor. Most single target spells and talents use this setting.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Regardless of AutoTarget setting, the UI will never produce a targeting cursor if an ability is type 0x1 (self) -&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''TargetType''' is a bit mask derived from the following table and controls the behavior of the UI's targeting cursor.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
|'''Bitmask''' || '''Effect'''&lt;br /&gt;
|-&lt;br /&gt;
| 0x1  ||  Self&lt;br /&gt;
|-&lt;br /&gt;
| 0x2 || Friendly Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x4 || Hostile Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x8 || Placeable Object&lt;br /&gt;
|-&lt;br /&gt;
| 0x10 || Area of Effect Object (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20 || Ground (see details)&lt;br /&gt;
|-&lt;br /&gt;
| 0x40 || Dead Body (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x80 || Party Member&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoDraw''' is an integer boolean field that defines how a character's weapons are handled when the ability is triggered.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The ability will not affect the player's weapon sheath status.&lt;br /&gt;
|-&lt;br /&gt;
| 1 || The engine will force the player to draw/unsheathe his weapon before executing the ability. This is used for most bow and melee weapon abilities. &lt;br /&gt;
|-&lt;br /&gt;
| 2 || The engine will force the player to stow away any non staff melee weapons before executing the ability. This is used to ensure that no inappropriate animations play with weapons drawn (e.g. the player conjuring with a sword clipping through his body) and to discourage switching between melee and spellcasting on the fly.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Balancing (Cost, Cooldown, etc) ====&lt;br /&gt;
&lt;br /&gt;
Abilities in Dragon Age are balanced along several vectors, most of which boil down to simple 'use frequency'. As a general rule of thumb, the more specialized and limited the effect of an ability is, the more outrageously powerful an ability can be.&lt;br /&gt;
&lt;br /&gt;
Use frequency of abilities can be adjusted by modifying the following field in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
* Cost: This is the simple mana (spells) or stamina (talents) activation cost of an ability. It is subtracted when the conjure phase of the spell has succesfully completed (e.g. no cost for spell interruptions). Without sufficient resources to cover activation cost, the UI will not allow the player to execute the ability. The value is a constant integer and is multiplied with 1+(Current Fatigue) of the caster. &lt;br /&gt;
&lt;br /&gt;
* Cooldown: Cooldown is a constant float in seconds that defines how long the player has to wait after the successful activation of an ability until he can use it again. For abilities that apply duration based debuffs or effects to a target, cooldown is usually set slightly higher than the duration of the effect to avoid stacking by the same caster.&lt;br /&gt;
&lt;br /&gt;
* Upkeep: Defines how much mana or stamina is removed from the casters overall pool while a sustained ability is active. This naturally limits the number of sustained abilities present on a creature and ensures that the more beneficial buffs are active on the caster, the less mana is available for immediate use.&lt;br /&gt;
&lt;br /&gt;
* [[Fatigue]]: Fatigue affects use frequency only indirectly, but it prevents characters from stacking too many buffs on each other, as each sustained ability active usually adds around 5-10% fatigue to the caster.&lt;br /&gt;
&lt;br /&gt;
* Mana/Stamina drain: By reducing the mana/stamina regeneration rate on a creature, the duration for which a sustained ability can be used can be restricted. This mechanic is used only for the most powerful sustained abilities in the game, which are flagged to turn off when the caster sustaining them reaches 0 mana/stamina.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Other balancing vectors:&lt;br /&gt;
&lt;br /&gt;
* AoESize and AoeShape: Area of effect spells that deal friendly fire are location and situation restricted on normal+ difficulty (hard+ on the consoles). Since dropping an Inferno on your own party members is hardly a good idea in most cases, the usefulness of the spell becomes restricted to careful positioning and the earlier stages of combat. &lt;br /&gt;
&lt;br /&gt;
* Threat Generation: Abilities apply threat not just by damage but often by activation. Higher activation threat of an ability can balance out outrageously powerful effects by making it harder for the player to use the spell. The prime example is the Walking Bomb kind of spells which deal excellent damage, but, on higher difficulties, also make the targets very very angry at the caster.  Using these spells effectively often requires a tactical approach by the player, thus limiting their universal usefulness and offsetting their very powerful effects.&lt;br /&gt;
&lt;br /&gt;
* Threat Removal: Some abilities are designed to only provide a short term benefit (Such as 3s stun on Mindblast) but offset their weakness by removing threat from the caster, often by reinitializing the threat tables on the target, causing enemies to randomly seek new targets.&lt;br /&gt;
&lt;br /&gt;
* Conjure time: Spells with a conjure time of 1+ (Speed in [[ABI_base.xls]]) can be interrupted by damage, limiting their usefulness in melee situations or when only one party member remains on the battlefield. Many of the very powerful Area of Effect type spells use this feature. Most activated spells have a conjure time of 0, making them instant cast.&lt;br /&gt;
&lt;br /&gt;
* Range: Lower ranges force the ability user into potentially more dangerous situations, adding additional risk to the use of an ability.&lt;br /&gt;
&lt;br /&gt;
=== Q&amp;amp;A ===&lt;br /&gt;
&lt;br /&gt;
==== Q: Where do we find the exact formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Due to most abilities being unique, the only place to find the exact details on each spell is in the scripts. While a lot of data can be glanced from [[ABI_base.xls]], a lot of the detailed mechanics are very different between abilities and can only be found in the appropriate spellscript. The *_constant.nss files hold some basic values, but often get further modified in the scripts. &lt;br /&gt;
&lt;br /&gt;
This is also one of the reasons why some elements of a talent are not displayed in the UI description in game. While we can calculate cost and cooldown based on the casting character and his fatigue and other properties (and consequently display it), we can usually not calculate damage or duration as they are mitigated on the target creature: &lt;br /&gt;
&lt;br /&gt;
Displaying those values results in very misleading information (e.g. while damage seems to be higher on one ability, the mitigation mechanisms and unique side effects of another ability will make it just as good or better - in certain situations) and it turned out to be better to provide the player with general guidance than the misleading information.&lt;br /&gt;
&lt;br /&gt;
==== Q: What is Spellpower and how does it interact with abilities ====&lt;br /&gt;
&lt;br /&gt;
Spellpower is probably the most important stat for a mage character (and only exists on mage characters). It is calculated as max(Magic - 10,0) and therefore increases by one point for every point a mage spends on his Magic attribute.&lt;br /&gt;
&lt;br /&gt;
Most mage spells benefit directly from higher spellpower by increased damage, effect magnitude and duration. It also plays a role in a mages ability to overcome mental or physical resistance on a target (where applicable). The actual impact of spellpower on an ability varies from spell to spell but the most common construct equates to something like 1% increase in spell potency per point of Spellpower. Thus, items and spells that increase spellpower are very powerful as they increase the potency of every spell the mage can cast.&lt;br /&gt;
&lt;br /&gt;
Spellpower is the only factor that causes an increase of a spells potency over time, so a level 20 mage with neglected the Magic attribute would be much less powerful than a mage that didn't neglect Magic.&lt;br /&gt;
&lt;br /&gt;
Some examples:&lt;br /&gt;
&lt;br /&gt;
* The damage potential for Winter's Grasp is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.36f;&lt;br /&gt;
* The healing potential for the heal spell is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.40f;&lt;br /&gt;
* The damage over time component of blizzard is executed as ApplyEffectDamageOverTime(a[i], oCreator, ABILITY_SPELL_BLIZZARD,  (100.0f + GetCreatureSpellPower(oCreator)) * 0.1, (BLIZZARD_INTERVAL_DURATION - 0.5f), DAMAGE_TYPE_COLD);&lt;br /&gt;
&lt;br /&gt;
Note that these formulas only list the raw damage potential and do not take into account the effects of damage types, difficulty, rank, resistances, magical shields and any other mitigating factors on the target or enhancing factors on the caster. This means that just comparing the numbers will not give you an idea which spell is better or worse.&lt;br /&gt;
&lt;br /&gt;
For non-mage spells and abilities, spellpower is often substituted by an appropriate other construct (such as max(Cunning-10,0) for rogue abilities).&lt;br /&gt;
&lt;br /&gt;
==== Q: Can we have the damage formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is no damage formula for abilities, as mentioned before, each ability follows their own rules.&lt;br /&gt;
&lt;br /&gt;
In general, talent damage is based on the weapon being used (e.g. Assault does 3 melee attacks that deal weapon damage with some additional bonuses) and are modified by external cirumstances such as location, critical chance and ability to deliver a backstab and are mitigated by armor on the target.&lt;br /&gt;
&lt;br /&gt;
Spells deal damage of different damage types following a rough rule of (Constant * (Spellpower / Variable)) / [Variables] ) + Modifiers but this only tells part of the story as actual damage is dependent on the target, it's resistances, rank and a number of other factors.&lt;br /&gt;
&lt;br /&gt;
Some additional factors affecting spell damage are:&lt;br /&gt;
&lt;br /&gt;
* damage resistance.&lt;br /&gt;
* magical shields.&lt;br /&gt;
* difficulty level.&lt;br /&gt;
* elemental damage bonuses from spells or items &lt;br /&gt;
* Environmental conditions (frozen targets take less damage from fire, etc.)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the differences between damage types? ====&lt;br /&gt;
&lt;br /&gt;
A: Creatures have variable damage resistances based on their type and rank. Dragons might get 60% less damage from fire (60% fire resistance), other creatures will have different immunities. Additional effects are:&lt;br /&gt;
&lt;br /&gt;
* Electricity: In addition to normal damage, these also reduce the targets stamina (but not mana) by the same amount, making them very effective boss killers.&lt;br /&gt;
&lt;br /&gt;
* Fire: Cancels Cold based damage over time effects and applies damage over time.&lt;br /&gt;
&lt;br /&gt;
* Cold: Cancel Fire based damage over time effects and often is accompanied by slow or slipping effects.&lt;br /&gt;
&lt;br /&gt;
* Spirit: There are very few ways of increasing spirit resistance in the game, so spells dealing spirit damage are universally useful...&lt;br /&gt;
&lt;br /&gt;
* Nature: Rarely found on spells. Many creatures are resistant to this.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(This should probably go on its own wiki page)&lt;br /&gt;
&lt;br /&gt;
==== Q: Are sustained abilities mutually exclusive ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is a very limited number of sustained abilities that are mutually exclusive, usually because it makes sense. Mutually exclusive abilities cancel each other upon activation.&lt;br /&gt;
&lt;br /&gt;
* Shield stances (Shield Wall, Shield Cover, Shield Defense) are mutually exclusive.&lt;br /&gt;
* Archery stances (Aim, Rapid Fire, Defensive Fire) are mutually exclusive.&lt;br /&gt;
* Shapeshifting forms (Sorry, no Bear-Wolfspider) are mutually exclusive.&lt;br /&gt;
* Weapon Enhancement spells are too, but only for the same caster (so two mages can run two different weapon enhancements if they want to).&lt;br /&gt;
* Bard Songs are mutually exclusive.&lt;br /&gt;
* The Death Syphon and Death Magic spells are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
Technically, all abilities in [[ABI_base.xls]] that share the same 'condition_group' value are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the rules for stacking effects and damage ? ====&lt;br /&gt;
&lt;br /&gt;
A: The general rules of stacking for abilities are:&lt;br /&gt;
&lt;br /&gt;
* Identical effect from different abilities stack (e.g. getting +10 attack from one ability and +10 attack from another nets +20 attack).&lt;br /&gt;
* The effects of identical abilities stack as long as they are from different caster. (Same caster usually does not apply as cooldown often exceeds duration).&lt;br /&gt;
* Weapon enhancement spells of the same type (e.g. 2 mages with flame weapons) do not stack. The sword does not get more flaming, sorry :)&lt;br /&gt;
* Animation based effects (knockdown, stun, etc.) stack, but only the one with the highest priority is played. This is defined in the priority column in effects.xls. &lt;br /&gt;
* Glyphs do stack but there is a limit of 5 active glyphs per caster.&lt;br /&gt;
* Fire and Cold DoT effects do not stack, the spell cast last will cancel any existing spell of the opposite type.&lt;br /&gt;
* Fire and Cold AoEs cancel each other, other AoEs might interact rather violently, handle with care :)&lt;br /&gt;
&lt;br /&gt;
For equipment and item based effects, the game usually stacks within the minumum and maximum clamp values of a property (properties.xls). This means that you can accumulate a lot of +damage or +critical critical chance effects, but for some type of stats there is a point where you are no longer gaining any benefits (e.g. speed modification - animations can only be sped up to a certain point before breaking, so stacking momentum, haste and a weapon with a speed based effect will not result in a -3.0s attack time, sorry :p)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
For almost all effects, the total result of all property modifications on a creature are visible on the main character UI by hovering over the individual stats.&lt;br /&gt;
&lt;br /&gt;
==== Q: How does game difficulty affect abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Our approach to game difficulty dictates that the effect of your chosen setting are&lt;br /&gt;
&lt;br /&gt;
a) non punishing - You do not get less XP for chosing a lower difficulty mode, etc.&lt;br /&gt;
b) challenge scaling - Higher difficulty will reward you with greater obstacles to overcome.&lt;br /&gt;
c) fair - Lower difficulties grant benefits that gradually get removed. (This does not mean the rules are symmetric and is not true on nightmare at all. Nightmare is evil. And unfair.)&lt;br /&gt;
d) non persistent - Difficulty changes are possible on the fly, at any time and take immediate effect.&lt;br /&gt;
&lt;br /&gt;
The game is balanced so that Hard mode is challenging for a Baldur's gate veteran.&lt;br /&gt;
&lt;br /&gt;
Based on these guidelines, you can expect the following ability behaviors in game:&lt;br /&gt;
&lt;br /&gt;
* The lower the difficulty, the longer your hostile effects such as stuns will last on enemies and the shorter they will last on you.&lt;br /&gt;
* The lower the difficulty, the more damage your abilities will do.&lt;br /&gt;
* The lower the difficulty, the less likely the enemy AI will use devastating special abilities (Note: less likely does not mean 'does not use').&lt;br /&gt;
* Casual and Normal have reduced friendly or nullified fire damage damage from area effect spells. Hard and Nightmare require careful positioning and tactical use of spells.&lt;br /&gt;
* The higher the difficulty, the more careful you need to manage threat when using spells and abilities (The AI becomes smarter about picking targets).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What is spell affinity ? ====&lt;br /&gt;
&lt;br /&gt;
A: Spell Affinity was a design we toyed with for a while during development but decided not to implement.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: How does Rank Based Mitigation Work ? ====&lt;br /&gt;
&lt;br /&gt;
A: In line with Dragon Age: Origin's asymmetric approach to rules, the game uses creature ranks (instead of levels) in addition to stats and resistances to define how creatures get affected by abilities. In short: Boss monsters get affected differently by abilities and effects than Lieutenants or Critters. &lt;br /&gt;
&lt;br /&gt;
The rank system is the primary balancing vector for the games difficulty levels and profoundly affects all aspects of combat. The gory details of this system are defined in creature_ranks.xls and difficulty.xls.&lt;br /&gt;
&lt;br /&gt;
Rank mitigation affects not just damage in- and output of a creature, but also the duration that hostile effects persist on it and is different for each difficulty level of the game. Note that party members have their own rank in this system and are handled differently from other creatures in some cases. &lt;br /&gt;
&lt;br /&gt;
Below is the formula used for rank based effect duration mitigation: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
// sys_resistances_h&lt;br /&gt;
// @brief Returns an effect duration scaled by rank of oCreature and game difficulty&lt;br /&gt;
// @author Georg&lt;br /&gt;
float GetRankAdjustedEffectDuration(object oCreature, float fDur)&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    // Georg: This deserves some explanation:&lt;br /&gt;
    //&lt;br /&gt;
    //        One of the core issues when designing the combat system was always&lt;br /&gt;
    //        the fact that the story called for sequences during the game in which&lt;br /&gt;
    //        your main character acts solo.&lt;br /&gt;
    //&lt;br /&gt;
    //        Characters reliant on special abilities, such as rogues, would require&lt;br /&gt;
    //        them to be very effective in order to beat enemies that a standard tank&lt;br /&gt;
    //        can plow through. However, if these abilities would maintain the same&lt;br /&gt;
    //        effectiveness in a full party, most encounters would turn into a stunfest.&lt;br /&gt;
    //&lt;br /&gt;
    //        The solution is to add 1 second flat to each detrimental effect duration&lt;br /&gt;
    //        lasting at least 1 second for each unoccupied slot in the party - before applying&lt;br /&gt;
    //        rank and difficulty modifiers. This also makes solo play a bit more viable.&lt;br /&gt;
    //&lt;br /&gt;
    //        This is in addition to the diminishing returns on quickly successive stuns.&lt;br /&gt;
    //&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    if (!IsPartyMember(oCreature))&lt;br /&gt;
    {&lt;br /&gt;
        float fPartySizeModifier = IntToFloat(Max(0,4 - GetArraySize(GetPartyList())));&lt;br /&gt;
&lt;br /&gt;
        if (fDur &amp;gt;= 1.0f)&lt;br /&gt;
        {&lt;br /&gt;
            fDur += fPartySizeModifier;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    float fRankDurMod = Diff_GetDurationModifier(oCreature);&lt;br /&gt;
    if (fRankDurMod &amp;gt;0.0f)&lt;br /&gt;
    {&lt;br /&gt;
        return (fDur * fRankDurMod);&lt;br /&gt;
    }&lt;br /&gt;
    else&lt;br /&gt;
    {&lt;br /&gt;
     return fDur;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripts]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What does 'asymmetric rules system' mean ? ====&lt;br /&gt;
&lt;br /&gt;
The goal behind Dragon Age: Origin's rule system was to create a fun and challenging video game experience first and foremost. &lt;br /&gt;
&lt;br /&gt;
We describe the rules as 'asymmetric' because a subset of the game rules treats player controlled characters and monsters differently, which is a deviation from pen and paper rule design that often require player and opponents to be treated exactly the same. &lt;br /&gt;
&lt;br /&gt;
Notable Examples:&lt;br /&gt;
* Party members never die permanently (get shattered, etc.)&lt;br /&gt;
* Differently ranked creatures (including party members) get affected for different durations by effects&lt;br /&gt;
* In limited situations in the game, we apply benefits to the player to overcome greater odds than they would usually be able to. &lt;br /&gt;
* Some abilities will work diferently when deployed against the party (although the visual results might be identical).&lt;br /&gt;
* Elimination of instant death situations (not fun!) against players but not against monsters (fun!).&lt;br /&gt;
* Sustained abilities only work for players (the overhead is not justified for monsters that won't ever reappear after they die).&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Ability&amp;diff=7358</id>
		<title>Ability</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Ability&amp;diff=7358"/>
				<updated>2009-10-31T02:27:46Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Q: Are sustained abilities mutually exclusive ? */ grammar&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=== Overview ===&lt;br /&gt;
The Ability System is used to handle Spells, Talents, Skills, and Item Abilities in Dragon Age.&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Spells, Talents, Skills and item abilities all use the same backend in the game, a mostly script implemented system relying heavily on two dimensional data arrays. &lt;br /&gt;
&lt;br /&gt;
The most important 2da file for abilities is '''[[ABI_base.xls]]''', as it defines each ability and all aspects of execution and handling in both scripting and engine code.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Ability Design Notes''' &lt;br /&gt;
&lt;br /&gt;
When creating an ability in Dragon Age: Origins, we generally stick to the following guidelines&lt;br /&gt;
&lt;br /&gt;
* Keep it useful. &lt;br /&gt;
Some constant benefits (such as an increase in Attack or Defense) stay useful for the duration of the game as the progression of the related properties are slow. &lt;br /&gt;
For other effects, such as damage, a constant value would mean that the ability will become progressively worse through the game as damage needed to drop enemies increases from level to level. In such cases, the ability should be tied in some fashion to a Spellpower (for spells) or another relevant trait (such as cunning for rogues) to ensure they stay useful throughout the game. &lt;br /&gt;
&lt;br /&gt;
* No repetition. &lt;br /&gt;
Each ability in Dragon Age: Origins is unique. No incremental abilities such as 'fireball I, fireball II, etc.'. Skills are exempt from this rule. Remember that the Damage Types dramatically alter the actual effect of an ability (such as lightning always draining stamina alongside doing damage), so having similar damaging abilities in different trees is usually fine.&lt;br /&gt;
&lt;br /&gt;
* Thematic matching.&lt;br /&gt;
Abilities within the same chain should follow a common theme. &lt;br /&gt;
&lt;br /&gt;
* Avoid binary abilities. Design hit heavy.&lt;br /&gt;
Avoid abilities that are hit-or-miss. Generally, abilities should hit whenever possible and use target side mitigation of effects (resistance checks, damage mitigation) instead of 'hit or miss' mechanics. Melee abilities may use the normal attack resolution routines but should always perform their attacks at a bonus. Use rank based mitigation and resistances to allow for very powerful effects that do not trivialize boss battles. &lt;br /&gt;
&lt;br /&gt;
* Use meaningful effects&lt;br /&gt;
Abilities should always be worth it. Don't do minor effects (+1 attack). The player should always be able to see the effect of the ability in game (not necessarily visually, but at least through increased damage, etc.). The first ability in a chain should, whenever possible, be active. The fourth ability in a chain should always have the biggest 'bang-for-the-buck' factor. Abilities lower in the chain should have shorter cooldowns. Do not allow instant death on bosses and elite bosses.&lt;br /&gt;
&lt;br /&gt;
* Avoid 'zero-sum' abilities&lt;br /&gt;
When possible, avoid 'zero-sum' abilities that trade a penalty for a benefit (e.g. increase defense but decrease attack). There are a number of these abilities that are valid (such as aim), but balancing them and keeping them useful is hard and requires a lot of work. This obviously does not apply to drastic abilities such as blood magic.&lt;br /&gt;
&lt;br /&gt;
* No emulation of defining class capabilities&lt;br /&gt;
Never ever grant a basic class capability from one class to another class via abilities. This means no invisibility or magical unlock spells for mages, as these are defining capabilities of the rogue class. No weapon talents for mages. No magic spells or large, targeted area of effects for warriors or rogues. Items might blur this line if the cost is balanced properly (e.g. grenades).&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Basic Ability Types ====&lt;br /&gt;
&lt;br /&gt;
Abilities are divided into 4 subtypes, as defined in the 'abilitytype' column in [[ABI_base.xls]]:&lt;br /&gt;
&lt;br /&gt;
* Talents - Abilities used by warriors and rogues, usually non magical in nature. (abilitytype=1)&lt;br /&gt;
* Spells - Abilities used by mages, either spell or passive abilities.  (abilitytype=2)&lt;br /&gt;
* Skills - Abilities usable by all classes, such as Survival and Combat training (abilitytype=3).&lt;br /&gt;
* Items  - Abilities present on an item that are triggered when the item is used on the quickbar. (ability_type=4)&lt;br /&gt;
&lt;br /&gt;
Note: Talents do not show up on mages and spells do not show up on rogue or warrior characters, so to create abilities that can be used by all classes, abilitytype 3 (Skill) must be used. To define under which heading an ability shows up on the character's talent/spell page, the field 'guitype' is used. It resolves against [[guitype.xls]] which lists all known headings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are 3 basic ability types in the game, defined by the field 'use_type' in [[ABI_base.xls]].&lt;br /&gt;
&lt;br /&gt;
'''Passive Abilities''' &lt;br /&gt;
&lt;br /&gt;
Passive abilities (use_type = 3) grant persistent or conditionally persistent bonuses or penalties to the creature that has the ability. &lt;br /&gt;
&lt;br /&gt;
A passive ability may grant up to 3 modifications to creature properties ([[properties.xls]]). Those modifications are defined in the passive_abilities worksheet of [[ABI_base.xls]] and linked to the ability through the passive_id column in ABI_base.xls.&lt;br /&gt;
&lt;br /&gt;
Additionally, the bonuses of an ability can be made conditional on the character's current 'wield mode' (2-handed, dual, weapon &amp;amp; shield, or universal) through the conditional integer field on the passive_abilities worksheet.&lt;br /&gt;
&lt;br /&gt;
Finally, a number of passive abilities do not define any property modifications in passive_abilites but instead have checks coded against their Ids directly in the combat resolution scripts (e.g. HasAbility( oCreature, ABILITY_TALENT_LETHALITY )). The mere presence of the ability on a creature causes a different code path to be taken in the scripts in those cases.&lt;br /&gt;
&lt;br /&gt;
Note that passive_ability benefits are not limited to abilities with use_type 3. Some active abilities also grant additional property modifying benefits to the owner.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sustained Abilities'''&lt;br /&gt;
&lt;br /&gt;
Sustained abilities (use_type = 2) are turned on and off per character and, while turned on, grant effects or property modifications to the user. &lt;br /&gt;
Most 'buffs' are implemented this way.&lt;br /&gt;
&lt;br /&gt;
Only members of the player's party are using sustained ability as the code overhead required to track them is too expensive to be used on monsters that only exist to die in an encounter with the player's party. (These creatures use duration based effects to emulate similar abilities instead).&lt;br /&gt;
&lt;br /&gt;
Most sustained abilities follow the same pattern:&lt;br /&gt;
* They do not have any activation cost, encouraging tactical use of buffs.&lt;br /&gt;
* They increase the users [[Fatigue]] property, therefore increasing the activation cost of all other abilities.&lt;br /&gt;
* They reduce the users maximum available mana or stamina by a constant value.&lt;br /&gt;
* They use cooldown to prevent the user from being too opportunistic with their use.&lt;br /&gt;
* Some abilities shut down when the user reaches 0 mana/stamina. Very powerful abilities (such as Momentum) have an associated stamina/mana drain effect to limit their use to a short or medium period of time. Creative item / buff use can be used to increase the length such an ability can be sustained.&lt;br /&gt;
&lt;br /&gt;
The benefits from sustained abilities are calculated when the ability is activated. So if a character levels up or otherwise changes stats that influence the magnitude of a sustained ability, they will not update until the ability is reactivated the next time.&lt;br /&gt;
&lt;br /&gt;
Some sustained abilities (such as Flaming Weapons) are active 'party-wide' - the caster not only sustains the ability on himself but on all his party members as well. This is controlled by the 'bPartyWide' flag in [[ABI_base.xls]]. Due to implementation limitations, party members who die or otherwise enter/exit the current party will not be affected by these abilities until they are recast. (we put low cooldown times on these abilities for that very reason).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Gameplay Design Note''' &lt;br /&gt;
* Unlike in games like Baldur's Gate, the system in DA: Origins is designed to encourage tactical use of buffs over strategical. We wanted to put an emphasis on the player making smart choices during an encounter vs. the player guessing which buffs might be useful ahead of time or having to employ save-die-reload to find out. &lt;br /&gt;
&lt;br /&gt;
* It is generally wise to run only one or two buffs all around and activate additional buffs only when needed. &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Activated Abilities'''&lt;br /&gt;
&lt;br /&gt;
Activated abilities (use_type = 4) are abilities that instantly execute their effect (see Targeting Behavior below). Most melee talents or targeted spells fall in this category. There are several sub-types of activated abilies, such as&lt;br /&gt;
&lt;br /&gt;
* Targeted, single target spells and talents (such as Winter's Grasp or Flurry)&lt;br /&gt;
* Ground targeted abilities (such as Blizzard or various Glyphs)&lt;br /&gt;
* Self targeted activated abilities.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Targeting Behavior ====&lt;br /&gt;
&lt;br /&gt;
An abilities targeting behavior is controlled by several settings in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoTarget''' is a boolean field that defines how the UI resolves targeting.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The UI will always bring up a targeting cursor. &lt;br /&gt;
|-&lt;br /&gt;
| 1 || The UI will only produce a targeting cursor if no suitable target is currently selected. e.g if the player currently has a hostile creature targeted and if the spells TargetType includes 0x4 (hostile), the ability will trigger immediately, not producing a targeting cursor. Most single target spells and talents use this setting.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Regardless of AutoTarget setting, the UI will never produce a targeting cursor if an ability is type 0x1 (self) -&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''TargetType''' is a bit mask derived from the following table and controls the behavior of the UI's targeting cursor.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
|'''Bitmask''' || '''Effect'''&lt;br /&gt;
|-&lt;br /&gt;
| 0x1  ||  Self&lt;br /&gt;
|-&lt;br /&gt;
| 0x2 || Friendly Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x4 || Hostile Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x8 || Placeable Object&lt;br /&gt;
|-&lt;br /&gt;
| 0x10 || Area of Effect Object (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20 || Ground (see details)&lt;br /&gt;
|-&lt;br /&gt;
| 0x40 || Dead Body (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x80 || Party Member&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoDraw''' is an integer boolean field that defines how a character's weapons are handled when the ability is triggered.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The ability will not affect the player's weapon sheath status.&lt;br /&gt;
|-&lt;br /&gt;
| 1 || The engine will force the player to draw/unsheathe his weapon before executing the ability. This is used for most bow and melee weapon abilities. &lt;br /&gt;
|-&lt;br /&gt;
| 2 || The engine will force the player to stow away any non staff melee weapons before executing the ability. This is used to ensure that no inappropriate animations play with weapons drawn (e.g. the player conjuring with a sword clipping through his body) and to discourage switching between melee and spellcasting on the fly.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Balancing (Cost, Cooldown, etc) ====&lt;br /&gt;
&lt;br /&gt;
Abilities in Dragon Age are balanced along several vectors, most of which boil down to simple 'use frequency'. As a general rule of thumb, the more specialized and limited the effect of an ability is, the more outrageously powerful an ability can be.&lt;br /&gt;
&lt;br /&gt;
Use frequency of abilities can be adjusted by modifying the following field in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
* Cost: This is the simple mana (spells) or stamina (talents) activation cost of an ability. It is subtracted when the conjure phase of the spell has succesfully completed (e.g. no cost for spell interruptions). Without sufficient resources to cover activation cost, the UI will not allow the player to execute the ability. The value is a constant integer and is multiplied with 1+(Current Fatigue) of the caster. &lt;br /&gt;
&lt;br /&gt;
* Cooldown: Cooldown is a constant float in seconds that defines how long the player has to wait after the successful activation of an ability until he can use it again. For abilities that apply duration based debuffs or effects to a target, cooldown is usually set slightly higher than the duration of the effect to avoid stacking by the same caster.&lt;br /&gt;
&lt;br /&gt;
* Upkeep: Defines how much mana or stamina is removed from the casters overall pool while a sustained ability is active. This naturally limits the number of sustained abilities present on a creature and ensures that the more beneficial buffs are active on the caster, the less mana is available for immediate use.&lt;br /&gt;
&lt;br /&gt;
* [[Fatigue]]: Fatigue affects use frequency only indirectly, but it prevents characters from stacking too many buffs on each other, as each sustained ability active usually adds around 5-10% fatigue to the caster.&lt;br /&gt;
&lt;br /&gt;
* Mana/Stamina drain: By reducing the mana/stamina regeneration rate on a creature, the duration for which a sustained ability can be used can be restricted. This mechanic is used only for the most powerful sustained abilities in the game, which are flagged to turn off when the caster sustaining them reaches 0 mana/stamina.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Other balancing vectors:&lt;br /&gt;
&lt;br /&gt;
* AoESize and AoeShape: Area of effect spells that deal friendly fire are location and situation restricted on normal+ difficulty (hard+ on the consoles). Since dropping an Inferno on your own party members is hardly a good idea in most cases, the usefulness of the spell becomes restricted to careful positioning and the earlier stages of combat. &lt;br /&gt;
&lt;br /&gt;
* Threat Generation: Abilities apply threat not just by damage but often by activation. Higher activation threat of an ability can balance out outrageously powerful effects by making it harder for the player to use the spell. The prime example is the Walking Bomb kind of spells which deal excellent damage, but, on higher difficulties, also make the targets very very angry at the caster.  Using these spells effectively often requires a tactical approach by the player, thus limiting their universal usefulness and offsetting their very powerful effects.&lt;br /&gt;
&lt;br /&gt;
* Threat Removal: Some abilities are designed to only provide a short term benefit (Such as 3s stun on Mindblast) but offset their weakness by removing threat from the caster, often by reinitializing the threat tables on the target, causing enemies to randomly seek new targets.&lt;br /&gt;
&lt;br /&gt;
* Conjure time: Spells with a conjure time of 1+ (Speed in [[ABI_base.xls]]) can be interrupted by damage, limiting their usefulness in melee situations or when only one party member remains on the battlefield. Many of the very powerful Area of Effect type spells use this feature. Most activated spells have a conjure time of 0, making them instant cast.&lt;br /&gt;
&lt;br /&gt;
* Range: Lower ranges force the ability user into potentially more dangerous situations, adding additional risk to the use of an ability.&lt;br /&gt;
&lt;br /&gt;
=== Q&amp;amp;A ===&lt;br /&gt;
&lt;br /&gt;
==== Q: Where do we find the exact formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Due to most abilities being unique, the only place to find the exact details on each spell is in the scripts. While a lot of data can be glanced from [[ABI_base.xls]], a lot of the detailed mechanics are very different between abilities and can only be found in the appropriate spellscript. The *_constant.nss files hold some basic values, but often get further modified in the scripts. &lt;br /&gt;
&lt;br /&gt;
This is also one of the reasons why some elements of a talent are not displayed in the UI description in game. While we can calculate cost and cooldown based on the casting character and his fatigue and other properties (and consequently display it), we can usually not calculate damage or duration as they are mitigated on the target creature: &lt;br /&gt;
&lt;br /&gt;
Displaying those values results in very misleading information (e.g. while damage seems to be higher on one ability, the mitigation mechanisms and unique side effects of another ability will make it just as good or better - in certain situations) and it turned out to be better to provide the player with general guidance than the misleading information.&lt;br /&gt;
&lt;br /&gt;
==== Q: What is Spellpower and how does it interact with abilities ====&lt;br /&gt;
&lt;br /&gt;
Spellpower is probably the most important stat for a mage character (and only exists on mage characters). It is calculated as max(Magic - 10,0) and therefore increases by one point for every point a mage spends on his Magic attribute.&lt;br /&gt;
&lt;br /&gt;
Most mage spells benefit directly from higher spellpower by increased damage, effect magnitude and duration. It also plays a role in a mages ability to overcome mental or physical resistance on a target (where applicable). The actual impact of spellpower on an ability varies from spell to spell but the most common construct equates to something like 1% increase in spell potency per point of Spellpower. Thus, items and spells that increase spellpower are very powerful as they increase the potency of every spell the mage can cast.&lt;br /&gt;
&lt;br /&gt;
Spellpower is the only factor that causes an increase of a spells potency over time, so a level 20 mage with neglected the Magic attribute would be much less powerful than a mage that didn't neglect Magic.&lt;br /&gt;
&lt;br /&gt;
Some examples:&lt;br /&gt;
&lt;br /&gt;
* The damage potential for Winter's Grasp is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.36f;&lt;br /&gt;
* The healing potential for the heal spell is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.40f;&lt;br /&gt;
* The damage over time component of blizzard is executed as ApplyEffectDamageOverTime(a[i], oCreator, ABILITY_SPELL_BLIZZARD,  (100.0f + GetCreatureSpellPower(oCreator)) * 0.1, (BLIZZARD_INTERVAL_DURATION - 0.5f), DAMAGE_TYPE_COLD);&lt;br /&gt;
&lt;br /&gt;
Note that these formulas only list the raw damage potential and do not take into account the effects of damage types, difficulty, rank, resistances, magical shields and any other mitigating factors on the target or enhancing factors on the caster. This means that just comparing the numbers will not give you an idea which spell is better or worse.&lt;br /&gt;
&lt;br /&gt;
For non-mage spells and abilities, spellpower is often substituted by an appropriate other construct (such as max(Cunning-10,0) for rogue abilities).&lt;br /&gt;
&lt;br /&gt;
==== Q: Can we have the damage formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is no damage formula for abilities, as mentioned before, each ability follows their own rules.&lt;br /&gt;
&lt;br /&gt;
In general, talent damage is based on the weapon being used (e.g. Assault does 3 melee attacks that deal weapon damage with some additional bonuses) and are modified by external cirumstances such as location, critical chance and ability to deliver a backstab and are mitigated by armor on the target.&lt;br /&gt;
&lt;br /&gt;
Spells deal damage of different damage types following a rough rule of (Constant * (Spellpower / Variable)) / [Variables] ) + Modifiers but this only tells part of the story as actual damage is dependent on the target, it's resistances, rank and a number of other factors.&lt;br /&gt;
&lt;br /&gt;
Some additional factors affecting spell damage are:&lt;br /&gt;
&lt;br /&gt;
* damage resistance.&lt;br /&gt;
* magical shields.&lt;br /&gt;
* difficulty level.&lt;br /&gt;
* elemental damage bonuses from spells or items &lt;br /&gt;
* Environmental conditions (frozen targets take less damage from fire, etc.)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the differences between damage types? ====&lt;br /&gt;
&lt;br /&gt;
A: Creatures have variable damage resistances based on their type and rank. Dragons might get 60% less damage from fire (60% fire resistance), other creatures will have different immunities. Additional effects are:&lt;br /&gt;
&lt;br /&gt;
* Electricity: In addition to normal damage, these also reduce the targets stamina (but not mana) by the same amount, making them very effective boss killers.&lt;br /&gt;
&lt;br /&gt;
* Fire: Cancels Cold based damage over time effects and applies damage over time.&lt;br /&gt;
&lt;br /&gt;
* Cold: Cancel Fire based damage over time effects and often is accompanied by slow or slipping effects.&lt;br /&gt;
&lt;br /&gt;
* Spirit: There are very few ways of increasing spirit resistance in the game, so spells dealing spirit damage are universally useful...&lt;br /&gt;
&lt;br /&gt;
* Nature: Rarely found on spells. Many creatures are resistant to this.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(This should probably go on its own wiki page)&lt;br /&gt;
&lt;br /&gt;
==== Q: Are sustained abilities mutually exclusive ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is a very limited number of sustained abilities that are mutually exclusive, usually because it makes sense. Mutually exclusive abilities cancel each other upon activation.&lt;br /&gt;
&lt;br /&gt;
* Shield stances (Shield Wall, Shield Cover, Shield Defense) are mutually exclusive.&lt;br /&gt;
* Archery stances (Aim, Rapid Fire, Defensive Fire) are mutually exclusive.&lt;br /&gt;
* Shapeshifting forms (Sorry, no Bear-Wolfspider) are mutually exclusive.&lt;br /&gt;
* Weapon Enhancement spells are too, but only for the same caster (so two mages can run two different weapon enhancements if they want to).&lt;br /&gt;
* Bard Songs are mutually exclusive.&lt;br /&gt;
* The Death Syphon and Death Magic spells are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
Technically, all abilities in abi_base.xls that share the same 'condition_group' value are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the rules for stacking effects and damage ? ====&lt;br /&gt;
&lt;br /&gt;
A: The general rules of stacking for abilities are:&lt;br /&gt;
&lt;br /&gt;
* Identical effect from different abilities stack (e.g. getting +10 attack from one ability and +10 attack from another nets +20 attack).&lt;br /&gt;
* The effects of identical abilities stack as long as they are from different caster. (Same caster usually does not apply as cooldown often exceeds duration).&lt;br /&gt;
* Weapon enhancement spells of the same type (e.g. 2 mages with flame weapons) do not stack. The sword does not get more flaming, sorry :)&lt;br /&gt;
* Animation based effects (knockdown, stun, etc.) stack, but only the one with the highest priority is played. This is defined in the priority column in effects.xls. &lt;br /&gt;
* Glyphs do stack but there is a limit of 5 active glyphs per caster.&lt;br /&gt;
* Fire and Cold DoT effects do not stack, the spell cast last will cancel any existing spell of the opposite type.&lt;br /&gt;
* Fire and Cold AoEs cancel each other, other AoEs might interact rather violently, handle with care :)&lt;br /&gt;
&lt;br /&gt;
For equipment and item based effects, the game usually stacks within the minumum and maximum clamp values of a property (properties.xls). This means that you can accumulate a lot of +damage or +critical critical chance effects, but for some type of stats there is a point where you are no longer gaining any benefits (e.g. speed modification - animations can only be sped up to a certain point before breaking, so stacking momentum, haste and a weapon with a speed based effect will not result in a -3.0s attack time, sorry :p)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
For almost all effects, the total result of all property modifications on a creature are visible on the main character UI by hovering over the individual stats.&lt;br /&gt;
&lt;br /&gt;
==== Q: How does game difficulty affect abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Our approach to game difficulty dictates that the effect of your chosen setting are&lt;br /&gt;
&lt;br /&gt;
a) non punishing - You do not get less XP for chosing a lower difficulty mode, etc.&lt;br /&gt;
b) challenge scaling - Higher difficulty will reward you with greater obstacles to overcome.&lt;br /&gt;
c) fair - Lower difficulties grant benefits that gradually get removed. (This does not mean the rules are symmetric and is not true on nightmare at all. Nightmare is evil. And unfair.)&lt;br /&gt;
d) non persistent - Difficulty changes are possible on the fly, at any time and take immediate effect.&lt;br /&gt;
&lt;br /&gt;
The game is balanced so that Hard mode is challenging for a Baldur's gate veteran.&lt;br /&gt;
&lt;br /&gt;
Based on these guidelines, you can expect the following ability behaviors in game:&lt;br /&gt;
&lt;br /&gt;
* The lower the difficulty, the longer your hostile effects such as stuns will last on enemies and the shorter they will last on you.&lt;br /&gt;
* The lower the difficulty, the more damage your abilities will do.&lt;br /&gt;
* The lower the difficulty, the less likely the enemy AI will use devastating special abilities (Note: less likely does not mean 'does not use').&lt;br /&gt;
* Casual and Normal have reduced friendly or nullified fire damage damage from area effect spells. Hard and Nightmare require careful positioning and tactical use of spells.&lt;br /&gt;
* The higher the difficulty, the more careful you need to manage threat when using spells and abilities (The AI becomes smarter about picking targets).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What is spell affinity ? ====&lt;br /&gt;
&lt;br /&gt;
A: Spell Affinity was a design we toyed with for a while during development but decided not to implement.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: How does Rank Based Mitigation Work ? ====&lt;br /&gt;
&lt;br /&gt;
A: In line with Dragon Age: Origin's asymmetric approach to rules, the game uses creature ranks (instead of levels) in addition to stats and resistances to define how creatures get affected by abilities. In short: Boss monsters get affected differently by abilities and effects than Lieutenants or Critters. &lt;br /&gt;
&lt;br /&gt;
The rank system is the primary balancing vector for the games difficulty levels and profoundly affects all aspects of combat. The gory details of this system are defined in creature_ranks.xls and difficulty.xls.&lt;br /&gt;
&lt;br /&gt;
Rank mitigation affects not just damage in- and output of a creature, but also the duration that hostile effects persist on it and is different for each difficulty level of the game. Note that party members have their own rank in this system and are handled differently from other creatures in some cases. &lt;br /&gt;
&lt;br /&gt;
Below is the formula used for rank based effect duration mitigation: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
// sys_resistances_h&lt;br /&gt;
// @brief Returns an effect duration scaled by rank of oCreature and game difficulty&lt;br /&gt;
// @author Georg&lt;br /&gt;
float GetRankAdjustedEffectDuration(object oCreature, float fDur)&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    // Georg: This deserves some explanation:&lt;br /&gt;
    //&lt;br /&gt;
    //        One of the core issues when designing the combat system was always&lt;br /&gt;
    //        the fact that the story called for sequences during the game in which&lt;br /&gt;
    //        your main character acts solo.&lt;br /&gt;
    //&lt;br /&gt;
    //        Characters reliant on special abilities, such as rogues, would require&lt;br /&gt;
    //        them to be very effective in order to beat enemies that a standard tank&lt;br /&gt;
    //        can plow through. However, if these abilities would maintain the same&lt;br /&gt;
    //        effectiveness in a full party, most encounters would turn into a stunfest.&lt;br /&gt;
    //&lt;br /&gt;
    //        The solution is to add 1 second flat to each detrimental effect duration&lt;br /&gt;
    //        lasting at least 1 second for each unoccupied slot in the party - before applying&lt;br /&gt;
    //        rank and difficulty modifiers. This also makes solo play a bit more viable.&lt;br /&gt;
    //&lt;br /&gt;
    //        This is in addition to the diminishing returns on quickly successive stuns.&lt;br /&gt;
    //&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    if (!IsPartyMember(oCreature))&lt;br /&gt;
    {&lt;br /&gt;
        float fPartySizeModifier = IntToFloat(Max(0,4 - GetArraySize(GetPartyList())));&lt;br /&gt;
&lt;br /&gt;
        if (fDur &amp;gt;= 1.0f)&lt;br /&gt;
        {&lt;br /&gt;
            fDur += fPartySizeModifier;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    float fRankDurMod = Diff_GetDurationModifier(oCreature);&lt;br /&gt;
    if (fRankDurMod &amp;gt;0.0f)&lt;br /&gt;
    {&lt;br /&gt;
        return (fDur * fRankDurMod);&lt;br /&gt;
    }&lt;br /&gt;
    else&lt;br /&gt;
    {&lt;br /&gt;
     return fDur;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripts]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What does 'asymmetric rules system' mean ? ====&lt;br /&gt;
&lt;br /&gt;
The goal behind Dragon Age: Origin's rule system was to create a fun and challenging video game experience first and foremost. &lt;br /&gt;
&lt;br /&gt;
We describe the rules as 'asymmetric' because a subset of the game rules treats player controlled characters and monsters differently, which is a deviation from pen and paper rule design that often require player and opponents to be treated exactly the same. &lt;br /&gt;
&lt;br /&gt;
Notable Examples:&lt;br /&gt;
* Party members never die permanently (get shattered, etc.)&lt;br /&gt;
* Differently ranked creatures (including party members) get affected for different durations by effects&lt;br /&gt;
* In limited situations in the game, we apply benefits to the player to overcome greater odds than they would usually be able to. &lt;br /&gt;
* Some abilities will work diferently when deployed against the party (although the visual results might be identical).&lt;br /&gt;
* Elimination of instant death situations (not fun!) against players but not against monsters (fun!).&lt;br /&gt;
* Sustained abilities only work for players (the overhead is not justified for monsters that won't ever reappear after they die).&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Ability&amp;diff=7357</id>
		<title>Ability</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Ability&amp;diff=7357"/>
				<updated>2009-10-31T01:49:42Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Q: Where do we find the exact formula for abilities ? */ formatting&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=== Overview ===&lt;br /&gt;
The Ability System is used to handle Spells, Talents, Skills, and Item Abilities in Dragon Age.&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Spells, Talents, Skills and item abilities all use the same backend in the game, a mostly script implemented system relying heavily on two dimensional data arrays. &lt;br /&gt;
&lt;br /&gt;
The most important 2da file for abilities is '''[[ABI_base.xls]]''', as it defines each ability and all aspects of execution and handling in both scripting and engine code.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Ability Design Notes''' &lt;br /&gt;
&lt;br /&gt;
When creating an ability in Dragon Age: Origins, we generally stick to the following guidelines&lt;br /&gt;
&lt;br /&gt;
* Keep it useful. &lt;br /&gt;
Some constant benefits (such as an increase in Attack or Defense) stay useful for the duration of the game as the progression of the related properties are slow. &lt;br /&gt;
For other effects, such as damage, a constant value would mean that the ability will become progressively worse through the game as damage needed to drop enemies increases from level to level. In such cases, the ability should be tied in some fashion to a Spellpower (for spells) or another relevant trait (such as cunning for rogues) to ensure they stay useful throughout the game. &lt;br /&gt;
&lt;br /&gt;
* No repetition. &lt;br /&gt;
Each ability in Dragon Age: Origins is unique. No incremental abilities such as 'fireball I, fireball II, etc.'. Skills are exempt from this rule. Remember that the Damage Types dramatically alter the actual effect of an ability (such as lightning always draining stamina alongside doing damage), so having similar damaging abilities in different trees is usually fine.&lt;br /&gt;
&lt;br /&gt;
* Thematic matching.&lt;br /&gt;
Abilities within the same chain should follow a common theme. &lt;br /&gt;
&lt;br /&gt;
* Avoid binary abilities. Design hit heavy.&lt;br /&gt;
Avoid abilities that are hit-or-miss. Generally, abilities should hit whenever possible and use target side mitigation of effects (resistance checks, damage mitigation) instead of 'hit or miss' mechanics. Melee abilities may use the normal attack resolution routines but should always perform their attacks at a bonus. Use rank based mitigation and resistances to allow for very powerful effects that do not trivialize boss battles. &lt;br /&gt;
&lt;br /&gt;
* Use meaningful effects&lt;br /&gt;
Abilities should always be worth it. Don't do minor effects (+1 attack). The player should always be able to see the effect of the ability in game (not necessarily visually, but at least through increased damage, etc.). The first ability in a chain should, whenever possible, be active. The fourth ability in a chain should always have the biggest 'bang-for-the-buck' factor. Abilities lower in the chain should have shorter cooldowns. Do not allow instant death on bosses and elite bosses.&lt;br /&gt;
&lt;br /&gt;
* Avoid 'zero-sum' abilities&lt;br /&gt;
When possible, avoid 'zero-sum' abilities that trade a penalty for a benefit (e.g. increase defense but decrease attack). There are a number of these abilities that are valid (such as aim), but balancing them and keeping them useful is hard and requires a lot of work. This obviously does not apply to drastic abilities such as blood magic.&lt;br /&gt;
&lt;br /&gt;
* No emulation of defining class capabilities&lt;br /&gt;
Never ever grant a basic class capability from one class to another class via abilities. This means no invisibility or magical unlock spells for mages, as these are defining capabilities of the rogue class. No weapon talents for mages. No magic spells or large, targeted area of effects for warriors or rogues. Items might blur this line if the cost is balanced properly (e.g. grenades).&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Basic Ability Types ====&lt;br /&gt;
&lt;br /&gt;
Abilities are divided into 4 subtypes, as defined in the 'abilitytype' column in [[ABI_base.xls]]:&lt;br /&gt;
&lt;br /&gt;
* Talents - Abilities used by warriors and rogues, usually non magical in nature. (abilitytype=1)&lt;br /&gt;
* Spells - Abilities used by mages, either spell or passive abilities.  (abilitytype=2)&lt;br /&gt;
* Skills - Abilities usable by all classes, such as Survival and Combat training (abilitytype=3).&lt;br /&gt;
* Items  - Abilities present on an item that are triggered when the item is used on the quickbar. (ability_type=4)&lt;br /&gt;
&lt;br /&gt;
Note: Talents do not show up on mages and spells do not show up on rogue or warrior characters, so to create abilities that can be used by all classes, abilitytype 3 (Skill) must be used. To define under which heading an ability shows up on the character's talent/spell page, the field 'guitype' is used. It resolves against [[guitype.xls]] which lists all known headings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are 3 basic ability types in the game, defined by the field 'use_type' in [[ABI_base.xls]].&lt;br /&gt;
&lt;br /&gt;
'''Passive Abilities''' &lt;br /&gt;
&lt;br /&gt;
Passive abilities (use_type = 3) grant persistent or conditionally persistent bonuses or penalties to the creature that has the ability. &lt;br /&gt;
&lt;br /&gt;
A passive ability may grant up to 3 modifications to creature properties ([[properties.xls]]). Those modifications are defined in the passive_abilities worksheet of [[ABI_base.xls]] and linked to the ability through the passive_id column in ABI_base.xls.&lt;br /&gt;
&lt;br /&gt;
Additionally, the bonuses of an ability can be made conditional on the character's current 'wield mode' (2-handed, dual, weapon &amp;amp; shield, or universal) through the conditional integer field on the passive_abilities worksheet.&lt;br /&gt;
&lt;br /&gt;
Finally, a number of passive abilities do not define any property modifications in passive_abilites but instead have checks coded against their Ids directly in the combat resolution scripts (e.g. HasAbility( oCreature, ABILITY_TALENT_LETHALITY )). The mere presence of the ability on a creature causes a different code path to be taken in the scripts in those cases.&lt;br /&gt;
&lt;br /&gt;
Note that passive_ability benefits are not limited to abilities with use_type 3. Some active abilities also grant additional property modifying benefits to the owner.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sustained Abilities'''&lt;br /&gt;
&lt;br /&gt;
Sustained abilities (use_type = 2) are turned on and off per character and, while turned on, grant effects or property modifications to the user. &lt;br /&gt;
Most 'buffs' are implemented this way.&lt;br /&gt;
&lt;br /&gt;
Only members of the player's party are using sustained ability as the code overhead required to track them is too expensive to be used on monsters that only exist to die in an encounter with the player's party. (These creatures use duration based effects to emulate similar abilities instead).&lt;br /&gt;
&lt;br /&gt;
Most sustained abilities follow the same pattern:&lt;br /&gt;
* They do not have any activation cost, encouraging tactical use of buffs.&lt;br /&gt;
* They increase the users [[Fatigue]] property, therefore increasing the activation cost of all other abilities.&lt;br /&gt;
* They reduce the users maximum available mana or stamina by a constant value.&lt;br /&gt;
* They use cooldown to prevent the user from being too opportunistic with their use.&lt;br /&gt;
* Some abilities shut down when the user reaches 0 mana/stamina. Very powerful abilities (such as Momentum) have an associated stamina/mana drain effect to limit their use to a short or medium period of time. Creative item / buff use can be used to increase the length such an ability can be sustained.&lt;br /&gt;
&lt;br /&gt;
The benefits from sustained abilities are calculated when the ability is activated. So if a character levels up or otherwise changes stats that influence the magnitude of a sustained ability, they will not update until the ability is reactivated the next time.&lt;br /&gt;
&lt;br /&gt;
Some sustained abilities (such as Flaming Weapons) are active 'party-wide' - the caster not only sustains the ability on himself but on all his party members as well. This is controlled by the 'bPartyWide' flag in [[ABI_base.xls]]. Due to implementation limitations, party members who die or otherwise enter/exit the current party will not be affected by these abilities until they are recast. (we put low cooldown times on these abilities for that very reason).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Gameplay Design Note''' &lt;br /&gt;
* Unlike in games like Baldur's Gate, the system in DA: Origins is designed to encourage tactical use of buffs over strategical. We wanted to put an emphasis on the player making smart choices during an encounter vs. the player guessing which buffs might be useful ahead of time or having to employ save-die-reload to find out. &lt;br /&gt;
&lt;br /&gt;
* It is generally wise to run only one or two buffs all around and activate additional buffs only when needed. &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Activated Abilities'''&lt;br /&gt;
&lt;br /&gt;
Activated abilities (use_type = 4) are abilities that instantly execute their effect (see Targeting Behavior below). Most melee talents or targeted spells fall in this category. There are several sub-types of activated abilies, such as&lt;br /&gt;
&lt;br /&gt;
* Targeted, single target spells and talents (such as Winter's Grasp or Flurry)&lt;br /&gt;
* Ground targeted abilities (such as Blizzard or various Glyphs)&lt;br /&gt;
* Self targeted activated abilities.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Targeting Behavior ====&lt;br /&gt;
&lt;br /&gt;
An abilities targeting behavior is controlled by several settings in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoTarget''' is a boolean field that defines how the UI resolves targeting.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The UI will always bring up a targeting cursor. &lt;br /&gt;
|-&lt;br /&gt;
| 1 || The UI will only produce a targeting cursor if no suitable target is currently selected. e.g if the player currently has a hostile creature targeted and if the spells TargetType includes 0x4 (hostile), the ability will trigger immediately, not producing a targeting cursor. Most single target spells and talents use this setting.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Regardless of AutoTarget setting, the UI will never produce a targeting cursor if an ability is type 0x1 (self) -&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''TargetType''' is a bit mask derived from the following table and controls the behavior of the UI's targeting cursor.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
|'''Bitmask''' || '''Effect'''&lt;br /&gt;
|-&lt;br /&gt;
| 0x1  ||  Self&lt;br /&gt;
|-&lt;br /&gt;
| 0x2 || Friendly Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x4 || Hostile Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x8 || Placeable Object&lt;br /&gt;
|-&lt;br /&gt;
| 0x10 || Area of Effect Object (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20 || Ground (see details)&lt;br /&gt;
|-&lt;br /&gt;
| 0x40 || Dead Body (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x80 || Party Member&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoDraw''' is an integer boolean field that defines how a character's weapons are handled when the ability is triggered.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The ability will not affect the player's weapon sheath status.&lt;br /&gt;
|-&lt;br /&gt;
| 1 || The engine will force the player to draw/unsheathe his weapon before executing the ability. This is used for most bow and melee weapon abilities. &lt;br /&gt;
|-&lt;br /&gt;
| 2 || The engine will force the player to stow away any non staff melee weapons before executing the ability. This is used to ensure that no inappropriate animations play with weapons drawn (e.g. the player conjuring with a sword clipping through his body) and to discourage switching between melee and spellcasting on the fly.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Balancing (Cost, Cooldown, etc) ====&lt;br /&gt;
&lt;br /&gt;
Abilities in Dragon Age are balanced along several vectors, most of which boil down to simple 'use frequency'. As a general rule of thumb, the more specialized and limited the effect of an ability is, the more outrageously powerful an ability can be.&lt;br /&gt;
&lt;br /&gt;
Use frequency of abilities can be adjusted by modifying the following field in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
* Cost: This is the simple mana (spells) or stamina (talents) activation cost of an ability. It is subtracted when the conjure phase of the spell has succesfully completed (e.g. no cost for spell interruptions). Without sufficient resources to cover activation cost, the UI will not allow the player to execute the ability. The value is a constant integer and is multiplied with 1+(Current Fatigue) of the caster. &lt;br /&gt;
&lt;br /&gt;
* Cooldown: Cooldown is a constant float in seconds that defines how long the player has to wait after the successful activation of an ability until he can use it again. For abilities that apply duration based debuffs or effects to a target, cooldown is usually set slightly higher than the duration of the effect to avoid stacking by the same caster.&lt;br /&gt;
&lt;br /&gt;
* Upkeep: Defines how much mana or stamina is removed from the casters overall pool while a sustained ability is active. This naturally limits the number of sustained abilities present on a creature and ensures that the more beneficial buffs are active on the caster, the less mana is available for immediate use.&lt;br /&gt;
&lt;br /&gt;
* [[Fatigue]]: Fatigue affects use frequency only indirectly, but it prevents characters from stacking too many buffs on each other, as each sustained ability active usually adds around 5-10% fatigue to the caster.&lt;br /&gt;
&lt;br /&gt;
* Mana/Stamina drain: By reducing the mana/stamina regeneration rate on a creature, the duration for which a sustained ability can be used can be restricted. This mechanic is used only for the most powerful sustained abilities in the game, which are flagged to turn off when the caster sustaining them reaches 0 mana/stamina.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Other balancing vectors:&lt;br /&gt;
&lt;br /&gt;
* AoESize and AoeShape: Area of effect spells that deal friendly fire are location and situation restricted on normal+ difficulty (hard+ on the consoles). Since dropping an Inferno on your own party members is hardly a good idea in most cases, the usefulness of the spell becomes restricted to careful positioning and the earlier stages of combat. &lt;br /&gt;
&lt;br /&gt;
* Threat Generation: Abilities apply threat not just by damage but often by activation. Higher activation threat of an ability can balance out outrageously powerful effects by making it harder for the player to use the spell. The prime example is the Walking Bomb kind of spells which deal excellent damage, but, on higher difficulties, also make the targets very very angry at the caster.  Using these spells effectively often requires a tactical approach by the player, thus limiting their universal usefulness and offsetting their very powerful effects.&lt;br /&gt;
&lt;br /&gt;
* Threat Removal: Some abilities are designed to only provide a short term benefit (Such as 3s stun on Mindblast) but offset their weakness by removing threat from the caster, often by reinitializing the threat tables on the target, causing enemies to randomly seek new targets.&lt;br /&gt;
&lt;br /&gt;
* Conjure time: Spells with a conjure time of 1+ (Speed in [[ABI_base.xls]]) can be interrupted by damage, limiting their usefulness in melee situations or when only one party member remains on the battlefield. Many of the very powerful Area of Effect type spells use this feature. Most activated spells have a conjure time of 0, making them instant cast.&lt;br /&gt;
&lt;br /&gt;
* Range: Lower ranges force the ability user into potentially more dangerous situations, adding additional risk to the use of an ability.&lt;br /&gt;
&lt;br /&gt;
=== Q&amp;amp;A ===&lt;br /&gt;
&lt;br /&gt;
==== Q: Where do we find the exact formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Due to most abilities being unique, the only place to find the exact details on each spell is in the scripts. While a lot of data can be glanced from [[ABI_base.xls]], a lot of the detailed mechanics are very different between abilities and can only be found in the appropriate spellscript. The *_constant.nss files hold some basic values, but often get further modified in the scripts. &lt;br /&gt;
&lt;br /&gt;
This is also one of the reasons why some elements of a talent are not displayed in the UI description in game. While we can calculate cost and cooldown based on the casting character and his fatigue and other properties (and consequently display it), we can usually not calculate damage or duration as they are mitigated on the target creature: &lt;br /&gt;
&lt;br /&gt;
Displaying those values results in very misleading information (e.g. while damage seems to be higher on one ability, the mitigation mechanisms and unique side effects of another ability will make it just as good or better - in certain situations) and it turned out to be better to provide the player with general guidance than the misleading information.&lt;br /&gt;
&lt;br /&gt;
==== Q: What is Spellpower and how does it interact with abilities ====&lt;br /&gt;
&lt;br /&gt;
Spellpower is probably the most important stat for a mage character (and only exists on mage characters). It is calculated as max(Magic - 10,0) and therefore increases by one point for every point a mage spends on his Magic attribute.&lt;br /&gt;
&lt;br /&gt;
Most mage spells benefit directly from higher spellpower by increased damage, effect magnitude and duration. It also plays a role in a mages ability to overcome mental or physical resistance on a target (where applicable). The actual impact of spellpower on an ability varies from spell to spell but the most common construct equates to something like 1% increase in spell potency per point of Spellpower. Thus, items and spells that increase spellpower are very powerful as they increase the potency of every spell the mage can cast.&lt;br /&gt;
&lt;br /&gt;
Spellpower is the only factor that causes an increase of a spells potency over time, so a level 20 mage with neglected the Magic attribute would be much less powerful than a mage that didn't neglect Magic.&lt;br /&gt;
&lt;br /&gt;
Some examples:&lt;br /&gt;
&lt;br /&gt;
* The damage potential for Winter's Grasp is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.36f;&lt;br /&gt;
* The healing potential for the heal spell is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.40f;&lt;br /&gt;
* The damage over time component of blizzard is executed as ApplyEffectDamageOverTime(a[i], oCreator, ABILITY_SPELL_BLIZZARD,  (100.0f + GetCreatureSpellPower(oCreator)) * 0.1, (BLIZZARD_INTERVAL_DURATION - 0.5f), DAMAGE_TYPE_COLD);&lt;br /&gt;
&lt;br /&gt;
Note that these formulas only list the raw damage potential and do not take into account the effects of damage types, difficulty, rank, resistances, magical shields and any other mitigating factors on the target or enhancing factors on the caster. This means that just comparing the numbers will not give you an idea which spell is better or worse.&lt;br /&gt;
&lt;br /&gt;
For non-mage spells and abilities, spellpower is often substituted by an appropriate other construct (such as max(Cunning-10,0) for rogue abilities).&lt;br /&gt;
&lt;br /&gt;
==== Q: Can we have the damage formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is no damage formula for abilities, as mentioned before, each ability follows their own rules.&lt;br /&gt;
&lt;br /&gt;
In general, talent damage is based on the weapon being used (e.g. Assault does 3 melee attacks that deal weapon damage with some additional bonuses) and are modified by external cirumstances such as location, critical chance and ability to deliver a backstab and are mitigated by armor on the target.&lt;br /&gt;
&lt;br /&gt;
Spells deal damage of different damage types following a rough rule of (Constant * (Spellpower / Variable)) / [Variables] ) + Modifiers but this only tells part of the story as actual damage is dependent on the target, it's resistances, rank and a number of other factors.&lt;br /&gt;
&lt;br /&gt;
Some additional factors affecting spell damage are:&lt;br /&gt;
&lt;br /&gt;
* damage resistance.&lt;br /&gt;
* magical shields.&lt;br /&gt;
* difficulty level.&lt;br /&gt;
* elemental damage bonuses from spells or items &lt;br /&gt;
* Environmental conditions (frozen targets take less damage from fire, etc.)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the differences between damage types? ====&lt;br /&gt;
&lt;br /&gt;
A: Creatures have variable damage resistances based on their type and rank. Dragons might get 60% less damage from fire (60% fire resistance), other creatures will have different immunities. Additional effects are:&lt;br /&gt;
&lt;br /&gt;
* Electricity: In addition to normal damage, these also reduce the targets stamina (but not mana) by the same amount, making them very effective boss killers.&lt;br /&gt;
&lt;br /&gt;
* Fire: Cancels Cold based damage over time effects and applies damage over time.&lt;br /&gt;
&lt;br /&gt;
* Cold: Cancel Fire based damage over time effects and often is accompanied by slow or slipping effects.&lt;br /&gt;
&lt;br /&gt;
* Spirit: There are very few ways of increasing spirit resistance in the game, so spells dealing spirit damage are universally useful...&lt;br /&gt;
&lt;br /&gt;
* Nature: Rarely found on spells. Many creatures are resistant to this.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(This should probably go on its own wiki page)&lt;br /&gt;
&lt;br /&gt;
==== Q: Are sustained abilities mutually exclusive ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is a very limited number of sustained abilities that are mutually exclusive, usually because it makes sense. Mutually exclusive abilities cancel each other upon activation.&lt;br /&gt;
&lt;br /&gt;
* Shield stances (Shield Wall, Shield Cover, Shield Defense) are mutually exclusive.&lt;br /&gt;
* Archery stances (Aim, Rapid Fire, Defensive Fire) are mutually exclusive.&lt;br /&gt;
* Shapeshifting forms are (Sorry, no Bear-Wolfspider) are mutually exclusive.&lt;br /&gt;
* Weapon Enhancement spells are too, but only for the same caster (so two mages can run two different weapon enhancements if they want to).&lt;br /&gt;
* Bard Songs are mutually exclusive.&lt;br /&gt;
* The Death Syphon and Death Magic spells are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
Technically, all abilities in abi_base.xls that share the same 'condition_group' value are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the rules for stacking effects and damage ? ====&lt;br /&gt;
&lt;br /&gt;
A: The general rules of stacking for abilities are:&lt;br /&gt;
&lt;br /&gt;
* Identical effect from different abilities stack (e.g. getting +10 attack from one ability and +10 attack from another nets +20 attack).&lt;br /&gt;
* The effects of identical abilities stack as long as they are from different caster. (Same caster usually does not apply as cooldown often exceeds duration).&lt;br /&gt;
* Weapon enhancement spells of the same type (e.g. 2 mages with flame weapons) do not stack. The sword does not get more flaming, sorry :)&lt;br /&gt;
* Animation based effects (knockdown, stun, etc.) stack, but only the one with the highest priority is played. This is defined in the priority column in effects.xls. &lt;br /&gt;
* Glyphs do stack but there is a limit of 5 active glyphs per caster.&lt;br /&gt;
* Fire and Cold DoT effects do not stack, the spell cast last will cancel any existing spell of the opposite type.&lt;br /&gt;
* Fire and Cold AoEs cancel each other, other AoEs might interact rather violently, handle with care :)&lt;br /&gt;
&lt;br /&gt;
For equipment and item based effects, the game usually stacks within the minumum and maximum clamp values of a property (properties.xls). This means that you can accumulate a lot of +damage or +critical critical chance effects, but for some type of stats there is a point where you are no longer gaining any benefits (e.g. speed modification - animations can only be sped up to a certain point before breaking, so stacking momentum, haste and a weapon with a speed based effect will not result in a -3.0s attack time, sorry :p)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
For almost all effects, the total result of all property modifications on a creature are visible on the main character UI by hovering over the individual stats.&lt;br /&gt;
&lt;br /&gt;
==== Q: How does game difficulty affect abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Our approach to game difficulty dictates that the effect of your chosen setting are&lt;br /&gt;
&lt;br /&gt;
a) non punishing - You do not get less XP for chosing a lower difficulty mode, etc.&lt;br /&gt;
b) challenge scaling - Higher difficulty will reward you with greater obstacles to overcome.&lt;br /&gt;
c) fair - Lower difficulties grant benefits that gradually get removed. (This does not mean the rules are symmetric and is not true on nightmare at all. Nightmare is evil. And unfair.)&lt;br /&gt;
d) non persistent - Difficulty changes are possible on the fly, at any time and take immediate effect.&lt;br /&gt;
&lt;br /&gt;
The game is balanced so that Hard mode is challenging for a Baldur's gate veteran.&lt;br /&gt;
&lt;br /&gt;
Based on these guidelines, you can expect the following ability behaviors in game:&lt;br /&gt;
&lt;br /&gt;
* The lower the difficulty, the longer your hostile effects such as stuns will last on enemies and the shorter they will last on you.&lt;br /&gt;
* The lower the difficulty, the more damage your abilities will do.&lt;br /&gt;
* The lower the difficulty, the less likely the enemy AI will use devastating special abilities (Note: less likely does not mean 'does not use').&lt;br /&gt;
* Casual and Normal have reduced friendly or nullified fire damage damage from area effect spells. Hard and Nightmare require careful positioning and tactical use of spells.&lt;br /&gt;
* The higher the difficulty, the more careful you need to manage threat when using spells and abilities (The AI becomes smarter about picking targets).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What is spell affinity ? ====&lt;br /&gt;
&lt;br /&gt;
A: Spell Affinity was a design we toyed with for a while during development but decided not to implement.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: How does Rank Based Mitigation Work ? ====&lt;br /&gt;
&lt;br /&gt;
A: In line with Dragon Age: Origin's asymmetric approach to rules, the game uses creature ranks (instead of levels) in addition to stats and resistances to define how creatures get affected by abilities. In short: Boss monsters get affected differently by abilities and effects than Lieutenants or Critters. &lt;br /&gt;
&lt;br /&gt;
The rank system is the primary balancing vector for the games difficulty levels and profoundly affects all aspects of combat. The gory details of this system are defined in creature_ranks.xls and difficulty.xls.&lt;br /&gt;
&lt;br /&gt;
Rank mitigation affects not just damage in- and output of a creature, but also the duration that hostile effects persist on it and is different for each difficulty level of the game. Note that party members have their own rank in this system and are handled differently from other creatures in some cases. &lt;br /&gt;
&lt;br /&gt;
Below is the formula used for rank based effect duration mitigation: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
// sys_resistances_h&lt;br /&gt;
// @brief Returns an effect duration scaled by rank of oCreature and game difficulty&lt;br /&gt;
// @author Georg&lt;br /&gt;
float GetRankAdjustedEffectDuration(object oCreature, float fDur)&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    // Georg: This deserves some explanation:&lt;br /&gt;
    //&lt;br /&gt;
    //        One of the core issues when designing the combat system was always&lt;br /&gt;
    //        the fact that the story called for sequences during the game in which&lt;br /&gt;
    //        your main character acts solo.&lt;br /&gt;
    //&lt;br /&gt;
    //        Characters reliant on special abilities, such as rogues, would require&lt;br /&gt;
    //        them to be very effective in order to beat enemies that a standard tank&lt;br /&gt;
    //        can plow through. However, if these abilities would maintain the same&lt;br /&gt;
    //        effectiveness in a full party, most encounters would turn into a stunfest.&lt;br /&gt;
    //&lt;br /&gt;
    //        The solution is to add 1 second flat to each detrimental effect duration&lt;br /&gt;
    //        lasting at least 1 second for each unoccupied slot in the party - before applying&lt;br /&gt;
    //        rank and difficulty modifiers. This also makes solo play a bit more viable.&lt;br /&gt;
    //&lt;br /&gt;
    //        This is in addition to the diminishing returns on quickly successive stuns.&lt;br /&gt;
    //&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    if (!IsPartyMember(oCreature))&lt;br /&gt;
    {&lt;br /&gt;
        float fPartySizeModifier = IntToFloat(Max(0,4 - GetArraySize(GetPartyList())));&lt;br /&gt;
&lt;br /&gt;
        if (fDur &amp;gt;= 1.0f)&lt;br /&gt;
        {&lt;br /&gt;
            fDur += fPartySizeModifier;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    float fRankDurMod = Diff_GetDurationModifier(oCreature);&lt;br /&gt;
    if (fRankDurMod &amp;gt;0.0f)&lt;br /&gt;
    {&lt;br /&gt;
        return (fDur * fRankDurMod);&lt;br /&gt;
    }&lt;br /&gt;
    else&lt;br /&gt;
    {&lt;br /&gt;
     return fDur;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripts]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What does 'asymmetric rules system' mean ? ====&lt;br /&gt;
&lt;br /&gt;
The goal behind Dragon Age: Origin's rule system was to create a fun and challenging video game experience first and foremost. &lt;br /&gt;
&lt;br /&gt;
We describe the rules as 'asymmetric' because a subset of the game rules treats player controlled characters and monsters differently, which is a deviation from pen and paper rule design that often require player and opponents to be treated exactly the same. &lt;br /&gt;
&lt;br /&gt;
Notable Examples:&lt;br /&gt;
* Party members never die permanently (get shattered, etc.)&lt;br /&gt;
* Differently ranked creatures (including party members) get affected for different durations by effects&lt;br /&gt;
* In limited situations in the game, we apply benefits to the player to overcome greater odds than they would usually be able to. &lt;br /&gt;
* Some abilities will work diferently when deployed against the party (although the visual results might be identical).&lt;br /&gt;
* Elimination of instant death situations (not fun!) against players but not against monsters (fun!).&lt;br /&gt;
* Sustained abilities only work for players (the overhead is not justified for monsters that won't ever reappear after they die).&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Ability&amp;diff=7356</id>
		<title>Ability</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Ability&amp;diff=7356"/>
				<updated>2009-10-31T01:36:39Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Detailed Description */ grammar, formatting, punctuation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=== Overview ===&lt;br /&gt;
The Ability System is used to handle Spells, Talents, Skills, and Item Abilities in Dragon Age.&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Spells, Talents, Skills and item abilities all use the same backend in the game, a mostly script implemented system relying heavily on two dimensional data arrays. &lt;br /&gt;
&lt;br /&gt;
The most important 2da file for abilities is '''[[ABI_base.xls]]''', as it defines each ability and all aspects of execution and handling in both scripting and engine code.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Ability Design Notes''' &lt;br /&gt;
&lt;br /&gt;
When creating an ability in Dragon Age: Origins, we generally stick to the following guidelines&lt;br /&gt;
&lt;br /&gt;
* Keep it useful. &lt;br /&gt;
Some constant benefits (such as an increase in Attack or Defense) stay useful for the duration of the game as the progression of the related properties are slow. &lt;br /&gt;
For other effects, such as damage, a constant value would mean that the ability will become progressively worse through the game as damage needed to drop enemies increases from level to level. In such cases, the ability should be tied in some fashion to a Spellpower (for spells) or another relevant trait (such as cunning for rogues) to ensure they stay useful throughout the game. &lt;br /&gt;
&lt;br /&gt;
* No repetition. &lt;br /&gt;
Each ability in Dragon Age: Origins is unique. No incremental abilities such as 'fireball I, fireball II, etc.'. Skills are exempt from this rule. Remember that the Damage Types dramatically alter the actual effect of an ability (such as lightning always draining stamina alongside doing damage), so having similar damaging abilities in different trees is usually fine.&lt;br /&gt;
&lt;br /&gt;
* Thematic matching.&lt;br /&gt;
Abilities within the same chain should follow a common theme. &lt;br /&gt;
&lt;br /&gt;
* Avoid binary abilities. Design hit heavy.&lt;br /&gt;
Avoid abilities that are hit-or-miss. Generally, abilities should hit whenever possible and use target side mitigation of effects (resistance checks, damage mitigation) instead of 'hit or miss' mechanics. Melee abilities may use the normal attack resolution routines but should always perform their attacks at a bonus. Use rank based mitigation and resistances to allow for very powerful effects that do not trivialize boss battles. &lt;br /&gt;
&lt;br /&gt;
* Use meaningful effects&lt;br /&gt;
Abilities should always be worth it. Don't do minor effects (+1 attack). The player should always be able to see the effect of the ability in game (not necessarily visually, but at least through increased damage, etc.). The first ability in a chain should, whenever possible, be active. The fourth ability in a chain should always have the biggest 'bang-for-the-buck' factor. Abilities lower in the chain should have shorter cooldowns. Do not allow instant death on bosses and elite bosses.&lt;br /&gt;
&lt;br /&gt;
* Avoid 'zero-sum' abilities&lt;br /&gt;
When possible, avoid 'zero-sum' abilities that trade a penalty for a benefit (e.g. increase defense but decrease attack). There are a number of these abilities that are valid (such as aim), but balancing them and keeping them useful is hard and requires a lot of work. This obviously does not apply to drastic abilities such as blood magic.&lt;br /&gt;
&lt;br /&gt;
* No emulation of defining class capabilities&lt;br /&gt;
Never ever grant a basic class capability from one class to another class via abilities. This means no invisibility or magical unlock spells for mages, as these are defining capabilities of the rogue class. No weapon talents for mages. No magic spells or large, targeted area of effects for warriors or rogues. Items might blur this line if the cost is balanced properly (e.g. grenades).&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Basic Ability Types ====&lt;br /&gt;
&lt;br /&gt;
Abilities are divided into 4 subtypes, as defined in the 'abilitytype' column in [[ABI_base.xls]]:&lt;br /&gt;
&lt;br /&gt;
* Talents - Abilities used by warriors and rogues, usually non magical in nature. (abilitytype=1)&lt;br /&gt;
* Spells - Abilities used by mages, either spell or passive abilities.  (abilitytype=2)&lt;br /&gt;
* Skills - Abilities usable by all classes, such as Survival and Combat training (abilitytype=3).&lt;br /&gt;
* Items  - Abilities present on an item that are triggered when the item is used on the quickbar. (ability_type=4)&lt;br /&gt;
&lt;br /&gt;
Note: Talents do not show up on mages and spells do not show up on rogue or warrior characters, so to create abilities that can be used by all classes, abilitytype 3 (Skill) must be used. To define under which heading an ability shows up on the character's talent/spell page, the field 'guitype' is used. It resolves against [[guitype.xls]] which lists all known headings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are 3 basic ability types in the game, defined by the field 'use_type' in [[ABI_base.xls]].&lt;br /&gt;
&lt;br /&gt;
'''Passive Abilities''' &lt;br /&gt;
&lt;br /&gt;
Passive abilities (use_type = 3) grant persistent or conditionally persistent bonuses or penalties to the creature that has the ability. &lt;br /&gt;
&lt;br /&gt;
A passive ability may grant up to 3 modifications to creature properties ([[properties.xls]]). Those modifications are defined in the passive_abilities worksheet of [[ABI_base.xls]] and linked to the ability through the passive_id column in ABI_base.xls.&lt;br /&gt;
&lt;br /&gt;
Additionally, the bonuses of an ability can be made conditional on the character's current 'wield mode' (2-handed, dual, weapon &amp;amp; shield, or universal) through the conditional integer field on the passive_abilities worksheet.&lt;br /&gt;
&lt;br /&gt;
Finally, a number of passive abilities do not define any property modifications in passive_abilites but instead have checks coded against their Ids directly in the combat resolution scripts (e.g. HasAbility( oCreature, ABILITY_TALENT_LETHALITY )). The mere presence of the ability on a creature causes a different code path to be taken in the scripts in those cases.&lt;br /&gt;
&lt;br /&gt;
Note that passive_ability benefits are not limited to abilities with use_type 3. Some active abilities also grant additional property modifying benefits to the owner.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sustained Abilities'''&lt;br /&gt;
&lt;br /&gt;
Sustained abilities (use_type = 2) are turned on and off per character and, while turned on, grant effects or property modifications to the user. &lt;br /&gt;
Most 'buffs' are implemented this way.&lt;br /&gt;
&lt;br /&gt;
Only members of the player's party are using sustained ability as the code overhead required to track them is too expensive to be used on monsters that only exist to die in an encounter with the player's party. (These creatures use duration based effects to emulate similar abilities instead).&lt;br /&gt;
&lt;br /&gt;
Most sustained abilities follow the same pattern:&lt;br /&gt;
* They do not have any activation cost, encouraging tactical use of buffs.&lt;br /&gt;
* They increase the users [[Fatigue]] property, therefore increasing the activation cost of all other abilities.&lt;br /&gt;
* They reduce the users maximum available mana or stamina by a constant value.&lt;br /&gt;
* They use cooldown to prevent the user from being too opportunistic with their use.&lt;br /&gt;
* Some abilities shut down when the user reaches 0 mana/stamina. Very powerful abilities (such as Momentum) have an associated stamina/mana drain effect to limit their use to a short or medium period of time. Creative item / buff use can be used to increase the length such an ability can be sustained.&lt;br /&gt;
&lt;br /&gt;
The benefits from sustained abilities are calculated when the ability is activated. So if a character levels up or otherwise changes stats that influence the magnitude of a sustained ability, they will not update until the ability is reactivated the next time.&lt;br /&gt;
&lt;br /&gt;
Some sustained abilities (such as Flaming Weapons) are active 'party-wide' - the caster not only sustains the ability on himself but on all his party members as well. This is controlled by the 'bPartyWide' flag in [[ABI_base.xls]]. Due to implementation limitations, party members who die or otherwise enter/exit the current party will not be affected by these abilities until they are recast. (we put low cooldown times on these abilities for that very reason).&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5faff; border:1px solid #a3b0bf; text-align:left; color:#000; padding:0.2em 0.4em; width:100%; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Gameplay Design Note''' &lt;br /&gt;
* Unlike in games like Baldur's Gate, the system in DA: Origins is designed to encourage tactical use of buffs over strategical. We wanted to put an emphasis on the player making smart choices during an encounter vs. the player guessing which buffs might be useful ahead of time or having to employ save-die-reload to find out. &lt;br /&gt;
&lt;br /&gt;
* It is generally wise to run only one or two buffs all around and activate additional buffs only when needed. &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Activated Abilities'''&lt;br /&gt;
&lt;br /&gt;
Activated abilities (use_type = 4) are abilities that instantly execute their effect (see Targeting Behavior below). Most melee talents or targeted spells fall in this category. There are several sub-types of activated abilies, such as&lt;br /&gt;
&lt;br /&gt;
* Targeted, single target spells and talents (such as Winter's Grasp or Flurry)&lt;br /&gt;
* Ground targeted abilities (such as Blizzard or various Glyphs)&lt;br /&gt;
* Self targeted activated abilities.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Targeting Behavior ====&lt;br /&gt;
&lt;br /&gt;
An abilities targeting behavior is controlled by several settings in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoTarget''' is a boolean field that defines how the UI resolves targeting.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The UI will always bring up a targeting cursor. &lt;br /&gt;
|-&lt;br /&gt;
| 1 || The UI will only produce a targeting cursor if no suitable target is currently selected. e.g if the player currently has a hostile creature targeted and if the spells TargetType includes 0x4 (hostile), the ability will trigger immediately, not producing a targeting cursor. Most single target spells and talents use this setting.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Regardless of AutoTarget setting, the UI will never produce a targeting cursor if an ability is type 0x1 (self) -&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''TargetType''' is a bit mask derived from the following table and controls the behavior of the UI's targeting cursor.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
|'''Bitmask''' || '''Effect'''&lt;br /&gt;
|-&lt;br /&gt;
| 0x1  ||  Self&lt;br /&gt;
|-&lt;br /&gt;
| 0x2 || Friendly Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x4 || Hostile Creature&lt;br /&gt;
|-&lt;br /&gt;
| 0x8 || Placeable Object&lt;br /&gt;
|-&lt;br /&gt;
| 0x10 || Area of Effect Object (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20 || Ground (see details)&lt;br /&gt;
|-&lt;br /&gt;
| 0x40 || Dead Body (deprecated)&lt;br /&gt;
|-&lt;br /&gt;
| 0x80 || Party Member&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''AutoDraw''' is an integer boolean field that defines how a character's weapons are handled when the ability is triggered.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
| 0 || The ability will not affect the player's weapon sheath status.&lt;br /&gt;
|-&lt;br /&gt;
| 1 || The engine will force the player to draw/unsheathe his weapon before executing the ability. This is used for most bow and melee weapon abilities. &lt;br /&gt;
|-&lt;br /&gt;
| 2 || The engine will force the player to stow away any non staff melee weapons before executing the ability. This is used to ensure that no inappropriate animations play with weapons drawn (e.g. the player conjuring with a sword clipping through his body) and to discourage switching between melee and spellcasting on the fly.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Balancing (Cost, Cooldown, etc) ====&lt;br /&gt;
&lt;br /&gt;
Abilities in Dragon Age are balanced along several vectors, most of which boil down to simple 'use frequency'. As a general rule of thumb, the more specialized and limited the effect of an ability is, the more outrageously powerful an ability can be.&lt;br /&gt;
&lt;br /&gt;
Use frequency of abilities can be adjusted by modifying the following field in [[ABI_base.xls]]&lt;br /&gt;
&lt;br /&gt;
* Cost: This is the simple mana (spells) or stamina (talents) activation cost of an ability. It is subtracted when the conjure phase of the spell has succesfully completed (e.g. no cost for spell interruptions). Without sufficient resources to cover activation cost, the UI will not allow the player to execute the ability. The value is a constant integer and is multiplied with 1+(Current Fatigue) of the caster. &lt;br /&gt;
&lt;br /&gt;
* Cooldown: Cooldown is a constant float in seconds that defines how long the player has to wait after the successful activation of an ability until he can use it again. For abilities that apply duration based debuffs or effects to a target, cooldown is usually set slightly higher than the duration of the effect to avoid stacking by the same caster.&lt;br /&gt;
&lt;br /&gt;
* Upkeep: Defines how much mana or stamina is removed from the casters overall pool while a sustained ability is active. This naturally limits the number of sustained abilities present on a creature and ensures that the more beneficial buffs are active on the caster, the less mana is available for immediate use.&lt;br /&gt;
&lt;br /&gt;
* [[Fatigue]]: Fatigue affects use frequency only indirectly, but it prevents characters from stacking too many buffs on each other, as each sustained ability active usually adds around 5-10% fatigue to the caster.&lt;br /&gt;
&lt;br /&gt;
* Mana/Stamina drain: By reducing the mana/stamina regeneration rate on a creature, the duration for which a sustained ability can be used can be restricted. This mechanic is used only for the most powerful sustained abilities in the game, which are flagged to turn off when the caster sustaining them reaches 0 mana/stamina.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Other balancing vectors:&lt;br /&gt;
&lt;br /&gt;
* AoESize and AoeShape: Area of effect spells that deal friendly fire are location and situation restricted on normal+ difficulty (hard+ on the consoles). Since dropping an Inferno on your own party members is hardly a good idea in most cases, the usefulness of the spell becomes restricted to careful positioning and the earlier stages of combat. &lt;br /&gt;
&lt;br /&gt;
* Threat Generation: Abilities apply threat not just by damage but often by activation. Higher activation threat of an ability can balance out outrageously powerful effects by making it harder for the player to use the spell. The prime example is the Walking Bomb kind of spells which deal excellent damage, but, on higher difficulties, also make the targets very very angry at the caster.  Using these spells effectively often requires a tactical approach by the player, thus limiting their universal usefulness and offsetting their very powerful effects.&lt;br /&gt;
&lt;br /&gt;
* Threat Removal: Some abilities are designed to only provide a short term benefit (Such as 3s stun on Mindblast) but offset their weakness by removing threat from the caster, often by reinitializing the threat tables on the target, causing enemies to randomly seek new targets.&lt;br /&gt;
&lt;br /&gt;
* Conjure time: Spells with a conjure time of 1+ (Speed in [[ABI_base.xls]]) can be interrupted by damage, limiting their usefulness in melee situations or when only one party member remains on the battlefield. Many of the very powerful Area of Effect type spells use this feature. Most activated spells have a conjure time of 0, making them instant cast.&lt;br /&gt;
&lt;br /&gt;
* Range: Lower ranges force the ability user into potentially more dangerous situations, adding additional risk to the use of an ability.&lt;br /&gt;
&lt;br /&gt;
=== Q&amp;amp;A ===&lt;br /&gt;
&lt;br /&gt;
==== Q: Where do we find the exact formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Due to most abilities being unique, the only place to find the exact details on each spell is in the scripts. While a lot of data can be glanced from abi_base.xls, a lot of the detailed mechanics are very different between abilities and can only be found in the appropriate spellscript. The *_constant.nss files hold some basic values, but often get further modified in the scripts. &lt;br /&gt;
&lt;br /&gt;
This is also one of the reasons why some elements of a talent are not displayed in the UI description in game. While we can calculate cost and cooldown based on the casting character and his fatigue and other properties (and consequently display it), we can usually not calculate damage or duration as they are mitigated on the target creature: &lt;br /&gt;
&lt;br /&gt;
Displaying those values results in very misleading information (e.g. while damage seems to be higher on one ability, the mitigation mechanisms and unique side effects of another ability will make it just as good or better - in certain situations) and it turned out to be better to provide the player with general guidance than the misleading information.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What is Spellpower and how does it interact with abilities ====&lt;br /&gt;
&lt;br /&gt;
Spellpower is probably the most important stat for a mage character (and only exists on mage characters). It is calculated as max(Magic - 10,0) and therefore increases by one point for every point a mage spends on his Magic attribute.&lt;br /&gt;
&lt;br /&gt;
Most mage spells benefit directly from higher spellpower by increased damage, effect magnitude and duration. It also plays a role in a mages ability to overcome mental or physical resistance on a target (where applicable). The actual impact of spellpower on an ability varies from spell to spell but the most common construct equates to something like 1% increase in spell potency per point of Spellpower. Thus, items and spells that increase spellpower are very powerful as they increase the potency of every spell the mage can cast.&lt;br /&gt;
&lt;br /&gt;
Spellpower is the only factor that causes an increase of a spells potency over time, so a level 20 mage with neglected the Magic attribute would be much less powerful than a mage that didn't neglect Magic.&lt;br /&gt;
&lt;br /&gt;
Some examples:&lt;br /&gt;
&lt;br /&gt;
* The damage potential for Winter's Grasp is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.36f;&lt;br /&gt;
* The healing potential for the heal spell is calculated as (100.0f + GetCreatureSpellPower(stEvent.oCaster)) * 0.40f;&lt;br /&gt;
* The damage over time component of blizzard is executed as ApplyEffectDamageOverTime(a[i], oCreator, ABILITY_SPELL_BLIZZARD,  (100.0f + GetCreatureSpellPower(oCreator)) * 0.1, (BLIZZARD_INTERVAL_DURATION - 0.5f), DAMAGE_TYPE_COLD);&lt;br /&gt;
&lt;br /&gt;
Note that these formulas only list the raw damage potential and do not take into account the effects of damage types, difficulty, rank, resistances, magical shields and any other mitigating factors on the target or enhancing factors on the caster. This means that just comparing the numbers will not give you an idea which spell is better or worse.&lt;br /&gt;
&lt;br /&gt;
For non-mage spells and abilities, spellpower is often substituted by an appropriate other construct (such as max(Cunning-10,0) for rogue abilities).&lt;br /&gt;
&lt;br /&gt;
==== Q: Can we have the damage formula for abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is no damage formula for abilities, as mentioned before, each ability follows their own rules.&lt;br /&gt;
&lt;br /&gt;
In general, talent damage is based on the weapon being used (e.g. Assault does 3 melee attacks that deal weapon damage with some additional bonuses) and are modified by external cirumstances such as location, critical chance and ability to deliver a backstab and are mitigated by armor on the target.&lt;br /&gt;
&lt;br /&gt;
Spells deal damage of different damage types following a rough rule of (Constant * (Spellpower / Variable)) / [Variables] ) + Modifiers but this only tells part of the story as actual damage is dependent on the target, it's resistances, rank and a number of other factors.&lt;br /&gt;
&lt;br /&gt;
Some additional factors affecting spell damage are:&lt;br /&gt;
&lt;br /&gt;
* damage resistance.&lt;br /&gt;
* magical shields.&lt;br /&gt;
* difficulty level.&lt;br /&gt;
* elemental damage bonuses from spells or items &lt;br /&gt;
* Environmental conditions (frozen targets take less damage from fire, etc.)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the differences between damage types? ====&lt;br /&gt;
&lt;br /&gt;
A: Creatures have variable damage resistances based on their type and rank. Dragons might get 60% less damage from fire (60% fire resistance), other creatures will have different immunities. Additional effects are:&lt;br /&gt;
&lt;br /&gt;
* Electricity: In addition to normal damage, these also reduce the targets stamina (but not mana) by the same amount, making them very effective boss killers.&lt;br /&gt;
&lt;br /&gt;
* Fire: Cancels Cold based damage over time effects and applies damage over time.&lt;br /&gt;
&lt;br /&gt;
* Cold: Cancel Fire based damage over time effects and often is accompanied by slow or slipping effects.&lt;br /&gt;
&lt;br /&gt;
* Spirit: There are very few ways of increasing spirit resistance in the game, so spells dealing spirit damage are universally useful...&lt;br /&gt;
&lt;br /&gt;
* Nature: Rarely found on spells. Many creatures are resistant to this.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(This should probably go on its own wiki page)&lt;br /&gt;
&lt;br /&gt;
==== Q: Are sustained abilities mutually exclusive ? ====&lt;br /&gt;
&lt;br /&gt;
A: There is a very limited number of sustained abilities that are mutually exclusive, usually because it makes sense. Mutually exclusive abilities cancel each other upon activation.&lt;br /&gt;
&lt;br /&gt;
* Shield stances (Shield Wall, Shield Cover, Shield Defense) are mutually exclusive.&lt;br /&gt;
* Archery stances (Aim, Rapid Fire, Defensive Fire) are mutually exclusive.&lt;br /&gt;
* Shapeshifting forms are (Sorry, no Bear-Wolfspider) are mutually exclusive.&lt;br /&gt;
* Weapon Enhancement spells are too, but only for the same caster (so two mages can run two different weapon enhancements if they want to).&lt;br /&gt;
* Bard Songs are mutually exclusive.&lt;br /&gt;
* The Death Syphon and Death Magic spells are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
Technically, all abilities in abi_base.xls that share the same 'condition_group' value are mutually exclusive.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What are the rules for stacking effects and damage ? ====&lt;br /&gt;
&lt;br /&gt;
A: The general rules of stacking for abilities are:&lt;br /&gt;
&lt;br /&gt;
* Identical effect from different abilities stack (e.g. getting +10 attack from one ability and +10 attack from another nets +20 attack).&lt;br /&gt;
* The effects of identical abilities stack as long as they are from different caster. (Same caster usually does not apply as cooldown often exceeds duration).&lt;br /&gt;
* Weapon enhancement spells of the same type (e.g. 2 mages with flame weapons) do not stack. The sword does not get more flaming, sorry :)&lt;br /&gt;
* Animation based effects (knockdown, stun, etc.) stack, but only the one with the highest priority is played. This is defined in the priority column in effects.xls. &lt;br /&gt;
* Glyphs do stack but there is a limit of 5 active glyphs per caster.&lt;br /&gt;
* Fire and Cold DoT effects do not stack, the spell cast last will cancel any existing spell of the opposite type.&lt;br /&gt;
* Fire and Cold AoEs cancel each other, other AoEs might interact rather violently, handle with care :)&lt;br /&gt;
&lt;br /&gt;
For equipment and item based effects, the game usually stacks within the minumum and maximum clamp values of a property (properties.xls). This means that you can accumulate a lot of +damage or +critical critical chance effects, but for some type of stats there is a point where you are no longer gaining any benefits (e.g. speed modification - animations can only be sped up to a certain point before breaking, so stacking momentum, haste and a weapon with a speed based effect will not result in a -3.0s attack time, sorry :p)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
For almost all effects, the total result of all property modifications on a creature are visible on the main character UI by hovering over the individual stats.&lt;br /&gt;
&lt;br /&gt;
==== Q: How does game difficulty affect abilities ? ====&lt;br /&gt;
&lt;br /&gt;
A: Our approach to game difficulty dictates that the effect of your chosen setting are&lt;br /&gt;
&lt;br /&gt;
a) non punishing - You do not get less XP for chosing a lower difficulty mode, etc.&lt;br /&gt;
b) challenge scaling - Higher difficulty will reward you with greater obstacles to overcome.&lt;br /&gt;
c) fair - Lower difficulties grant benefits that gradually get removed. (This does not mean the rules are symmetric and is not true on nightmare at all. Nightmare is evil. And unfair.)&lt;br /&gt;
d) non persistent - Difficulty changes are possible on the fly, at any time and take immediate effect.&lt;br /&gt;
&lt;br /&gt;
The game is balanced so that Hard mode is challenging for a Baldur's gate veteran.&lt;br /&gt;
&lt;br /&gt;
Based on these guidelines, you can expect the following ability behaviors in game:&lt;br /&gt;
&lt;br /&gt;
* The lower the difficulty, the longer your hostile effects such as stuns will last on enemies and the shorter they will last on you.&lt;br /&gt;
* The lower the difficulty, the more damage your abilities will do.&lt;br /&gt;
* The lower the difficulty, the less likely the enemy AI will use devastating special abilities (Note: less likely does not mean 'does not use').&lt;br /&gt;
* Casual and Normal have reduced friendly or nullified fire damage damage from area effect spells. Hard and Nightmare require careful positioning and tactical use of spells.&lt;br /&gt;
* The higher the difficulty, the more careful you need to manage threat when using spells and abilities (The AI becomes smarter about picking targets).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What is spell affinity ? ====&lt;br /&gt;
&lt;br /&gt;
A: Spell Affinity was a design we toyed with for a while during development but decided not to implement.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: How does Rank Based Mitigation Work ? ====&lt;br /&gt;
&lt;br /&gt;
A: In line with Dragon Age: Origin's asymmetric approach to rules, the game uses creature ranks (instead of levels) in addition to stats and resistances to define how creatures get affected by abilities. In short: Boss monsters get affected differently by abilities and effects than Lieutenants or Critters. &lt;br /&gt;
&lt;br /&gt;
The rank system is the primary balancing vector for the games difficulty levels and profoundly affects all aspects of combat. The gory details of this system are defined in creature_ranks.xls and difficulty.xls.&lt;br /&gt;
&lt;br /&gt;
Rank mitigation affects not just damage in- and output of a creature, but also the duration that hostile effects persist on it and is different for each difficulty level of the game. Note that party members have their own rank in this system and are handled differently from other creatures in some cases. &lt;br /&gt;
&lt;br /&gt;
Below is the formula used for rank based effect duration mitigation: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
// sys_resistances_h&lt;br /&gt;
// @brief Returns an effect duration scaled by rank of oCreature and game difficulty&lt;br /&gt;
// @author Georg&lt;br /&gt;
float GetRankAdjustedEffectDuration(object oCreature, float fDur)&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    // Georg: This deserves some explanation:&lt;br /&gt;
    //&lt;br /&gt;
    //        One of the core issues when designing the combat system was always&lt;br /&gt;
    //        the fact that the story called for sequences during the game in which&lt;br /&gt;
    //        your main character acts solo.&lt;br /&gt;
    //&lt;br /&gt;
    //        Characters reliant on special abilities, such as rogues, would require&lt;br /&gt;
    //        them to be very effective in order to beat enemies that a standard tank&lt;br /&gt;
    //        can plow through. However, if these abilities would maintain the same&lt;br /&gt;
    //        effectiveness in a full party, most encounters would turn into a stunfest.&lt;br /&gt;
    //&lt;br /&gt;
    //        The solution is to add 1 second flat to each detrimental effect duration&lt;br /&gt;
    //        lasting at least 1 second for each unoccupied slot in the party - before applying&lt;br /&gt;
    //        rank and difficulty modifiers. This also makes solo play a bit more viable.&lt;br /&gt;
    //&lt;br /&gt;
    //        This is in addition to the diminishing returns on quickly successive stuns.&lt;br /&gt;
    //&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    if (!IsPartyMember(oCreature))&lt;br /&gt;
    {&lt;br /&gt;
        float fPartySizeModifier = IntToFloat(Max(0,4 - GetArraySize(GetPartyList())));&lt;br /&gt;
&lt;br /&gt;
        if (fDur &amp;gt;= 1.0f)&lt;br /&gt;
        {&lt;br /&gt;
            fDur += fPartySizeModifier;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    float fRankDurMod = Diff_GetDurationModifier(oCreature);&lt;br /&gt;
    if (fRankDurMod &amp;gt;0.0f)&lt;br /&gt;
    {&lt;br /&gt;
        return (fDur * fRankDurMod);&lt;br /&gt;
    }&lt;br /&gt;
    else&lt;br /&gt;
    {&lt;br /&gt;
     return fDur;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripts]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Q: What does 'asymmetric rules system' mean ? ====&lt;br /&gt;
&lt;br /&gt;
The goal behind Dragon Age: Origin's rule system was to create a fun and challenging video game experience first and foremost. &lt;br /&gt;
&lt;br /&gt;
We describe the rules as 'asymmetric' because a subset of the game rules treats player controlled characters and monsters differently, which is a deviation from pen and paper rule design that often require player and opponents to be treated exactly the same. &lt;br /&gt;
&lt;br /&gt;
Notable Examples:&lt;br /&gt;
* Party members never die permanently (get shattered, etc.)&lt;br /&gt;
* Differently ranked creatures (including party members) get affected for different durations by effects&lt;br /&gt;
* In limited situations in the game, we apply benefits to the player to overcome greater odds than they would usually be able to. &lt;br /&gt;
* Some abilities will work diferently when deployed against the party (although the visual results might be identical).&lt;br /&gt;
* Elimination of instant death situations (not fun!) against players but not against monsters (fun!).&lt;br /&gt;
* Sustained abilities only work for players (the overhead is not justified for monsters that won't ever reappear after they die).&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Combat_damage_h.nss&amp;diff=7355</id>
		<title>Combat damage h.nss</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Combat_damage_h.nss&amp;diff=7355"/>
				<updated>2009-10-30T23:56:29Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Combat_Damage_GetBackstabDamage */ grammar&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=== Overview ===&lt;br /&gt;
&lt;br /&gt;
combat_damage_h.nss handles the core rule resolution logic for non-spell damage.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Notable Functions ===&lt;br /&gt;
&lt;br /&gt;
==== GetCriticalDamageModifier ====&lt;br /&gt;
&lt;br /&gt;
Returns the multiplier for critical hit damage.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
const float COMBAT_CRITICAL_DAMAGE_MODIFIER = 1.5f; // critical hits increase damage increase.&lt;br /&gt;
&lt;br /&gt;
float GetCriticalDamageModifier(object oAttacker)&lt;br /&gt;
{&lt;br /&gt;
    return COMBAT_CRITICAL_DAMAGE_MODIFIER + (GetCreatureProperty(oAttacker, 54 /*PROPERTY_ATTRIBUTE_CRITICAL_RANGE*/) / 100.0);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Combat_Damage_GetBackstabDamage ====&lt;br /&gt;
&lt;br /&gt;
Determines the backstab damage given an attacker and attack damage. (weapon is passed in for future use)&lt;br /&gt;
Note: This function was slightly modified from the toolset version to remove some non-essential elements for clarity.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
float Combat_Damage_GetBackstabDamage(object oAttacker, object oWeapon, float fDamage)&lt;br /&gt;
{&lt;br /&gt;
    //  ------------------------------------------------------------------------&lt;br /&gt;
    // Each backstab does critical damage.&lt;br /&gt;
    //  ------------------------------------------------------------------------&lt;br /&gt;
    fDamage *= GetCriticalDamageModifier(oAttacker);&lt;br /&gt;
&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    // Exploit Weakness:  Backstab Damage + max(CUN-10,0) / 3.0&lt;br /&gt;
    // -------------------------------------------------------------------------&lt;br /&gt;
    if (HasAbility(oAttacker,ABILITY_TALENT_EXPLOIT_WEAKNESS))&lt;br /&gt;
    {&lt;br /&gt;
        float fBase = MaxF(0.0,(GetAttributeModifier(oAttacker,PROPERTY_ATTRIBUTE_CUNNING)/3.0)) ;&lt;br /&gt;
        float fMod = MaxF(0.2,RandomFloat());&lt;br /&gt;
        fDamage += (fBase * fMod);&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    return fDamage;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7354</id>
		<title>Combat Rules</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7354"/>
				<updated>2009-10-30T23:36:27Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Flanking Bonus Determination */ grammar&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''This page is work in progress'''&lt;br /&gt;
&lt;br /&gt;
=== Overview ===&lt;br /&gt;
&lt;br /&gt;
This page describes the technical implementation and flow of combat logic in the game scripts.&lt;br /&gt;
It deals mostly with weapon based combat, for spells and abilities, please see [[Ability|Abilities]].&lt;br /&gt;
&lt;br /&gt;
Note: The term 'property' used on this page refers to [[Creature Properties]].&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Combat in Dragon Age: Origin is handled mainly through scripts - the game engine itself has little knowledge of rule concepts such as 'Strength', 'Damage Modifier' or 'Armor Penetration'.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Hit Resolution  ====&lt;br /&gt;
&lt;br /&gt;
Hit resolution is implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]], which is invoked from the [[creature_core.nss]] script whenever an attack event is received. The function returns one of several [[COMBAT_RESULT|COMBAT_RESULT_*]] constants and handles messaging to the game engine which animation to play.&lt;br /&gt;
&lt;br /&gt;
Overall, Dragon Age: Origin's combat system is 'hit heavy' as a target's armor does not modify its chance of getting hit.&lt;br /&gt;
&lt;br /&gt;
The simplified decision tree for to hit resolution is as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
if Target Is Placeable Object&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
if Target Displacement/Dodge &amp;lt; RandomF(100.0)&lt;br /&gt;
  return COMBAT_RESULT_MISS  &lt;br /&gt;
&lt;br /&gt;
if Attacker Is Using BASE_ITEM_TYPE_STAFF&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
bHit = RandomF(100.0) &amp;lt; AttackRating - DefenseRating&lt;br /&gt;
bCrit = CheckCricital()&lt;br /&gt;
bBackstab = CheckBackstab()&lt;br /&gt;
&lt;br /&gt;
if bHit&lt;br /&gt;
  if  HasEffect(attacker, EFFECT_TYPE_MISDIRECTION_HEX)&lt;br /&gt;
    if bCrit &lt;br /&gt;
      return COMBAT_RESULT_HIT&lt;br /&gt;
    else&lt;br /&gt;
      return COMBAT_RESULT_MISS&lt;br /&gt;
&lt;br /&gt;
  if bBackstab&lt;br /&gt;
    return COMBAT_RESULT_BACKSTAB&lt;br /&gt;
  else&lt;br /&gt;
    if bCrit&lt;br /&gt;
      return COMBAT_RESULT_CRITICAL_HIT&lt;br /&gt;
    else&lt;br /&gt;
      return  COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
else&lt;br /&gt;
  return COMBAT_RESULT_MISS&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Attack Rating =====&lt;br /&gt;
&lt;br /&gt;
Attack rating includes:&lt;br /&gt;
&lt;br /&gt;
* Base attack value (54.0f)&lt;br /&gt;
* + [[#Flanking Bonus Determination|Flanking Bonus]] (position based, modified by attacker and enemy talents and effects as well as shields. Rogues have a bonus here).&lt;br /&gt;
* + Distance based penalties (for ranged attacks)&lt;br /&gt;
* + Attacker's attack property value (this includes modifiers from buffs, etc.)&lt;br /&gt;
* + Any +attack item bonuses on the weapon that performs the attack.&lt;br /&gt;
* + Any external bonuses or penalties passed into the function (from talent scripts, etc.)&lt;br /&gt;
* + Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Defense Rating =====&lt;br /&gt;
&lt;br /&gt;
Defense rating includes:&lt;br /&gt;
&lt;br /&gt;
* Defender defense value and (missile deflection if attack was ranged). This includes items, effects and magical bonus.&lt;br /&gt;
* Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Flanking Bonus Determination =====&lt;br /&gt;
&lt;br /&gt;
* Flanking bonus is a floating point value that applies to both AttackRating and to the chance to score a critical hit.&lt;br /&gt;
* It is essentially a representation of how close the character is to the best position when attacking the enemy (directly in the back)&lt;br /&gt;
* Various shield abilities on the target reduce or prevent the attacker from getting the bonus.&lt;br /&gt;
* The further away the character is from that position, the more the bonus is diluted.&lt;br /&gt;
* The magnitude of the bonus ranges from +0 to +15 (+20 with combat_movement) and is applied to AttackRating and partially (1+(FlankingBonus/5)) to critical hit chance.&lt;br /&gt;
* Most characters only flank 60 degrees in each direction, combat movement allows an increase to 90 degrees (the full back 180).&lt;br /&gt;
* Only rogues get the full flanking bonus, everyone else still gets half.&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_GetFlankingBonus|Combat_GetFlankingBonus]] in [[combat_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Determination =====&lt;br /&gt;
&lt;br /&gt;
* Backstab is determined for each melee attack only.&lt;br /&gt;
* Backstab requires the attacker to have a flanking bonus &amp;gt; 0 (some talents waive this restriction)&lt;br /&gt;
* Only creatures with the Rogue [[Classes|Character Class]] may backstab. This is a class benefit.&lt;br /&gt;
* Only humanoid attackers can backstab (this includes darkspawn)&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_CheckBackstab|Combat_CheckBackstab]] in [[combat_h.nss]].&lt;br /&gt;
* The damage logic is implemented in [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Determination =====&lt;br /&gt;
&lt;br /&gt;
* Critical Hit Chance uses the attackers Melee or Ranged critical hit modifier based on attack type.&lt;br /&gt;
* + the attacking weapon's critical hit modifier stat.&lt;br /&gt;
* + 1.20x (1.1x for non rogues) the attacker's [[#Flanking Bonus Determination|Flanking Bonus]] in the current situation.&lt;br /&gt;
* + 3.5 for each enemy past the 2nd that is fighting a warriors with the bravery talent.&lt;br /&gt;
* A critical hit occurs when the resulting CriticalHitChance is smaller than RandomFloat()*100.0f.&lt;br /&gt;
* Certain effects and spells (e.g. Death Hex) can always override the result, as will attacking from stealth (always hits critical).&lt;br /&gt;
* The logic is  implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]]&lt;br /&gt;
&lt;br /&gt;
==== Damage Resolution ====&lt;br /&gt;
&lt;br /&gt;
Damage resolution logic is implemented in the script [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Critical hits increase the amount of damage done by an attack by a fixed multiplier.&lt;br /&gt;
* The magnitude of the multiplier can be affected by items and effects, but is not affected by of the character's attributes.&lt;br /&gt;
* Historical Note: Critical damage used to be variable 'up to...', but was changed to constant to provide a more predictable flow of damage.&lt;br /&gt;
* The logic for critical damage is implemented in [[combat_damage_h.nss#GetCriticalDamageModifier]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Backstab damage is essentially identical to critical damage, but modified by certain rogue talents.&lt;br /&gt;
* The full logic is implemented [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]] in [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
[[Category: Scripts]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7353</id>
		<title>Combat Rules</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7353"/>
				<updated>2009-10-30T23:29:49Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Hit Resolution */ indentation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''This page is work in progress'''&lt;br /&gt;
&lt;br /&gt;
=== Overview ===&lt;br /&gt;
&lt;br /&gt;
This page describes the technical implementation and flow of combat logic in the game scripts.&lt;br /&gt;
It deals mostly with weapon based combat, for spells and abilities, please see [[Ability|Abilities]].&lt;br /&gt;
&lt;br /&gt;
Note: The term 'property' used on this page refers to [[Creature Properties]].&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Combat in Dragon Age: Origin is handled mainly through scripts - the game engine itself has little knowledge of rule concepts such as 'Strength', 'Damage Modifier' or 'Armor Penetration'.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Hit Resolution  ====&lt;br /&gt;
&lt;br /&gt;
Hit resolution is implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]], which is invoked from the [[creature_core.nss]] script whenever an attack event is received. The function returns one of several [[COMBAT_RESULT|COMBAT_RESULT_*]] constants and handles messaging to the game engine which animation to play.&lt;br /&gt;
&lt;br /&gt;
Overall, Dragon Age: Origin's combat system is 'hit heavy' as a target's armor does not modify its chance of getting hit.&lt;br /&gt;
&lt;br /&gt;
The simplified decision tree for to hit resolution is as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
if Target Is Placeable Object&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
if Target Displacement/Dodge &amp;lt; RandomF(100.0)&lt;br /&gt;
  return COMBAT_RESULT_MISS  &lt;br /&gt;
&lt;br /&gt;
if Attacker Is Using BASE_ITEM_TYPE_STAFF&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
bHit = RandomF(100.0) &amp;lt; AttackRating - DefenseRating&lt;br /&gt;
bCrit = CheckCricital()&lt;br /&gt;
bBackstab = CheckBackstab()&lt;br /&gt;
&lt;br /&gt;
if bHit&lt;br /&gt;
  if  HasEffect(attacker, EFFECT_TYPE_MISDIRECTION_HEX)&lt;br /&gt;
    if bCrit &lt;br /&gt;
      return COMBAT_RESULT_HIT&lt;br /&gt;
    else&lt;br /&gt;
      return COMBAT_RESULT_MISS&lt;br /&gt;
&lt;br /&gt;
  if bBackstab&lt;br /&gt;
    return COMBAT_RESULT_BACKSTAB&lt;br /&gt;
  else&lt;br /&gt;
    if bCrit&lt;br /&gt;
      return COMBAT_RESULT_CRITICAL_HIT&lt;br /&gt;
    else&lt;br /&gt;
      return  COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
else&lt;br /&gt;
  return COMBAT_RESULT_MISS&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Attack Rating =====&lt;br /&gt;
&lt;br /&gt;
Attack rating includes:&lt;br /&gt;
&lt;br /&gt;
* Base attack value (54.0f)&lt;br /&gt;
* + [[#Flanking Bonus Determination|Flanking Bonus]] (position based, modified by attacker and enemy talents and effects as well as shields. Rogues have a bonus here).&lt;br /&gt;
* + Distance based penalties (for ranged attacks)&lt;br /&gt;
* + Attacker's attack property value (this includes modifiers from buffs, etc.)&lt;br /&gt;
* + Any +attack item bonuses on the weapon that performs the attack.&lt;br /&gt;
* + Any external bonuses or penalties passed into the function (from talent scripts, etc.)&lt;br /&gt;
* + Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Defense Rating =====&lt;br /&gt;
&lt;br /&gt;
Defense rating includes:&lt;br /&gt;
&lt;br /&gt;
* Defender defense value and (missile deflection if attack was ranged). This includes items, effects and magical bonus.&lt;br /&gt;
* Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Flanking Bonus Determination =====&lt;br /&gt;
&lt;br /&gt;
* Flanking bonus is a floating point value that applies to both AttackRating and to the chance to score a critical hit.&lt;br /&gt;
* It is essentially a representation of close the character is to the best position when attacking the enemy (directly in the back)&lt;br /&gt;
* Various shield abilities on the target reduce or prevent the attacker from getting the bonus.&lt;br /&gt;
* The further away the character is from that position, the more the bonus is diluted.&lt;br /&gt;
* The magnitude of the bonus ranges from +0 to +15 (+20 with combat_movement) and is applied to AttackRating and partially (1+(FlankingBonus/5)) to critical hit chance.&lt;br /&gt;
* Most characters only flank 60 degrees in each direction, combat movement allows an increase to 90 degrees (the full back 180).&lt;br /&gt;
* Only rogues get the full flanking bonus, everyone else still gets half.&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_GetFlankingBonus|Combat_GetFlankingBonus]] in [[combat_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Determination =====&lt;br /&gt;
&lt;br /&gt;
* Backstab is determined for each melee attack only.&lt;br /&gt;
* Backstab requires the attacker to have a flanking bonus &amp;gt; 0 (some talents waive this restriction)&lt;br /&gt;
* Only creatures with the Rogue [[Classes|Character Class]] may backstab. This is a class benefit.&lt;br /&gt;
* Only humanoid attackers can backstab (this includes darkspawn)&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_CheckBackstab|Combat_CheckBackstab]] in [[combat_h.nss]].&lt;br /&gt;
* The damage logic is implemented in [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Determination =====&lt;br /&gt;
&lt;br /&gt;
* Critical Hit Chance uses the attackers Melee or Ranged critical hit modifier based on attack type.&lt;br /&gt;
* + the attacking weapon's critical hit modifier stat.&lt;br /&gt;
* + 1.20x (1.1x for non rogues) the attacker's [[#Flanking Bonus Determination|Flanking Bonus]] in the current situation.&lt;br /&gt;
* + 3.5 for each enemy past the 2nd that is fighting a warriors with the bravery talent.&lt;br /&gt;
* A critical hit occurs when the resulting CriticalHitChance is smaller than RandomFloat()*100.0f.&lt;br /&gt;
* Certain effects and spells (e.g. Death Hex) can always override the result, as will attacking from stealth (always hits critical).&lt;br /&gt;
* The logic is  implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]]&lt;br /&gt;
&lt;br /&gt;
==== Damage Resolution ====&lt;br /&gt;
&lt;br /&gt;
Damage resolution logic is implemented in the script [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Critical hits increase the amount of damage done by an attack by a fixed multiplier.&lt;br /&gt;
* The magnitude of the multiplier can be affected by items and effects, but is not affected by of the character's attributes.&lt;br /&gt;
* Historical Note: Critical damage used to be variable 'up to...', but was changed to constant to provide a more predictable flow of damage.&lt;br /&gt;
* The logic for critical damage is implemented in [[combat_damage_h.nss#GetCriticalDamageModifier]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Backstab damage is essentially identical to critical damage, but modified by certain rogue talents.&lt;br /&gt;
* The full logic is implemented [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]] in [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
[[Category: Scripts]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7352</id>
		<title>Combat Rules</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7352"/>
				<updated>2009-10-30T23:28:00Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Hit Resolution */ indentation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''This page is work in progress'''&lt;br /&gt;
&lt;br /&gt;
=== Overview ===&lt;br /&gt;
&lt;br /&gt;
This page describes the technical implementation and flow of combat logic in the game scripts.&lt;br /&gt;
It deals mostly with weapon based combat, for spells and abilities, please see [[Ability|Abilities]].&lt;br /&gt;
&lt;br /&gt;
Note: The term 'property' used on this page refers to [[Creature Properties]].&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Combat in Dragon Age: Origin is handled mainly through scripts - the game engine itself has little knowledge of rule concepts such as 'Strength', 'Damage Modifier' or 'Armor Penetration'.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Hit Resolution  ====&lt;br /&gt;
&lt;br /&gt;
Hit resolution is implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]], which is invoked from the [[creature_core.nss]] script whenever an attack event is received. The function returns one of several [[COMBAT_RESULT|COMBAT_RESULT_*]] constants and handles messaging to the game engine which animation to play.&lt;br /&gt;
&lt;br /&gt;
Overall, Dragon Age: Origin's combat system is 'hit heavy' as a target's armor does not modify its chance of getting hit.&lt;br /&gt;
&lt;br /&gt;
The simplified decision tree for to hit resolution is as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
if Target Is Placeable Object&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
if Target Displacement/Dodge &amp;lt; RandomF(100.0)&lt;br /&gt;
  return COMBAT_RESULT_MISS  &lt;br /&gt;
&lt;br /&gt;
if Attacker Is Using BASE_ITEM_TYPE_STAFF&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
bHit = RandomF(100.0) &amp;lt; AttackRating - DefenseRating&lt;br /&gt;
bCrit = CheckCricital()&lt;br /&gt;
bBackstab = CheckBackstab()&lt;br /&gt;
&lt;br /&gt;
if bHit&lt;br /&gt;
  if  HasEffect(attacker, EFFECT_TYPE_MISDIRECTION_HEX)&lt;br /&gt;
    if bCrit &lt;br /&gt;
      return COMBAT_RESULT_HIT&lt;br /&gt;
    else&lt;br /&gt;
      return COMBAT_RESULT_MISS&lt;br /&gt;
&lt;br /&gt;
 if bBackstab&lt;br /&gt;
   return COMBAT_RESULT_BACKSTAB&lt;br /&gt;
 else&lt;br /&gt;
   if bCrit&lt;br /&gt;
     return COMBAT_RESULT_CRITICAL_HIT&lt;br /&gt;
   else&lt;br /&gt;
     return  COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
 else&lt;br /&gt;
   return COMBAT_RESULT_MISS&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Attack Rating =====&lt;br /&gt;
&lt;br /&gt;
Attack rating includes:&lt;br /&gt;
&lt;br /&gt;
* Base attack value (54.0f)&lt;br /&gt;
* + [[#Flanking Bonus Determination|Flanking Bonus]] (position based, modified by attacker and enemy talents and effects as well as shields. Rogues have a bonus here).&lt;br /&gt;
* + Distance based penalties (for ranged attacks)&lt;br /&gt;
* + Attacker's attack property value (this includes modifiers from buffs, etc.)&lt;br /&gt;
* + Any +attack item bonuses on the weapon that performs the attack.&lt;br /&gt;
* + Any external bonuses or penalties passed into the function (from talent scripts, etc.)&lt;br /&gt;
* + Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Defense Rating =====&lt;br /&gt;
&lt;br /&gt;
Defense rating includes:&lt;br /&gt;
&lt;br /&gt;
* Defender defense value and (missile deflection if attack was ranged). This includes items, effects and magical bonus.&lt;br /&gt;
* Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Flanking Bonus Determination =====&lt;br /&gt;
&lt;br /&gt;
* Flanking bonus is a floating point value that applies to both AttackRating and to the chance to score a critical hit.&lt;br /&gt;
* It is essentially a representation of close the character is to the best position when attacking the enemy (directly in the back)&lt;br /&gt;
* Various shield abilities on the target reduce or prevent the attacker from getting the bonus.&lt;br /&gt;
* The further away the character is from that position, the more the bonus is diluted.&lt;br /&gt;
* The magnitude of the bonus ranges from +0 to +15 (+20 with combat_movement) and is applied to AttackRating and partially (1+(FlankingBonus/5)) to critical hit chance.&lt;br /&gt;
* Most characters only flank 60 degrees in each direction, combat movement allows an increase to 90 degrees (the full back 180).&lt;br /&gt;
* Only rogues get the full flanking bonus, everyone else still gets half.&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_GetFlankingBonus|Combat_GetFlankingBonus]] in [[combat_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Determination =====&lt;br /&gt;
&lt;br /&gt;
* Backstab is determined for each melee attack only.&lt;br /&gt;
* Backstab requires the attacker to have a flanking bonus &amp;gt; 0 (some talents waive this restriction)&lt;br /&gt;
* Only creatures with the Rogue [[Classes|Character Class]] may backstab. This is a class benefit.&lt;br /&gt;
* Only humanoid attackers can backstab (this includes darkspawn)&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_CheckBackstab|Combat_CheckBackstab]] in [[combat_h.nss]].&lt;br /&gt;
* The damage logic is implemented in [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Determination =====&lt;br /&gt;
&lt;br /&gt;
* Critical Hit Chance uses the attackers Melee or Ranged critical hit modifier based on attack type.&lt;br /&gt;
* + the attacking weapon's critical hit modifier stat.&lt;br /&gt;
* + 1.20x (1.1x for non rogues) the attacker's [[#Flanking Bonus Determination|Flanking Bonus]] in the current situation.&lt;br /&gt;
* + 3.5 for each enemy past the 2nd that is fighting a warriors with the bravery talent.&lt;br /&gt;
* A critical hit occurs when the resulting CriticalHitChance is smaller than RandomFloat()*100.0f.&lt;br /&gt;
* Certain effects and spells (e.g. Death Hex) can always override the result, as will attacking from stealth (always hits critical).&lt;br /&gt;
* The logic is  implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]]&lt;br /&gt;
&lt;br /&gt;
==== Damage Resolution ====&lt;br /&gt;
&lt;br /&gt;
Damage resolution logic is implemented in the script [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Critical hits increase the amount of damage done by an attack by a fixed multiplier.&lt;br /&gt;
* The magnitude of the multiplier can be affected by items and effects, but is not affected by of the character's attributes.&lt;br /&gt;
* Historical Note: Critical damage used to be variable 'up to...', but was changed to constant to provide a more predictable flow of damage.&lt;br /&gt;
* The logic for critical damage is implemented in [[combat_damage_h.nss#GetCriticalDamageModifier]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Backstab damage is essentially identical to critical damage, but modified by certain rogue talents.&lt;br /&gt;
* The full logic is implemented [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]] in [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
[[Category: Scripts]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7351</id>
		<title>Combat Rules</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7351"/>
				<updated>2009-10-30T23:27:11Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Hit Resolution */ indentation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''This page is work in progress'''&lt;br /&gt;
&lt;br /&gt;
=== Overview ===&lt;br /&gt;
&lt;br /&gt;
This page describes the technical implementation and flow of combat logic in the game scripts.&lt;br /&gt;
It deals mostly with weapon based combat, for spells and abilities, please see [[Ability|Abilities]].&lt;br /&gt;
&lt;br /&gt;
Note: The term 'property' used on this page refers to [[Creature Properties]].&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Combat in Dragon Age: Origin is handled mainly through scripts - the game engine itself has little knowledge of rule concepts such as 'Strength', 'Damage Modifier' or 'Armor Penetration'.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Hit Resolution  ====&lt;br /&gt;
&lt;br /&gt;
Hit resolution is implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]], which is invoked from the [[creature_core.nss]] script whenever an attack event is received. The function returns one of several [[COMBAT_RESULT|COMBAT_RESULT_*]] constants and handles messaging to the game engine which animation to play.&lt;br /&gt;
&lt;br /&gt;
Overall, Dragon Age: Origin's combat system is 'hit heavy' as a target's armor does not modify its chance of getting hit.&lt;br /&gt;
&lt;br /&gt;
The simplified decision tree for to hit resolution is as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
if Target Is Placeable Object&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
if Target Displacement/Dodge &amp;lt; RandomF(100.0)&lt;br /&gt;
  return COMBAT_RESULT_MISS  &lt;br /&gt;
&lt;br /&gt;
if Attacker Is Using BASE_ITEM_TYPE_STAFF&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
bHit = RandomF(100.0) &amp;lt; AttackRating - DefenseRating&lt;br /&gt;
bCrit = CheckCricital()&lt;br /&gt;
bBackstab = CheckBackstab()&lt;br /&gt;
&lt;br /&gt;
if bHit&lt;br /&gt;
  if  HasEffect(attacker, EFFECT_TYPE_MISDIRECTION_HEX)&lt;br /&gt;
    if bCrit &lt;br /&gt;
      return COMBAT_RESULT_HIT&lt;br /&gt;
    else&lt;br /&gt;
      return COMBAT_RESULT_MISS&lt;br /&gt;
&lt;br /&gt;
 if bBackstab&lt;br /&gt;
    return COMBAT_RESULT_BACKSTAB&lt;br /&gt;
 else&lt;br /&gt;
    if bCrit&lt;br /&gt;
      return COMBAT_RESULT_CRITICAL_HIT&lt;br /&gt;
    else&lt;br /&gt;
      return  COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
 else&lt;br /&gt;
   return COMBAT_RESULT_MISS&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Attack Rating =====&lt;br /&gt;
&lt;br /&gt;
Attack rating includes:&lt;br /&gt;
&lt;br /&gt;
* Base attack value (54.0f)&lt;br /&gt;
* + [[#Flanking Bonus Determination|Flanking Bonus]] (position based, modified by attacker and enemy talents and effects as well as shields. Rogues have a bonus here).&lt;br /&gt;
* + Distance based penalties (for ranged attacks)&lt;br /&gt;
* + Attacker's attack property value (this includes modifiers from buffs, etc.)&lt;br /&gt;
* + Any +attack item bonuses on the weapon that performs the attack.&lt;br /&gt;
* + Any external bonuses or penalties passed into the function (from talent scripts, etc.)&lt;br /&gt;
* + Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Defense Rating =====&lt;br /&gt;
&lt;br /&gt;
Defense rating includes:&lt;br /&gt;
&lt;br /&gt;
* Defender defense value and (missile deflection if attack was ranged). This includes items, effects and magical bonus.&lt;br /&gt;
* Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Flanking Bonus Determination =====&lt;br /&gt;
&lt;br /&gt;
* Flanking bonus is a floating point value that applies to both AttackRating and to the chance to score a critical hit.&lt;br /&gt;
* It is essentially a representation of close the character is to the best position when attacking the enemy (directly in the back)&lt;br /&gt;
* Various shield abilities on the target reduce or prevent the attacker from getting the bonus.&lt;br /&gt;
* The further away the character is from that position, the more the bonus is diluted.&lt;br /&gt;
* The magnitude of the bonus ranges from +0 to +15 (+20 with combat_movement) and is applied to AttackRating and partially (1+(FlankingBonus/5)) to critical hit chance.&lt;br /&gt;
* Most characters only flank 60 degrees in each direction, combat movement allows an increase to 90 degrees (the full back 180).&lt;br /&gt;
* Only rogues get the full flanking bonus, everyone else still gets half.&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_GetFlankingBonus|Combat_GetFlankingBonus]] in [[combat_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Determination =====&lt;br /&gt;
&lt;br /&gt;
* Backstab is determined for each melee attack only.&lt;br /&gt;
* Backstab requires the attacker to have a flanking bonus &amp;gt; 0 (some talents waive this restriction)&lt;br /&gt;
* Only creatures with the Rogue [[Classes|Character Class]] may backstab. This is a class benefit.&lt;br /&gt;
* Only humanoid attackers can backstab (this includes darkspawn)&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_CheckBackstab|Combat_CheckBackstab]] in [[combat_h.nss]].&lt;br /&gt;
* The damage logic is implemented in [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Determination =====&lt;br /&gt;
&lt;br /&gt;
* Critical Hit Chance uses the attackers Melee or Ranged critical hit modifier based on attack type.&lt;br /&gt;
* + the attacking weapon's critical hit modifier stat.&lt;br /&gt;
* + 1.20x (1.1x for non rogues) the attacker's [[#Flanking Bonus Determination|Flanking Bonus]] in the current situation.&lt;br /&gt;
* + 3.5 for each enemy past the 2nd that is fighting a warriors with the bravery talent.&lt;br /&gt;
* A critical hit occurs when the resulting CriticalHitChance is smaller than RandomFloat()*100.0f.&lt;br /&gt;
* Certain effects and spells (e.g. Death Hex) can always override the result, as will attacking from stealth (always hits critical).&lt;br /&gt;
* The logic is  implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]]&lt;br /&gt;
&lt;br /&gt;
==== Damage Resolution ====&lt;br /&gt;
&lt;br /&gt;
Damage resolution logic is implemented in the script [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Critical hits increase the amount of damage done by an attack by a fixed multiplier.&lt;br /&gt;
* The magnitude of the multiplier can be affected by items and effects, but is not affected by of the character's attributes.&lt;br /&gt;
* Historical Note: Critical damage used to be variable 'up to...', but was changed to constant to provide a more predictable flow of damage.&lt;br /&gt;
* The logic for critical damage is implemented in [[combat_damage_h.nss#GetCriticalDamageModifier]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Backstab damage is essentially identical to critical damage, but modified by certain rogue talents.&lt;br /&gt;
* The full logic is implemented [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]] in [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
[[Category: Scripts]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7350</id>
		<title>Combat Rules</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7350"/>
				<updated>2009-10-30T23:26:26Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Hit Resolution */ spacing&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''This page is work in progress'''&lt;br /&gt;
&lt;br /&gt;
=== Overview ===&lt;br /&gt;
&lt;br /&gt;
This page describes the technical implementation and flow of combat logic in the game scripts.&lt;br /&gt;
It deals mostly with weapon based combat, for spells and abilities, please see [[Ability|Abilities]].&lt;br /&gt;
&lt;br /&gt;
Note: The term 'property' used on this page refers to [[Creature Properties]].&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Combat in Dragon Age: Origin is handled mainly through scripts - the game engine itself has little knowledge of rule concepts such as 'Strength', 'Damage Modifier' or 'Armor Penetration'.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Hit Resolution  ====&lt;br /&gt;
&lt;br /&gt;
Hit resolution is implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]], which is invoked from the [[creature_core.nss]] script whenever an attack event is received. The function returns one of several [[COMBAT_RESULT|COMBAT_RESULT_*]] constants and handles messaging to the game engine which animation to play.&lt;br /&gt;
&lt;br /&gt;
Overall, Dragon Age: Origin's combat system is 'hit heavy' as a target's armor does not modify its chance of getting hit.&lt;br /&gt;
&lt;br /&gt;
The simplified decision tree for to hit resolution is as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
if Target Is Placeable Object&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
if Target Displacement/Dodge &amp;lt; RandomF(100.0)&lt;br /&gt;
  return COMBAT_RESULT_MISS  &lt;br /&gt;
&lt;br /&gt;
if Attacker Is Using BASE_ITEM_TYPE_STAFF&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
bHit = RandomF(100.0) &amp;lt; AttackRating - DefenseRating&lt;br /&gt;
bCrit = CheckCricital()&lt;br /&gt;
bBackstab = CheckBackstab()&lt;br /&gt;
&lt;br /&gt;
if bHit&lt;br /&gt;
  if  HasEffect(attacker, EFFECT_TYPE_MISDIRECTION_HEX)&lt;br /&gt;
    if bCrit &lt;br /&gt;
      return COMBAT_RESULT_HIT&lt;br /&gt;
    else&lt;br /&gt;
      return COMBAT_RESULT_MISS&lt;br /&gt;
&lt;br /&gt;
 if bBackstab&lt;br /&gt;
    return COMBAT_RESULT_BACKSTAB&lt;br /&gt;
 else&lt;br /&gt;
    if bCrit&lt;br /&gt;
      return COMBAT_RESULT_CRITICAL_HIT&lt;br /&gt;
    else&lt;br /&gt;
      return  COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
 else&lt;br /&gt;
  return COMBAT_RESULT_MISS&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Attack Rating =====&lt;br /&gt;
&lt;br /&gt;
Attack rating includes:&lt;br /&gt;
&lt;br /&gt;
* Base attack value (54.0f)&lt;br /&gt;
* + [[#Flanking Bonus Determination|Flanking Bonus]] (position based, modified by attacker and enemy talents and effects as well as shields. Rogues have a bonus here).&lt;br /&gt;
* + Distance based penalties (for ranged attacks)&lt;br /&gt;
* + Attacker's attack property value (this includes modifiers from buffs, etc.)&lt;br /&gt;
* + Any +attack item bonuses on the weapon that performs the attack.&lt;br /&gt;
* + Any external bonuses or penalties passed into the function (from talent scripts, etc.)&lt;br /&gt;
* + Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Defense Rating =====&lt;br /&gt;
&lt;br /&gt;
Defense rating includes:&lt;br /&gt;
&lt;br /&gt;
* Defender defense value and (missile deflection if attack was ranged). This includes items, effects and magical bonus.&lt;br /&gt;
* Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Flanking Bonus Determination =====&lt;br /&gt;
&lt;br /&gt;
* Flanking bonus is a floating point value that applies to both AttackRating and to the chance to score a critical hit.&lt;br /&gt;
* It is essentially a representation of close the character is to the best position when attacking the enemy (directly in the back)&lt;br /&gt;
* Various shield abilities on the target reduce or prevent the attacker from getting the bonus.&lt;br /&gt;
* The further away the character is from that position, the more the bonus is diluted.&lt;br /&gt;
* The magnitude of the bonus ranges from +0 to +15 (+20 with combat_movement) and is applied to AttackRating and partially (1+(FlankingBonus/5)) to critical hit chance.&lt;br /&gt;
* Most characters only flank 60 degrees in each direction, combat movement allows an increase to 90 degrees (the full back 180).&lt;br /&gt;
* Only rogues get the full flanking bonus, everyone else still gets half.&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_GetFlankingBonus|Combat_GetFlankingBonus]] in [[combat_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Determination =====&lt;br /&gt;
&lt;br /&gt;
* Backstab is determined for each melee attack only.&lt;br /&gt;
* Backstab requires the attacker to have a flanking bonus &amp;gt; 0 (some talents waive this restriction)&lt;br /&gt;
* Only creatures with the Rogue [[Classes|Character Class]] may backstab. This is a class benefit.&lt;br /&gt;
* Only humanoid attackers can backstab (this includes darkspawn)&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_CheckBackstab|Combat_CheckBackstab]] in [[combat_h.nss]].&lt;br /&gt;
* The damage logic is implemented in [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Determination =====&lt;br /&gt;
&lt;br /&gt;
* Critical Hit Chance uses the attackers Melee or Ranged critical hit modifier based on attack type.&lt;br /&gt;
* + the attacking weapon's critical hit modifier stat.&lt;br /&gt;
* + 1.20x (1.1x for non rogues) the attacker's [[#Flanking Bonus Determination|Flanking Bonus]] in the current situation.&lt;br /&gt;
* + 3.5 for each enemy past the 2nd that is fighting a warriors with the bravery talent.&lt;br /&gt;
* A critical hit occurs when the resulting CriticalHitChance is smaller than RandomFloat()*100.0f.&lt;br /&gt;
* Certain effects and spells (e.g. Death Hex) can always override the result, as will attacking from stealth (always hits critical).&lt;br /&gt;
* The logic is  implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]]&lt;br /&gt;
&lt;br /&gt;
==== Damage Resolution ====&lt;br /&gt;
&lt;br /&gt;
Damage resolution logic is implemented in the script [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Critical hits increase the amount of damage done by an attack by a fixed multiplier.&lt;br /&gt;
* The magnitude of the multiplier can be affected by items and effects, but is not affected by of the character's attributes.&lt;br /&gt;
* Historical Note: Critical damage used to be variable 'up to...', but was changed to constant to provide a more predictable flow of damage.&lt;br /&gt;
* The logic for critical damage is implemented in [[combat_damage_h.nss#GetCriticalDamageModifier]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Backstab damage is essentially identical to critical damage, but modified by certain rogue talents.&lt;br /&gt;
* The full logic is implemented [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]] in [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
[[Category: Scripts]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7349</id>
		<title>Combat Rules</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Combat_Rules&amp;diff=7349"/>
				<updated>2009-10-30T23:22:59Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Hit Resolution */ punctuation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''This page is work in progress'''&lt;br /&gt;
&lt;br /&gt;
=== Overview ===&lt;br /&gt;
&lt;br /&gt;
This page describes the technical implementation and flow of combat logic in the game scripts.&lt;br /&gt;
It deals mostly with weapon based combat, for spells and abilities, please see [[Ability|Abilities]].&lt;br /&gt;
&lt;br /&gt;
Note: The term 'property' used on this page refers to [[Creature Properties]].&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Combat in Dragon Age: Origin is handled mainly through scripts - the game engine itself has little knowledge of rule concepts such as 'Strength', 'Damage Modifier' or 'Armor Penetration'.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Hit Resolution  ====&lt;br /&gt;
&lt;br /&gt;
Hit resolution is implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]], which is invoked from the [[creature_core.nss]] script whenever an attack event is received. The function returns one of several [[COMBAT_RESULT|COMBAT_RESULT_*]] constants and handles messaging to the game engine which animation to play.&lt;br /&gt;
&lt;br /&gt;
Overall, Dragon Age: Origin's combat system is 'hit heavy' as a target's armor does not modify its chance of getting hit.&lt;br /&gt;
&lt;br /&gt;
The simplified decision tree for to hit resolution is as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
if Target Is Placeable Object&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
if Target Displacement/Dodge &amp;lt; RandomF(100.0)&lt;br /&gt;
  return COMBAT_RESULT_MISS  &lt;br /&gt;
&lt;br /&gt;
if Attacker Is Using BASE_ITEM_TYPE_STAFF&lt;br /&gt;
  return COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
bHit = RandomF(100.0) &amp;lt; AttackRating - DefenseRating&lt;br /&gt;
bCrit = CheckCricital()&lt;br /&gt;
bBackstab = CheckBackstab()&lt;br /&gt;
&lt;br /&gt;
if bHit&lt;br /&gt;
  if  HasEffect(attacker, EFFECT_TYPE_MISDIRECTION_HEX)&lt;br /&gt;
    if bCrit &lt;br /&gt;
      return COMBAT_RESULT_HIT&lt;br /&gt;
    else&lt;br /&gt;
      return COMBAT_RESULT_MISS&lt;br /&gt;
&lt;br /&gt;
 if bBackstab&lt;br /&gt;
    return COMBAT_RESULT_BACKSTAB&lt;br /&gt;
  else&lt;br /&gt;
     if bCrit&lt;br /&gt;
       return COMBAT_RESULT_CRITICAL_HIT&lt;br /&gt;
     else&lt;br /&gt;
       return  COMBAT_RESULT_HIT&lt;br /&gt;
&lt;br /&gt;
  else&lt;br /&gt;
   return COMBAT_RESULT_MISS&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;/dascript&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Attack Rating =====&lt;br /&gt;
&lt;br /&gt;
Attack rating includes:&lt;br /&gt;
&lt;br /&gt;
* Base attack value (54.0f)&lt;br /&gt;
* + [[#Flanking Bonus Determination|Flanking Bonus]] (position based, modified by attacker and enemy talents and effects as well as shields. Rogues have a bonus here).&lt;br /&gt;
* + Distance based penalties (for ranged attacks)&lt;br /&gt;
* + Attacker's attack property value (this includes modifiers from buffs, etc.)&lt;br /&gt;
* + Any +attack item bonuses on the weapon that performs the attack.&lt;br /&gt;
* + Any external bonuses or penalties passed into the function (from talent scripts, etc.)&lt;br /&gt;
* + Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Defense Rating =====&lt;br /&gt;
&lt;br /&gt;
Defense rating includes:&lt;br /&gt;
&lt;br /&gt;
* Defender defense value and (missile deflection if attack was ranged). This includes items, effects and magical bonus.&lt;br /&gt;
* Difficulty setting based modifications&lt;br /&gt;
&lt;br /&gt;
===== Flanking Bonus Determination =====&lt;br /&gt;
&lt;br /&gt;
* Flanking bonus is a floating point value that applies to both AttackRating and to the chance to score a critical hit.&lt;br /&gt;
* It is essentially a representation of close the character is to the best position when attacking the enemy (directly in the back)&lt;br /&gt;
* Various shield abilities on the target reduce or prevent the attacker from getting the bonus.&lt;br /&gt;
* The further away the character is from that position, the more the bonus is diluted.&lt;br /&gt;
* The magnitude of the bonus ranges from +0 to +15 (+20 with combat_movement) and is applied to AttackRating and partially (1+(FlankingBonus/5)) to critical hit chance.&lt;br /&gt;
* Most characters only flank 60 degrees in each direction, combat movement allows an increase to 90 degrees (the full back 180).&lt;br /&gt;
* Only rogues get the full flanking bonus, everyone else still gets half.&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_GetFlankingBonus|Combat_GetFlankingBonus]] in [[combat_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Determination =====&lt;br /&gt;
&lt;br /&gt;
* Backstab is determined for each melee attack only.&lt;br /&gt;
* Backstab requires the attacker to have a flanking bonus &amp;gt; 0 (some talents waive this restriction)&lt;br /&gt;
* Only creatures with the Rogue [[Classes|Character Class]] may backstab. This is a class benefit.&lt;br /&gt;
* Only humanoid attackers can backstab (this includes darkspawn)&lt;br /&gt;
* The full logic is implemented in the function [[combat_h.nss#Combat_CheckBackstab|Combat_CheckBackstab]] in [[combat_h.nss]].&lt;br /&gt;
* The damage logic is implemented in [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Determination =====&lt;br /&gt;
&lt;br /&gt;
* Critical Hit Chance uses the attackers Melee or Ranged critical hit modifier based on attack type.&lt;br /&gt;
* + the attacking weapon's critical hit modifier stat.&lt;br /&gt;
* + 1.20x (1.1x for non rogues) the attacker's [[#Flanking Bonus Determination|Flanking Bonus]] in the current situation.&lt;br /&gt;
* + 3.5 for each enemy past the 2nd that is fighting a warriors with the bravery talent.&lt;br /&gt;
* A critical hit occurs when the resulting CriticalHitChance is smaller than RandomFloat()*100.0f.&lt;br /&gt;
* Certain effects and spells (e.g. Death Hex) can always override the result, as will attacking from stealth (always hits critical).&lt;br /&gt;
* The logic is  implemented in the function [[combat_h.nss#Combat_GetAttackResult|Combat_GetAttackResult]] in the script library [[combat_h.nss]]&lt;br /&gt;
&lt;br /&gt;
==== Damage Resolution ====&lt;br /&gt;
&lt;br /&gt;
Damage resolution logic is implemented in the script [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
===== Critical Hit Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Critical hits increase the amount of damage done by an attack by a fixed multiplier.&lt;br /&gt;
* The magnitude of the multiplier can be affected by items and effects, but is not affected by of the character's attributes.&lt;br /&gt;
* Historical Note: Critical damage used to be variable 'up to...', but was changed to constant to provide a more predictable flow of damage.&lt;br /&gt;
* The logic for critical damage is implemented in [[combat_damage_h.nss#GetCriticalDamageModifier]].&lt;br /&gt;
&lt;br /&gt;
===== Backstab Damage Modification =====&lt;br /&gt;
&lt;br /&gt;
* Backstab damage is essentially identical to critical damage, but modified by certain rogue talents.&lt;br /&gt;
* The full logic is implemented [[combat_damage_h.nss#Combat_Damage_GetBackstabDamage|Combat_Damage_GetBackstabDamage]] in [[combat_damage_h.nss]].&lt;br /&gt;
&lt;br /&gt;
[[Category: Scripts]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Creature_Properties&amp;diff=7346</id>
		<title>Creature Properties</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Creature_Properties&amp;diff=7346"/>
				<updated>2009-10-30T22:35:45Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Property Definitions */ grammar&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=== Overview ===&lt;br /&gt;
&lt;br /&gt;
The creature property system is the heart of the rules engine and defines all the numerical values that make up a character in Dragon Age.&lt;br /&gt;
&lt;br /&gt;
=== Detailed Description ===&lt;br /&gt;
&lt;br /&gt;
Properties are 32-bit floating point values associated with every combat capable creature in the game (Creature Type field in the toolset). They are used by engine, scripting and UI to make up and display the RPG ruleset of the game.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Property Types ====&lt;br /&gt;
&lt;br /&gt;
There are 3 types of properties that abstract the most common types of statistics found in an RPG:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== PROPERTY_TYPE_SIMPLE =====&lt;br /&gt;
&lt;br /&gt;
Simple properties are 32 bit floats that can hold a single value and that generally are not modified or influenced by other properties. Examples include Experience, Level or the number of unspent talent points a character has.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== PROPERTY_TYPE_ATTRIBUTE =====&lt;br /&gt;
&lt;br /&gt;
[[Attribute]]s are a moderately complex set of values encapsulating a single character stat. They have three fields that are independently tracked in the engine and are accessible from scripting: &lt;br /&gt;
&lt;br /&gt;
* Base - A character's unmodified base value, usually only modified during level up and character creation. This number is displayed as a white number the character sheet.&lt;br /&gt;
&lt;br /&gt;
* Modifier - A float32 that holds the sum of all effect based modifications to the property. This number is shown as a red (if negative) or green (if positive) number on the character sheet.&lt;br /&gt;
&lt;br /&gt;
* Total - The sum of the base and modifier fields along with any in engine modifications done to the property in C++ (for speed reasons) as defined by the engine link field. When reading this field, the engine will always clamp the return values between Min and Max, even through it stores the full, unmodified number internally.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5fffa; border:1px solid #a3bfb1; text-align:left; color:#000; padding:0.2em 0.4em; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Example:'''&lt;br /&gt;
A level 1 warrior with 15 strength, a buff that grants +2 strength and a shield that has a +1 strength enhancement would be stored as as:&lt;br /&gt;
* Base: 15&lt;br /&gt;
* Modifiers: 3&lt;br /&gt;
* Total 18&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
===== PROPERTY_TYPE_DEPLETABLE =====&lt;br /&gt;
Depletables represent the most complex type of stats usually found in an RPG, used for Health and Mana. In addition to all fields present on an Attribute, they have an additional 'Current' field. &lt;br /&gt;
&lt;br /&gt;
* Current - This is the character's current value in this stat, which can be between Min and Max and can exceed Total. &lt;br /&gt;
&lt;br /&gt;
Additionally, just like attributes, the EngineLink field defines some hardcoded behavior in the engine such as creating the link between the 'rengeration rate' properties.&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5fffa; border:1px solid #a3bfb1; text-align:left; color:#000; padding:0.2em 0.4em; height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|'''Example:'''&lt;br /&gt;
A level 1 warrior with 14 Con and 100 base health and a +5 health ring would store health who was at full health before getting hit for 20 points of damage:&lt;br /&gt;
* Base: 100&lt;br /&gt;
* Modifiers: +5&lt;br /&gt;
* Hidden Engine Modifiers: +20 (5 points for each point in CON after 10). &lt;br /&gt;
* Total: 125&lt;br /&gt;
* Current: 105&lt;br /&gt;
&lt;br /&gt;
Hidden Engine modifiers can not be modified (obviously, they're in C++), but can be disabled by setting the EngineLink field to 0. They exist purely to speed up stats accessed with high frequency (DAScript has a 7-15x overhead per instruction compared to native code).&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Property Definitions ====&lt;br /&gt;
&lt;br /&gt;
The two dimensional data array defined in [[Properties.xls]] defines numerical values that exist on every creature in the game. All properties are float32 and all rules logic of the game is based on floating point math. This dynamic data driven approach to rules relevant stats is new to Dragon Age: Origins and makes the engine extremely flexible for Designers. It enables the game to have a rules logic that is almost completely softcoded in script and data.&lt;br /&gt;
&lt;br /&gt;
The following is an excerpt from the 2da that lists all rows present in the initial ship version of Dragon Age: Origins but only shows the most important columns. Note that DLC or expansion content may be overriding individual lines in the 2da.&lt;br /&gt;
&lt;br /&gt;
{| valign=&amp;quot;top&amp;quot; border=&amp;quot;1&amp;quot; width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|-| &lt;br /&gt;
| '''ID''' || '''Stat''' || '''Type''' || '''Min''' || '''Max''' || '''Comment'''&lt;br /&gt;
|-|&lt;br /&gt;
|  ''int'' || ''string'' || ''string'' || ''float'' || ''float'' || ''comment''&lt;br /&gt;
|-|&lt;br /&gt;
|  0 || INVALID || INVALID || 0 || 0 || &lt;br /&gt;
|-|&lt;br /&gt;
|  1 || Strength || ATTRIBUTE || 0 || 1000 || STR [[Attribute]]&lt;br /&gt;
|-|&lt;br /&gt;
|  2 || Dexterity || ATTRIBUTE || 0 || 1000 || DEX [[Attribute]]&lt;br /&gt;
|-|&lt;br /&gt;
|  3 || Willpower || ATTRIBUTE || 0 || 1000 || WIL [[Attribute]]&lt;br /&gt;
|-|&lt;br /&gt;
|  4 || Magic || ATTRIBUTE || 0 || 1000 || MAG [[Attribute]]&lt;br /&gt;
|-|&lt;br /&gt;
|  5 || Cunning || ATTRIBUTE || 0 || 1000 || CUN [[Attribute]]&lt;br /&gt;
|-|&lt;br /&gt;
|  6 || Constitution || ATTRIBUTE || 0 || 1000 || CON [[Attribute]]&lt;br /&gt;
|-|&lt;br /&gt;
|  7 || Health || DEPLETABLE || 1 || 9999 || Hit Points&lt;br /&gt;
|-|&lt;br /&gt;
|  8 || Mana_Stamina || DEPLETABLE || 0 || 9999 || Mana or Stamina, based on class&lt;br /&gt;
|-|&lt;br /&gt;
|  9 || Attack || ATTRIBUTE || 0 || 1000 || Attack Power&lt;br /&gt;
|-|&lt;br /&gt;
|  10 || Defense || ATTRIBUTE || 0 || 1000 || Defense&lt;br /&gt;
|-|&lt;br /&gt;
|  11 || Armor || ATTRIBUTE || 0 || 1000 || Armor Mitigation Potential&lt;br /&gt;
|-|&lt;br /&gt;
|  12 || DamageScale || ATTRIBUTE || 1 || 10 || Based Damage Scaling (for difficulty settings and ranks)&lt;br /&gt;
|-|&lt;br /&gt;
|  13 || SpellPower || ATTRIBUTE || 0 || 1000 || Spellpower (Max(MAG-10,0)+Effects)&lt;br /&gt;
|-|&lt;br /&gt;
|  14 || Regeneration_Health || ATTRIBUTE || 0 || 50 || Health Regeneration Rate (Explore Mode) per tick.&lt;br /&gt;
|-|&lt;br /&gt;
|  15 || Level || SIMPLE || 0 || 99 || Current Character Level. &lt;br /&gt;
|-|&lt;br /&gt;
|  16 || Displacement || ATTRIBUTE || 0 || 100 ||  Chance to outright evade any physical attach attempt (aka Dodge)&lt;br /&gt;
|-|&lt;br /&gt;
|  17 || Inventory_Size || SIMPLE || 0 || 1000 || Inventory Slot size (on party)&lt;br /&gt;
|-|&lt;br /&gt;
|  18 || AI_BEHAVIOR || SIMPLE || 0 || 1000 || Selected AI Behavior &lt;br /&gt;
|-|&lt;br /&gt;
|  19 || Experience || SIMPLE || 0 || 186001 || Experience Points&lt;br /&gt;
|-|&lt;br /&gt;
|  20 || Flanking_Angle || ATTRIBUTE || 0 || 180 || The angle at which this creature is able to flank an enemy (default is 90)&lt;br /&gt;
|-|&lt;br /&gt;
|  21 || Melee_Crit_Modifier || ATTRIBUTE || -100 || 200 || The +melee crit modifier&lt;br /&gt;
|-|&lt;br /&gt;
|  22 || Missile_Shield || ATTRIBUTE || 0 || 100 || Chance to avoid missiles (shields and some spells increase this)&lt;br /&gt;
|-|&lt;br /&gt;
|  23 || Ranged_Crit_Modifier || ATTRIBUTE || -100 || 200 || The +ranged crit modifier&lt;br /&gt;
|-|&lt;br /&gt;
|  24 || Ranged_Aim_Speed || ATTRIBUTE || -3 || 6 || The character's speed bonus or penality when aiming with ranged weapons&lt;br /&gt;
|-|&lt;br /&gt;
|  25 || BaseAttackRating || SIMPLE || 0 || 1000 || The creature's cached base attack rating&lt;br /&gt;
|-|&lt;br /&gt;
|  26 || BaseDefenseRating || SIMPLE || 0 || 1000 || The creature's cached base defense rating&lt;br /&gt;
|-|&lt;br /&gt;
|  27 || CurrentClass || SIMPLE || 0 || 31 || The creature class (index into cla_base.xls)&lt;br /&gt;
|-|&lt;br /&gt;
|  28 || Regeneration_Health_Combat || ATTRIBUTE || 0 || 20 || The creature's health regeneration rate (per tick) in combat.&lt;br /&gt;
|-|&lt;br /&gt;
|  29 || Regeneration_Stamina || ATTRIBUTE || -20 || 50 || The creature's stamina regeneration rate (per tick) in explore mode.&lt;br /&gt;
|-|&lt;br /&gt;
|  30 || Regeneration_Stamina_Combat || ATTRIBUTE || -20 || 20 || The creature's stamina regeneration rate (per tick) in combat mode.&lt;br /&gt;
|-|&lt;br /&gt;
|  31 || AttackSpeedModifier || ATTRIBUTE || 0 || 1.5 || The creature's universal melee attack speed modifiers (used by haste, momentum, etc.)&lt;br /&gt;
|-|&lt;br /&gt;
|  32 || Resistance_Mind || ATTRIBUTE || -100 || 100 || Mental Resistance.&lt;br /&gt;
|-|&lt;br /&gt;
|  33 || Resistance_Physical || ATTRIBUTE || -100 || 100 || Physical Resistance.&lt;br /&gt;
|-|&lt;br /&gt;
|  34 || Attribute_points || SIMPLE || 0 || 100 || Holds any unspent attribute points the creature has. If this is != 0, the UI shows the levelup button.&lt;br /&gt;
|-|&lt;br /&gt;
|  35 || Skill_points || SIMPLE || 0 || 100 || Holds any unspent skill points the creature has. If this is != 0, the UI shows the levelup button.&lt;br /&gt;
|-|&lt;br /&gt;
|  36 || talent_spell_points || SIMPLE || 0 || 100 ||Holds any unspent talent points the creature has. If this is != 0, the UI shows the levelup button.&lt;br /&gt;
|-|&lt;br /&gt;
|  37 || Background || SIMPLE || 0 || 10 || The character's origin (index into backgrounds.xls).&lt;br /&gt;
|-|&lt;br /&gt;
|  38 || specialization_points || SIMPLE || 0 || 2 || Holds any unspent specialization points the creature has. &lt;br /&gt;
|-|&lt;br /&gt;
|  39 || DamageBonus || ATTRIBUTE || -100 || 100 || Universal physical attack damage bonus on the creature.&lt;br /&gt;
|-|&lt;br /&gt;
|  40 || Threat_Decrease_Rate || SIMPLE || -1000 || 1000 || The rate at which the creature's threat rating decays.&lt;br /&gt;
|-|&lt;br /&gt;
|  41 || Fatique || ATTRIBUTE || -25 || 250 || The creature's current [[Fatigue]] (% increase of ability cost).&lt;br /&gt;
|-|&lt;br /&gt;
|  42 || Damage_Resistance_Fire || ATTRIBUTE || -100 || 75 || The creature's damage resistance to fire. All fire damage is reduce by %.&lt;br /&gt;
|-|&lt;br /&gt;
|  43 || Damage_Resistance_Cold || ATTRIBUTE || -100 || 75 || The creature's damage resistance to cold. All cold damage is reduce by %.&lt;br /&gt;
|-|&lt;br /&gt;
|  44 || Damage_Resistance_Electricity || ATTRIBUTE || -100 || 75 || The creature's damage resistance to lightning. All lightning damage is reduce by %.&lt;br /&gt;
|-|&lt;br /&gt;
|  45 || Damage_Resistance_Nature || ATTRIBUTE || -100 || 75|| The creature's damage resistance to nature. All nature damage is reduce by %.&lt;br /&gt;
|-|&lt;br /&gt;
|  46 || Damage_Resistance_Spirit || ATTRIBUTE || -100 || 75 || The creature's damage resistance to spirit. All spirit damage is reduce by %.&lt;br /&gt;
|-|&lt;br /&gt;
|  47 || Damage_Shield_points || ATTRIBUTE || 0 || 9999 || Magical, damage mitigating shield (all damage types) on the creature. Creature immune to damage until the shield is depleted.&lt;br /&gt;
|-|&lt;br /&gt;
|  48 || Damage_Shield_strength || ATTRIBUTE || 0 || 100 || The maximum amount of damage the creature's magical shields can absorb (not used yet.)&lt;br /&gt;
|-|&lt;br /&gt;
|  49 || Damage_OffHand || ATTRIBUTE || 0 || 9999 || Display only cache of creature's weapon damage potential. This value is only used to marshal data into the UI, it does not have any rules implications.&lt;br /&gt;
|-|&lt;br /&gt;
|  50 || Damage_MainHand || ATTRIBUTE || 0 || 9999  || Display only cache of creature's weapon damage potential. This value is only used to marshal data into the UI, it does not have any rules implications.&lt;br /&gt;
|-|&lt;br /&gt;
|  51 || Healing_Effect_Factor || ATTRIBUTE || 100 || 200 || Percentage modifier of how effective healing is on the creature. Blood magic does NOT use this field, it is coded in effect_heal_h instead.&lt;br /&gt;
|-|&lt;br /&gt;
|  52 || Spell_resistance || ATTRIBUTE || 0 || 100 || Creature 'hostile magic resistance'. % Chance to avoid any hostile magic.&lt;br /&gt;
|-|&lt;br /&gt;
|  53 || AP_BONUS || ATTRIBUTE || -100 || 100 || Armor Penetration bonuses  are stored her.&lt;br /&gt;
|-|&lt;br /&gt;
|  54 || CriticalRange || ATTRIBUTE || 0 || 200 || The 'range' which critical hits use. 150 would mean up to 150% of normal damage.&lt;br /&gt;
|-|&lt;br /&gt;
|  55 || Fire_Damage_Bonus || ATTRIBUTE || 0 || 30 || Percentage bonus to all fire damage dealt by the user (spells, staves, etc.)&lt;br /&gt;
|-|&lt;br /&gt;
|  56 || Spirit_Damage_Bonus || ATTRIBUTE || 0 || 30 || Percentage bonus to all spirit damage dealt by the user (spells, staves, etc.)&lt;br /&gt;
|-|&lt;br /&gt;
|  57 || Cold_Damage_Bonus || ATTRIBUTE || 0 || 30 || Percentage bonus to all cold damage dealt by the user (spells, staves, etc.)&lt;br /&gt;
|-|&lt;br /&gt;
|  58 || Nature_Damage_Bonus || ATTRIBUTE || 0 || 30 || Percentage bonus to all nature damage dealt by the user (spells, staves, etc.)&lt;br /&gt;
|-|&lt;br /&gt;
|  59 || Electricity_Damage_Bonus || ATTRIBUTE || 0 || 30 || Percentage bonus to all lightning damage dealt by the user (spells, staves, etc.)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin:0; background:#f5fffa; border:1px solid #a3bfb1; text-align:left; color:#000; padding:0.2em 0.4em; width:100%;  height:100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;|&lt;br /&gt;
&amp;lt;h2 style=&amp;quot;margin:0; background:red; font-size:150%; font-weight:bold; border:1px solid #a3bfb1; text-align:left; color:#fff; padding:0.2em 0.4em;&amp;quot;&amp;gt;Words of Caution&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Properties.xls is the most integral and powerful 2da in the game. Any changes to it have profound implications on the game and the chance of breaking existing savegames and introducing unwanted behavior.&lt;br /&gt;
&lt;br /&gt;
'''Removing Rows'''&lt;br /&gt;
It is referenced from many other rules and UI related 2das and removing existing data can have severe consequences, including the invalidation of existing characters. You can NEVER remove rows from this 2da!&lt;br /&gt;
&lt;br /&gt;
'''Changing Rows'''&lt;br /&gt;
Changing rows is not as dangerous as removing them, but still can have severe implications. The m2da system should be utilized to modify individual rows instead of overwriting the entire 2da. Especially the Min, Max and EngineLink columns hold a lot of rules relevant data that might not be obvious on the first glance (e.g. the Max value on 'Experience' defines the maximum XP the game will allow on a character. Any attempt to award more XP from script will silently fail.)&lt;br /&gt;
&lt;br /&gt;
'''Adding rows''':&lt;br /&gt;
Every row added to this file will reserve several Float32 data fields on every combat capable creature in the game. While a few floats might not sound like a lot, the impact on runtime area memory, savegame size and associated load times can not be overstated. While these issues are more pressing for the console versions of the game, they still do affect the PC version and I strongly advise not to add to this file unless absolutely necessary.&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Q&amp;amp;A ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Q: Why use Floats instead of integers? ===&lt;br /&gt;
&lt;br /&gt;
We had initially investigated a structure that would allow creation of typed properties but found the associated overhead and complexity in such a frequently accessed system to be too high to be worth it.&lt;br /&gt;
&lt;br /&gt;
Since much of our system requires floating point values and floats can be easily rounded for display purposes, we decided to use floating point across the board.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Q: Won't floating point math lead to imprecision? ===&lt;br /&gt;
&lt;br /&gt;
Yes, it can. Certain mathematical operations promote imprecision in floating point values. DA script, like NWScript is only precise for a limited number of digits and any existing imprecision can be magnified by consecutive divisions and other operations.&lt;br /&gt;
&lt;br /&gt;
However, there are mitigating circumstances that make this much less of a problem than it might appear on paper (or fresh from university :)&lt;br /&gt;
&lt;br /&gt;
* Most frequent calculations retrieve an existing floating point value cached in a property, run a bunch of calculations and then execute the result (e.g. calculating damage). The resulting values are rarely stored so imprecision has little opportunity to build up over time.&lt;br /&gt;
&lt;br /&gt;
* When writing to values that are displayed as integers on the UI or used as integers in the combat math, we are casting back to integer before storing or computation (e.g. to avoid health from going into the gray realm between 0 and 1).&lt;br /&gt;
&lt;br /&gt;
* Some engine commands have added security to prevent rounding errors from propagating from script into engine stored values.&lt;br /&gt;
&lt;br /&gt;
* If you happen to do .004 points damage more during an attack, the gameplay impact is virtually zero, so even if imprecision manages to propagate up to the 3rd decimal, it is still not visible in the game.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Q: Is there anything absolutely hardcoded? ===&lt;br /&gt;
&lt;br /&gt;
Yes. While nearly all C++ implemented aspects of the rules system can be turned off by removing the associated EngineLink from properties.xls, a few behaviors are not easy to modify or replace by script:&lt;br /&gt;
&lt;br /&gt;
* Regeneration. While it is technically possible to turn off regeneration by setting all rates to 0, the system can not be modified. One would have to replace it with a scripted, heartbeat like construct to make changes. The reason for this is simple: Regeneration ticks at a high frequency on all combat capable creatures and the cpu time consumed by running this entirely in script is completely unacceptable.&lt;br /&gt;
&lt;br /&gt;
* Some UI rules are currently hardcoded and although it is possible to control some of the UI through various 2das, replacing the entire UI with a new framework is impossible at this point.&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Sound&amp;diff=7330</id>
		<title>Sound</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Sound&amp;diff=7330"/>
				<updated>2009-10-29T01:12:09Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* The object inspector */ spelling&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Sounds are created and packaged using the [[FMOD]] tool. This is a third-party tool that is included with the Dragon Age toolset. See the [[FMOD]] page for documentation on how to use it to create sound resources for use in the designer toolkit.&lt;br /&gt;
&lt;br /&gt;
The designer toolset is our way to get sounds into the game. In this application we can define the sound design for any particular area in the game. We have the ability to draw audio volumes to define certain areas, assign sounds to them and even modify and mix within the volume itself, in real time. We can drop emitters for our 3D sounds and modify them as well.&lt;br /&gt;
&lt;br /&gt;
Voice over is handled separately by the toolset; see the relevant section of [[conversation]] for more details.&lt;br /&gt;
&lt;br /&gt;
==  Sounds in the area editor ==&lt;br /&gt;
&lt;br /&gt;
Any sound that you create events for and build to the .fev/.fsb files is available for use in the [[area]] editor. The area editor will see these sounds and make them available when the editor is opened or when the “Refresh F5” option is selected from the menu. This way you can keep the editor open, go back to FMOD, edit, rebuild and then see your changes in the area editor.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m696ff502.png|frame|center|The refresh command in “View”]]&lt;br /&gt;
&lt;br /&gt;
=== Where are they and how to get them ===&lt;br /&gt;
&lt;br /&gt;
Sounds in the area editor are available in two places:&lt;br /&gt;
&lt;br /&gt;
Sounds available to be used as 3D placeable emitters and 3D area effects can be accessed from the palette window under “Sounds”, located by the double eighth note icon.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m4737e97a.png|frame|center|“Sounds” in the palette window.]]&lt;br /&gt;
&lt;br /&gt;
Although all sounds in the FMOD project will be available here, we will only select the sounds used as emitters from this window. Sounds that we will assign to volumes will be accessed in another way.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m76633bf9.png|frame|center|Sounds used as emitters.]]&lt;br /&gt;
&lt;br /&gt;
All of these sounds will be visible as they are in the event groups we have created in FMOD.&lt;br /&gt;
&lt;br /&gt;
Sounds that we will assign to audio volumes are available in the object inspector window. When you click on an audio volume, the object inspector for that audio volume will come up allowing you to select sounds and assign them to the volume.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_3358dde5.png|frame|center|The audio volume selected in the area editor.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m239c4e80.png|frame|center|The object inspector for the audio volume.]]&lt;br /&gt;
&lt;br /&gt;
In the object inspector we can name the audio volume, select a reverb for the volume and assign sounds to the volume.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_258f7e.png|frame|center|Name the volume.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_2fd0e616.png|frame|center|Set the reverb preset.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_250eeee5.png|frame|center|Assign sounds to the volume.]]&lt;br /&gt;
&lt;br /&gt;
To assign sounds to the volume, click on the “&amp;lt;B&amp;gt;…&amp;lt;/B&amp;gt;” tab on the far right of the “Sounds” field. You will see a window called “Sound Instances” pop-up that will allow you to access sounds and assign them to the volume.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m14f66b49.png]]&lt;br /&gt;
&lt;br /&gt;
Selecting the sound(s) you want to assign to the volume and clicking the “Add - &amp;gt;” button will transfer the sounds over to the next window.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m7bd884d5.png]]&lt;br /&gt;
&lt;br /&gt;
Likewise, the “Remove” or “Remove all” buttons will do just that, remove selected sounds or clear all sounds from the window.&lt;br /&gt;
&lt;br /&gt;
When the sounds are in the window, you can audition them singly or all together and even edit their mix and other properties.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m6bde288.png|frame|center|Sounds selected for audition or edit.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_4dd5f697.png|frame|center|The object inspector for the sounds assigned to a volume.]]&lt;br /&gt;
&lt;br /&gt;
Once selected and assigned to a volume, these sounds will now play in game in the area defined by the volume, based on their individual playback parameters.&lt;br /&gt;
&lt;br /&gt;
== The object inspector ==&lt;br /&gt;
&lt;br /&gt;
The object inspector is a facility offered by the DA designer toolset with which to perform several processes to the sounds we have applied to any given level. We have the ability to modify the audio events that we have created as well as modify other parameters such as the active/inactive status of an emitter, adjust the position of an object, change the 3D cone of an emitter, as well as adjust the max range of the radius of an emitter. These modifiers are also supported by the ability to adjust the occludability, pitch, priority and volume of any given object. These functions will be explained in two ways: 1. how the object inspector allows modification to an audio volume and: 2. how the object inspector allows modification to an emitter.&lt;br /&gt;
&lt;br /&gt;
=== Use and utility ===&lt;br /&gt;
&lt;br /&gt;
==== The object inspector and audio volumes ====&lt;br /&gt;
&lt;br /&gt;
When you select an audio volume in the area editor, the object inspector shows several fields that will allow us to perform several actions directly related to that audio volume. These fields are:&lt;br /&gt;
&lt;br /&gt;
1. Name- here we can name the volume, usually calling it what it is on the map or some name that describes its function is a good way to name these objects. For example: “Hallway 1, or Tower Courtyard Lower 1”. Note that there are numbers at the end of the name, you may have volumes that are the same name but are used multiple times, e.g. Alcove 1, 2, 3, 4… and so on, etc. Using a number after each volume, even if it is the only one on the map is an easy way to keep track of what and where things are.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_20762b04.png]]&lt;br /&gt;
&lt;br /&gt;
2. Reverb Preset- in this field we can assign a reverb to the volume. Any reverb preset that is in the master_reverb FMOD project is available to use in your volumes.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_2d41b5bb.png]]&lt;br /&gt;
&lt;br /&gt;
3. Sounds- sounds can be assigned to audio volumes in this field. When you click to the right of the sounds field a menu called “Sound Instances” will open and you will be able to select sound events from the FMOD project for the level you are working on and assign them to the volume.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m4927b95a.png]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m6325a6cf.png|frame|center|Sounds assigned to a volume.]]&lt;br /&gt;
&lt;br /&gt;
4. Position- this field describes the position of the volume on the map, with values representing points in 3D space including height, which is the last value.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m70cedfbe.png|frame|center|The height of the volume, in meters.]]&lt;br /&gt;
&lt;br /&gt;
All of the numerical values relating to position are copy/pasteable from one object inspector to the other, which is useful when copying a volume from one map to another, for reuse.&lt;br /&gt;
&lt;br /&gt;
5. Sound Instances- this window allows us to select and assign sound events to audio volumes, in addition, we can also perform some editing functions per sound event. When selecting a sound in the “Sound Instances” window the editing functions open up, as below:&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m467394a0.png|frame|center|Sound instance object inspector.]]&lt;br /&gt;
&lt;br /&gt;
These functions enable greater control over each sound event assigned to the volume and we can effectively mix these sounds within each volume, as well as script instances within a volume.&lt;br /&gt;
&lt;br /&gt;
==== The object inspector and emitters ====&lt;br /&gt;
&lt;br /&gt;
When you select an emitter in the area editor, the object inspector shows several fields that will allow us to perform several actions directly related to that emitter. These fields are identical to the “Sound Instances” object inspector functions discussed in the previous entry.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m143509d9.png|frame|center|The emitter object inspector.]]&lt;br /&gt;
&lt;br /&gt;
Within this window we have the ability to modify other parameters such as the active/inactive status of an emitter, adjust the position of the emitter, change the 3D cone of the emitter, as well as adjust the max range of the radius of an emitter, volume, pitch and priority. All of these values can be copied and pasted as well as manipulated instance to instance.&lt;br /&gt;
&lt;br /&gt;
== Volumes and emitters. ==&lt;br /&gt;
&lt;br /&gt;
We can use volumes for two purposes when designing the sound for an area in DA. The first is to use an audio volume to define an area in which you want to play certain sounds as 4.0 ambiences. For example: the borders of a town, or the path of a river, a room in a castle or an outdoor area. All of these instances can use volumes to define the ambient audio we will here when we are in that space in the game. Audio volumes are used in conjunction with emitters to fulfill the 4.0 and 3D directional aspects of all sounds used as ambiences in the game.&lt;br /&gt;
&lt;br /&gt;
=== Audio volumes ===&lt;br /&gt;
&lt;br /&gt;
Audio volumes are used to define an area for 4.0 ambiences to be assigned to. In the area editor, simply right clicking anywhere in the map will allow you to begin to draw an audio volume, as shown below..&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m6f0fdea3.png|frame|center|Right click on the map.]]&lt;br /&gt;
&lt;br /&gt;
You will then see a crosshairs with which you can point and click to draw virtually any complex shape necessary to define the area you need. You draw these shapes by dropping vertices which then can be moved as a group or independently, in 3 dimensions.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m7bf496c3.png|frame|center|Draw the shape desired.]]&lt;br /&gt;
&lt;br /&gt;
As stated we use these volumes and the shapes we draw to define the 4.0 audio for any given area. These volumes show up in the menu on the right hand side of the area editor. It is here that you can select them to edit their properties and parameters in the object inspector.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_69cbabfe.png|frame|center|Placed audio volumes in the menu.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m5099ccff.png|frame|center|Portion of map defined by volumes.]]&lt;br /&gt;
&lt;br /&gt;
=== Reverb volumes ===&lt;br /&gt;
&lt;br /&gt;
Reverb volumes share may of the same properties as audio volumes except they are designed to define an area for a certain reverb. Since we can assign reverbs to audio volumes, the reverb volumes are usually used to draw small volumes to place emitters in order for them to be in a separate reverb from the rest of the area. We can currently have 3 reverbs per area.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m44f5abfb.png|frame|center|Reverb volume with emitters placed inside. ]]&lt;br /&gt;
&lt;br /&gt;
These volumes show up in the menu on the right hand side of the area editor. It is here that you can select them to edit their properties and parameters in the object inspector.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m4fa514c0.png|frame|center|Placed reverb volumes in the menu.]]&lt;br /&gt;
&lt;br /&gt;
=== Emitter properties and utility. ===&lt;br /&gt;
&lt;br /&gt;
Emitters are used in the area editor to perform several functions, they can be placed to provide the sound for a 3D placeable object, like a fire, flag or waterfall:&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m487b9558.png|frame|center|Emitter placed as a 3D placeable object.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_4084754f.png|thumb|center|600px|The FMOD event for this instance.]]&lt;br /&gt;
&lt;br /&gt;
They can be used to define a 3D area effect over an entire area of the map:&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_484de945.png|frame|center|Emitter providing a 3D area effect.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_60d10943.png|thumb|center|600px|The FMOD event for this instance.]]&lt;br /&gt;
&lt;br /&gt;
And finally, they can be used as point source 3D ambience over a selected area of the map.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m7d17ec99.png|frame|center|Emitter used as point source ambience.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m6daf1077.png|thumb|600px|center|The FMOD event for this instance.]]&lt;br /&gt;
&lt;br /&gt;
To place an emitter, the sounds can be accessed in the “Sounds” palette window to the right of the area editor.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m4737e97a.png|frame|center|“Sounds” selected in the palette window.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_7fa321e0.png|frame|center|Selecting a sound.]]&lt;br /&gt;
&lt;br /&gt;
Upon selection of a sound, you will be given a crosshair and you can drop the sound anywhere on the map. You can then adjust its position in 3 dimensions as you see fit.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_bdda402.png|frame|center|Placed sounds in the menu.]]&lt;br /&gt;
&lt;br /&gt;
Sounds used as emitters show up in the menu on the right hand side of the area editor. It is here that you can select them to edit their properties and parameters in the object inspector.&lt;br /&gt;
&lt;br /&gt;
[[Category:Sounds]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Sound&amp;diff=7329</id>
		<title>Sound</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Sound&amp;diff=7329"/>
				<updated>2009-10-29T01:05:55Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Where are they and how to get them */ speeling&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Sounds are created and packaged using the [[FMOD]] tool. This is a third-party tool that is included with the Dragon Age toolset. See the [[FMOD]] page for documentation on how to use it to create sound resources for use in the designer toolkit.&lt;br /&gt;
&lt;br /&gt;
The designer toolset is our way to get sounds into the game. In this application we can define the sound design for any particular area in the game. We have the ability to draw audio volumes to define certain areas, assign sounds to them and even modify and mix within the volume itself, in real time. We can drop emitters for our 3D sounds and modify them as well.&lt;br /&gt;
&lt;br /&gt;
Voice over is handled separately by the toolset; see the relevant section of [[conversation]] for more details.&lt;br /&gt;
&lt;br /&gt;
==  Sounds in the area editor ==&lt;br /&gt;
&lt;br /&gt;
Any sound that you create events for and build to the .fev/.fsb files is available for use in the [[area]] editor. The area editor will see these sounds and make them available when the editor is opened or when the “Refresh F5” option is selected from the menu. This way you can keep the editor open, go back to FMOD, edit, rebuild and then see your changes in the area editor.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m696ff502.png|frame|center|The refresh command in “View”]]&lt;br /&gt;
&lt;br /&gt;
=== Where are they and how to get them ===&lt;br /&gt;
&lt;br /&gt;
Sounds in the area editor are available in two places:&lt;br /&gt;
&lt;br /&gt;
Sounds available to be used as 3D placeable emitters and 3D area effects can be accessed from the palette window under “Sounds”, located by the double eighth note icon.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m4737e97a.png|frame|center|“Sounds” in the palette window.]]&lt;br /&gt;
&lt;br /&gt;
Although all sounds in the FMOD project will be available here, we will only select the sounds used as emitters from this window. Sounds that we will assign to volumes will be accessed in another way.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m76633bf9.png|frame|center|Sounds used as emitters.]]&lt;br /&gt;
&lt;br /&gt;
All of these sounds will be visible as they are in the event groups we have created in FMOD.&lt;br /&gt;
&lt;br /&gt;
Sounds that we will assign to audio volumes are available in the object inspector window. When you click on an audio volume, the object inspector for that audio volume will come up allowing you to select sounds and assign them to the volume.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_3358dde5.png|frame|center|The audio volume selected in the area editor.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m239c4e80.png|frame|center|The object inspector for the audio volume.]]&lt;br /&gt;
&lt;br /&gt;
In the object inspector we can name the audio volume, select a reverb for the volume and assign sounds to the volume.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_258f7e.png|frame|center|Name the volume.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_2fd0e616.png|frame|center|Set the reverb preset.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_250eeee5.png|frame|center|Assign sounds to the volume.]]&lt;br /&gt;
&lt;br /&gt;
To assign sounds to the volume, click on the “&amp;lt;B&amp;gt;…&amp;lt;/B&amp;gt;” tab on the far right of the “Sounds” field. You will see a window called “Sound Instances” pop-up that will allow you to access sounds and assign them to the volume.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m14f66b49.png]]&lt;br /&gt;
&lt;br /&gt;
Selecting the sound(s) you want to assign to the volume and clicking the “Add - &amp;gt;” button will transfer the sounds over to the next window.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m7bd884d5.png]]&lt;br /&gt;
&lt;br /&gt;
Likewise, the “Remove” or “Remove all” buttons will do just that, remove selected sounds or clear all sounds from the window.&lt;br /&gt;
&lt;br /&gt;
When the sounds are in the window, you can audition them singly or all together and even edit their mix and other properties.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m6bde288.png|frame|center|Sounds selected for audition or edit.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_4dd5f697.png|frame|center|The object inspector for the sounds assigned to a volume.]]&lt;br /&gt;
&lt;br /&gt;
Once selected and assigned to a volume, these sounds will now play in game in the area defined by the volume, based on their individual playback parameters.&lt;br /&gt;
&lt;br /&gt;
== The object inspector ==&lt;br /&gt;
&lt;br /&gt;
The object inspector is a facility offered by the DA designer toolset with which to perform several processes to the sounds we have applied to any given level. We have the ability to modify the audio events that we have created as well as modify other parameters such as the active/inactive status of an emitter, adjust the position of an object, change the 3D cone of an emitter, as well as adjust the max range of the radius of an emitter. These modifiers are also supported by the ability to adjust the occludability, pitch, priority and volume of any given object. These functions will be explain in two ways: 1. how the object inspector allows modification to an audio volume and: 2. how the object inspector allows modification to an emitter.&lt;br /&gt;
&lt;br /&gt;
=== Use and utility ===&lt;br /&gt;
&lt;br /&gt;
==== The object inspector and audio volumes ====&lt;br /&gt;
&lt;br /&gt;
When you select an audio volume in the area editor, the object inspector shows several fields that will allow us to perform several actions directly related to that audio volume. These fields are:&lt;br /&gt;
&lt;br /&gt;
1. Name- here we can name the volume, usually calling it what it is on the map or some name that describes its function is a good way to name these objects. For example: “Hallway 1, or Tower Courtyard Lower 1”. Note that there are numbers at the end of the name, you may have volumes that are the same name but are used multiple times, e.g. Alcove 1, 2, 3, 4… and so on, etc. Using a number after each volume, even if it is the only one on the map is an easy way to keep track of what and where things are.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_20762b04.png]]&lt;br /&gt;
&lt;br /&gt;
2. Reverb Preset- in this field we can assign a reverb to the volume. Any reverb preset that is in the master_reverb FMOD project is available to use in your volumes.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_2d41b5bb.png]]&lt;br /&gt;
&lt;br /&gt;
3. Sounds- sounds can be assigned to audio volumes in this field. When you click to the right of the sounds field a menu called “Sound Instances” will open and you will be able to select sound events from the FMOD project for the level you are working on and assign them to the volume.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m4927b95a.png]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m6325a6cf.png|frame|center|Sounds assigned to a volume.]]&lt;br /&gt;
&lt;br /&gt;
4. Position- this field describes the position of the volume on the map, with values representing points in 3D space including height, which is the last value.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m70cedfbe.png|frame|center|The height of the volume, in meters.]]&lt;br /&gt;
&lt;br /&gt;
All of the numerical values relating to position are copy/pasteable from one object inspector to the other, which is useful when copying a volume from one map to another, for reuse.&lt;br /&gt;
&lt;br /&gt;
5. Sound Instances- this window allows us to select and assign sound events to audio volumes, in addition, we can also perform some editing functions per sound event. When selecting a sound in the “Sound Instances” window the editing functions open up, as below:&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m467394a0.png|frame|center|Sound instance object inspector.]]&lt;br /&gt;
&lt;br /&gt;
These functions enable greater control over each sound event assigned to the volume and we can effectively mix these sounds within each volume, as well as script instances within a volume.&lt;br /&gt;
&lt;br /&gt;
==== The object inspector and emitters ====&lt;br /&gt;
&lt;br /&gt;
When you select an emitter in the area editor, the object inspector shows several fields that will allow us to perform several actions directly related to that emitter. These fields are identical to the “Sound Instances” object inspector functions discussed in the previous entry.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m143509d9.png|frame|center|The emitter object inspector.]]&lt;br /&gt;
&lt;br /&gt;
Within this window we have the ability to modify other parameters such as the active/inactive status of an emitter, adjust the position of the emitter, change the 3D cone of the emitter, as well as adjust the max range of the radius of an emitter, volume, pitch and priority. All of these values can be copied and pasted as well as manipulated instance to instance.&lt;br /&gt;
&lt;br /&gt;
== Volumes and emitters. ==&lt;br /&gt;
&lt;br /&gt;
We can use volumes for two purposes when designing the sound for an area in DA. The first is to use an audio volume to define an area in which you want to play certain sounds as 4.0 ambiences. For example: the borders of a town, or the path of a river, a room in a castle or an outdoor area. All of these instances can use volumes to define the ambient audio we will here when we are in that space in the game. Audio volumes are used in conjunction with emitters to fulfill the 4.0 and 3D directional aspects of all sounds used as ambiences in the game.&lt;br /&gt;
&lt;br /&gt;
=== Audio volumes ===&lt;br /&gt;
&lt;br /&gt;
Audio volumes are used to define an area for 4.0 ambiences to be assigned to. In the area editor, simply right clicking anywhere in the map will allow you to begin to draw an audio volume, as shown below..&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m6f0fdea3.png|frame|center|Right click on the map.]]&lt;br /&gt;
&lt;br /&gt;
You will then see a crosshairs with which you can point and click to draw virtually any complex shape necessary to define the area you need. You draw these shapes by dropping vertices which then can be moved as a group or independently, in 3 dimensions.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m7bf496c3.png|frame|center|Draw the shape desired.]]&lt;br /&gt;
&lt;br /&gt;
As stated we use these volumes and the shapes we draw to define the 4.0 audio for any given area. These volumes show up in the menu on the right hand side of the area editor. It is here that you can select them to edit their properties and parameters in the object inspector.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_69cbabfe.png|frame|center|Placed audio volumes in the menu.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m5099ccff.png|frame|center|Portion of map defined by volumes.]]&lt;br /&gt;
&lt;br /&gt;
=== Reverb volumes ===&lt;br /&gt;
&lt;br /&gt;
Reverb volumes share may of the same properties as audio volumes except they are designed to define an area for a certain reverb. Since we can assign reverbs to audio volumes, the reverb volumes are usually used to draw small volumes to place emitters in order for them to be in a separate reverb from the rest of the area. We can currently have 3 reverbs per area.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m44f5abfb.png|frame|center|Reverb volume with emitters placed inside. ]]&lt;br /&gt;
&lt;br /&gt;
These volumes show up in the menu on the right hand side of the area editor. It is here that you can select them to edit their properties and parameters in the object inspector.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m4fa514c0.png|frame|center|Placed reverb volumes in the menu.]]&lt;br /&gt;
&lt;br /&gt;
=== Emitter properties and utility. ===&lt;br /&gt;
&lt;br /&gt;
Emitters are used in the area editor to perform several functions, they can be placed to provide the sound for a 3D placeable object, like a fire, flag or waterfall:&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m487b9558.png|frame|center|Emitter placed as a 3D placeable object.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_4084754f.png|thumb|center|600px|The FMOD event for this instance.]]&lt;br /&gt;
&lt;br /&gt;
They can be used to define a 3D area effect over an entire area of the map:&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_484de945.png|frame|center|Emitter providing a 3D area effect.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_60d10943.png|thumb|center|600px|The FMOD event for this instance.]]&lt;br /&gt;
&lt;br /&gt;
And finally, they can be used as point source 3D ambience over a selected area of the map.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m7d17ec99.png|frame|center|Emitter used as point source ambience.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m6daf1077.png|thumb|600px|center|The FMOD event for this instance.]]&lt;br /&gt;
&lt;br /&gt;
To place an emitter, the sounds can be accessed in the “Sounds” palette window to the right of the area editor.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_m4737e97a.png|frame|center|“Sounds” selected in the palette window.]]&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_7fa321e0.png|frame|center|Selecting a sound.]]&lt;br /&gt;
&lt;br /&gt;
Upon selection of a sound, you will be given a crosshair and you can drop the sound anywhere on the map. You can then adjust its position in 3 dimensions as you see fit.&lt;br /&gt;
&lt;br /&gt;
[[Image:DA_Audio_Design_Documentation_Ambience_Content_html_bdda402.png|frame|center|Placed sounds in the menu.]]&lt;br /&gt;
&lt;br /&gt;
Sounds used as emitters show up in the menu on the right hand side of the area editor. It is here that you can select them to edit their properties and parameters in the object inspector.&lt;br /&gt;
&lt;br /&gt;
[[Category:Sounds]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Creature_tutorial&amp;diff=7327</id>
		<title>Creature tutorial</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Creature_tutorial&amp;diff=7327"/>
				<updated>2009-10-29T00:05:38Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: punctuation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Now the player can navigate around between the various areas you've set up, but he's got nothing he can actually do there. Other tutorials will cover how to add interactive quests, conversations, and other such things, but for now to make things just a little more interesting, we can add a couple of monsters for the player to slay. We'll put them in the hut_interior area so the player won't be instantly thrust into combat.&lt;br /&gt;
&lt;br /&gt;
== Creating a monstrous creature's template ==&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* The &amp;quot;Group&amp;quot; property determines who is hostile to whom&lt;br /&gt;
* &amp;quot;Resource Name&amp;quot; and &amp;quot;Tag&amp;quot; are only seen by developers &lt;br /&gt;
* &amp;quot;Name&amp;quot; may be seen by players &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
First, create a new creature template. You can leave most of its properties at their defaults for starters. To make it fight the player when it sees him, set the &amp;quot;Group&amp;quot; property to &amp;quot;_Hostile&amp;quot;. Give it a name in the &amp;quot;Name&amp;quot; property (&amp;quot;Hut Monster&amp;quot; in this example) and change the &amp;quot;Appearance&amp;quot; property to something appropriate (a normal Hurlock in this case).&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial hut monster.png]]&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* Put weapons in inventory and set them as &amp;quot;equipped&amp;quot;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
To make our monsters a bit more of a challenge for the player to fight, we'll add a sword to the creature's inventory and set it as &amp;quot;equipped&amp;quot;. This will put the sword on the creature's back, where it will draw it from when it enters combat. To prevent the player from being laden down with hundreds of looted swords over the course of the game we'll leave the &amp;quot;Droppable&amp;quot; and &amp;quot;Stealable&amp;quot; flags unset - when the creature dies the sword will be unrecoverable.&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial inventory.png]]&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* &amp;quot;Package&amp;quot; determines what sorts of abilities the creature will have&lt;br /&gt;
* &amp;quot;Package AI&amp;quot; determines how it will behave&lt;br /&gt;
* &amp;quot;Rank&amp;quot; determines how strong the creature will be and how much loot it drops&lt;br /&gt;
* &amp;quot;Treasure category&amp;quot; determines what type of loot it drops&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Finally, we'll want to set the creature's stats so that it will be the correct level of toughness to challenge the player when he meets him. The game has two basic parameters that need to be set for this; package (determines what general sorts of abilities the creature has) and rank (determines how good the creature is at what it does, and how tough it is).&lt;br /&gt;
&lt;br /&gt;
We set the general package type to &amp;quot;Darkspawn&amp;quot; (this tells the game what general type of creature it is), the package to &amp;quot;Darkspawn weapon + shield (Hurlock)&amp;quot; since that's the closest match to a Hurlock weilding a one-handed sword that's available, and the package AI to &amp;quot;AIP_DS_WPN_SHLD_Hurlock&amp;quot; (since this is the only AI available for the selected package the choice is obvious. For some creatures there may be other AIs available, for example making the creature behave in a more &amp;quot;cowardly&amp;quot; fashion).&lt;br /&gt;
&lt;br /&gt;
The rank of the creature tells the game's autoscaling system how good the creature should be at using its abilities and how tough it is. Since we want these creatures to be an interesting fight but not a serious challenge for our demo, we'll set the hut monster to &amp;quot;Critter&amp;quot;. Rank also determines the quality of the treasure that is automatically generated for the player to loot from the monster's corpse; tougher monsters have higher-quality loot. To determine what ''kind'' of loot is generated, set the treasure category property. Different types of monsters will generally carry different types of loot, for example the Darkspawn are more likely to have vials of poison in their possession.&lt;br /&gt;
&lt;br /&gt;
== Placing creatures ==&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* See [[3D control]] for camera and movement controls &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Now that we have the basic template for the horrible hut monsters defined, we can place some in the hut's interior. The creature we've designed in the creature editor is a template from which many identical copies can be spawned and placed within the area, much like the placeable doors we've inserted previously. Open the area in the area editor, select the hut monster from the palette, and click on the area in the places you want to put copies of the creature.&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial hut interior.png]]&lt;br /&gt;
&lt;br /&gt;
We've put three monsters in the hut. If we play the game now the monsters will attack the player as soon as they perceive him, which the small size of the hut will make almost instantaneous. Once slain the player will be able to loot their corpses for a small amount of treasure.&lt;br /&gt;
&lt;br /&gt;
If you want to customize the individual monsters you've placed, you can right-click on the creature (either in the area map or on the area's object list to the left of the area display) and select &amp;quot;properties&amp;quot; from the menu.&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial individal creature properties.png]]&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* Some creature properties can be customized on a per-creature basis, others are fixed with whatever value you set in the creature template it's based on.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This will open the object inspector with a subset of the creature's properties that can be customized on a per-creature basis. Not all of the properties of the creature can be modified; some of them are defined by the template and can only be modified there. The properties that can be modified on a per-creature basis are:&lt;br /&gt;
&lt;br /&gt;
*Active (useful for placing monsters that only &amp;quot;appear&amp;quot; later on when a script changes their active status)&lt;br /&gt;
*Interaction Radius (if not zero, overrides the default distance the PC needs to be to interact with this object)&lt;br /&gt;
*Platform (used when developing a game that can be ported to multiple different platforms with different capabilities)&lt;br /&gt;
*Rank (how tough the monster is, described above)&lt;br /&gt;
*Tag (a label the creature can be referred to by with scripting)&lt;br /&gt;
*Team (an identifier for grouping several monsters together, useful for keeping track of quests and for coordinated behavior)&lt;br /&gt;
*Trackable&lt;br /&gt;
*Treasure Category (type of treasure dropped, described above)&lt;br /&gt;
*Variables&lt;br /&gt;
*WeaponsDrawn&lt;br /&gt;
*Orientation (Don't bother manually setting orientation and position unless you need high-precision control, the area editor's positioning controls are generally easier)&lt;br /&gt;
*Position&lt;br /&gt;
&lt;br /&gt;
So, for example, we could pick a particular one of these hut monsters and make him tougher than his fellows, or give him a different team ID (we'll see one way team IDs can be used later in the tutorial when we set up a quest for the player to slay all three of the monsters we've put in the hut).&lt;br /&gt;
&lt;br /&gt;
== Creating an NPC quest giver ==&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* Some humanoid creatures don't have clothing built in and need it to be added to their inventory and equipped for it to appear.&lt;br /&gt;
* Some humanoid creatures can have their appearance customized by selecting head [[morph]]s.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The module is now vaguely playable, but not really all that interesting - it's hard to tell a story with nothing but area transitions and meaningless combat. The easiest way to add some depth to the adventure is to include some people that can be talked with. Conversations are complex and will be dealt with in a separate section of the tutorial, but we can lay the foundation here by creating and placing a neutral human to talk to. By putting him in the &amp;quot;_Neutral&amp;quot; group he won't attack the player and won't get involved in the player's fights. If he were in the _Friendly group he'd attack any _Hostile-grouped creatures he perceived, but for now we'll be putting him in an area with no other creatures so that won't make a difference.&lt;br /&gt;
&lt;br /&gt;
The default new creature is human, but is unclothed and unequipped. It also has a very bland default appearance. To dress the creature we'll need to create some clothing as done in the [[Item tutorial]], add it to the creature's inventory, and equip it (if you cannot see your newly-created items in the inventory dialog, try checking them in first).&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial quest giver inventory.png]]&lt;br /&gt;
&lt;br /&gt;
Next we're going to want to replace that bland default head with a different appearance. Dragon Age allows head appearance to be customized through the use of head morphs, a process with sufficient sophistication and scope that there's a separate editing tool dedicated to it. We won't cover that in this tutorial, however, and instead simply use one of the prefabricated head morphs that comes with the game.&lt;br /&gt;
&lt;br /&gt;
Under the &amp;quot;Appearance&amp;quot; section of the object explorer is the &amp;quot;Head Morph&amp;quot; property. When you click on the ellipsis ([[Image:ellipsis.png]]) button you'll be presented with a file picker to choose a head morph from. Once you've selected a head morph most of the other options under Appearance will be disabled, since the head morph customizes all of those parameters in a much more fine-grained manner.&lt;br /&gt;
&lt;br /&gt;
Since this NPC is not intended to ever enter or even respond to combat, the package and scaling is not particularly important. It can be left with the defaults.&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* There are several different ways to make a creature &amp;quot;permanent,&amp;quot; if needed&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;Special&amp;quot; section is relevant in this case, on the other hand. Since this NPC is going to be the source of our quest, it wouldn't do to allow even the possibility that he might get himself killed early. If you set the &amp;quot;Plot&amp;quot; flag to true the creature will be immune to damage by any hostile effect. The &amp;quot;Immortal&amp;quot; flag allows the creature to be damaged, but it will never lose its last hit point - useful if you want a creature to get involved in a fight in a realistic manner but guarantee that it will survive the encounter. &amp;quot;No Permanent Death&amp;quot; tells the game engine not to dispose of the creature's body after it's killed and is used primarily for the player's companions.&lt;br /&gt;
&lt;br /&gt;
Here is the NPC in his final form, ready to be placed in the hut_exterior area to tell the player about the monsters inside:&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial quest giver.png]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Tutorials]]&lt;br /&gt;
[[Category:Creatures]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Creature_tutorial&amp;diff=7326</id>
		<title>Creature tutorial</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Creature_tutorial&amp;diff=7326"/>
				<updated>2009-10-29T00:04:27Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: punctuation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Now the player can navigate around between the various areas you've set up, but he's got nothing he can actually do there. Other tutorials will cover how to add interactive quests, conversations, and other such things, but for now to make things just a little more interesting we can add a couple of monsters for the player to slay. We'll put them in the hut_interior area so the player won't be instantly thrust into combat.&lt;br /&gt;
&lt;br /&gt;
== Creating a monstrous creature's template ==&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* The &amp;quot;Group&amp;quot; property determines who is hostile to whom&lt;br /&gt;
* &amp;quot;Resource Name&amp;quot; and &amp;quot;Tag&amp;quot; are only seen by developers &lt;br /&gt;
* &amp;quot;Name&amp;quot; may be seen by players &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
First, create a new creature template. You can leave most of its properties at their defaults for starters. To make it fight the player when it sees him, set the &amp;quot;Group&amp;quot; property to &amp;quot;_Hostile&amp;quot;. Give it a name in the &amp;quot;Name&amp;quot; property (&amp;quot;Hut Monster&amp;quot; in this example) and change the &amp;quot;Appearance&amp;quot; property to something appropriate (a normal Hurlock in this case).&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial hut monster.png]]&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* Put weapons in inventory and set them as &amp;quot;equipped&amp;quot;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
To make our monsters a bit more of a challenge for the player to fight, we'll add a sword to the creature's inventory and set it as &amp;quot;equipped&amp;quot;. This will put the sword on the creature's back, where it will draw it from when it enters combat. To prevent the player from being laden down with hundreds of looted swords over the course of the game we'll leave the &amp;quot;Droppable&amp;quot; and &amp;quot;Stealable&amp;quot; flags unset - when the creature dies the sword will be unrecoverable.&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial inventory.png]]&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* &amp;quot;Package&amp;quot; determines what sorts of abilities the creature will have&lt;br /&gt;
* &amp;quot;Package AI&amp;quot; determines how it will behave&lt;br /&gt;
* &amp;quot;Rank&amp;quot; determines how strong the creature will be and how much loot it drops&lt;br /&gt;
* &amp;quot;Treasure category&amp;quot; determines what type of loot it drops&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Finally, we'll want to set the creature's stats so that it will be the correct level of toughness to challenge the player when he meets him. The game has two basic parameters that need to be set for this; package (determines what general sorts of abilities the creature has) and rank (determines how good the creature is at what it does, and how tough it is).&lt;br /&gt;
&lt;br /&gt;
We set the general package type to &amp;quot;Darkspawn&amp;quot; (this tells the game what general type of creature it is), the package to &amp;quot;Darkspawn weapon + shield (Hurlock)&amp;quot; since that's the closest match to a Hurlock weilding a one-handed sword that's available, and the package AI to &amp;quot;AIP_DS_WPN_SHLD_Hurlock&amp;quot; (since this is the only AI available for the selected package the choice is obvious. For some creatures there may be other AIs available, for example making the creature behave in a more &amp;quot;cowardly&amp;quot; fashion).&lt;br /&gt;
&lt;br /&gt;
The rank of the creature tells the game's autoscaling system how good the creature should be at using its abilities and how tough it is. Since we want these creatures to be an interesting fight but not a serious challenge for our demo, we'll set the hut monster to &amp;quot;Critter&amp;quot;. Rank also determines the quality of the treasure that is automatically generated for the player to loot from the monster's corpse; tougher monsters have higher-quality loot. To determine what ''kind'' of loot is generated, set the treasure category property. Different types of monsters will generally carry different types of loot, for example the Darkspawn are more likely to have vials of poison in their possession.&lt;br /&gt;
&lt;br /&gt;
== Placing creatures ==&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* See [[3D control]] for camera and movement controls &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Now that we have the basic template for the horrible hut monsters defined, we can place some in the hut's interior. The creature we've designed in the creature editor is a template from which many identical copies can be spawned and placed within the area, much like the placeable doors we've inserted previously. Open the area in the area editor, select the hut monster from the palette, and click on the area in the places you want to put copies of the creature.&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial hut interior.png]]&lt;br /&gt;
&lt;br /&gt;
We've put three monsters in the hut. If we play the game now the monsters will attack the player as soon as they perceive him, which the small size of the hut will make almost instantaneous. Once slain the player will be able to loot their corpses for a small amount of treasure.&lt;br /&gt;
&lt;br /&gt;
If you want to customize the individual monsters you've placed, you can right-click on the creature (either in the area map or on the area's object list to the left of the area display) and select &amp;quot;properties&amp;quot; from the menu.&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial individal creature properties.png]]&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* Some creature properties can be customized on a per-creature basis, others are fixed with whatever value you set in the creature template it's based on.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This will open the object inspector with a subset of the creature's properties that can be customized on a per-creature basis. Not all of the properties of the creature can be modified; some of them are defined by the template and can only be modified there. The properties that can be modified on a per-creature basis are:&lt;br /&gt;
&lt;br /&gt;
*Active (useful for placing monsters that only &amp;quot;appear&amp;quot; later on when a script changes their active status)&lt;br /&gt;
*Interaction Radius (if not zero, overrides the default distance the PC needs to be to interact with this object)&lt;br /&gt;
*Platform (used when developing a game that can be ported to multiple different platforms with different capabilities)&lt;br /&gt;
*Rank (how tough the monster is, described above)&lt;br /&gt;
*Tag (a label the creature can be referred to by with scripting)&lt;br /&gt;
*Team (an identifier for grouping several monsters together, useful for keeping track of quests and for coordinated behavior)&lt;br /&gt;
*Trackable&lt;br /&gt;
*Treasure Category (type of treasure dropped, described above)&lt;br /&gt;
*Variables&lt;br /&gt;
*WeaponsDrawn&lt;br /&gt;
*Orientation (Don't bother manually setting orientation and position unless you need high-precision control, the area editor's positioning controls are generally easier)&lt;br /&gt;
*Position&lt;br /&gt;
&lt;br /&gt;
So, for example, we could pick a particular one of these hut monsters and make him tougher than his fellows, or give him a different team ID (we'll see one way team IDs can be used later in the tutorial when we set up a quest for the player to slay all three of the monsters we've put in the hut).&lt;br /&gt;
&lt;br /&gt;
== Creating an NPC quest giver ==&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* Some humanoid creatures don't have clothing built in and need it to be added to their inventory and equipped for it to appear.&lt;br /&gt;
* Some humanoid creatures can have their appearance customized by selecting head [[morph]]s.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The module is now vaguely playable, but not really all that interesting - it's hard to tell a story with nothing but area transitions and meaningless combat. The easiest way to add some depth to the adventure is to include some people that can be talked with. Conversations are complex and will be dealt with in a separate section of the tutorial, but we can lay the foundation here by creating and placing a neutral human to talk to. By putting him in the &amp;quot;_Neutral&amp;quot; group he won't attack the player and won't get involved in the player's fights. If he were in the _Friendly group he'd attack any _Hostile-grouped creatures he perceived, but for now we'll be putting him in an area with no other creatures so that won't make a difference.&lt;br /&gt;
&lt;br /&gt;
The default new creature is human, but is unclothed and unequipped. It also has a very bland default appearance. To dress the creature we'll need to create some clothing as done in the [[Item tutorial]], add it to the creature's inventory, and equip it (if you cannot see your newly-created items in the inventory dialog, try checking them in first).&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial quest giver inventory.png]]&lt;br /&gt;
&lt;br /&gt;
Next we're going to want to replace that bland default head with a different appearance. Dragon Age allows head appearance to be customized through the use of head morphs, a process with sufficient sophistication and scope that there's a separate editing tool dedicated to it. We won't cover that in this tutorial, however, and instead simply use one of the prefabricated head morphs that comes with the game.&lt;br /&gt;
&lt;br /&gt;
Under the &amp;quot;Appearance&amp;quot; section of the object explorer is the &amp;quot;Head Morph&amp;quot; property. When you click on the ellipsis ([[Image:ellipsis.png]]) button you'll be presented with a file picker to choose a head morph from. Once you've selected a head morph most of the other options under Appearance will be disabled, since the head morph customizes all of those parameters in a much more fine-grained manner.&lt;br /&gt;
&lt;br /&gt;
Since this NPC is not intended to ever enter or even respond to combat, the package and scaling is not particularly important. It can be left with the defaults.&lt;br /&gt;
&lt;br /&gt;
{{sidebox|&lt;br /&gt;
* There are several different ways to make a creature &amp;quot;permanent,&amp;quot; if needed&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;Special&amp;quot; section is relevant in this case, on the other hand. Since this NPC is going to be the source of our quest, it wouldn't do to allow even the possibility that he might get himself killed early. If you set the &amp;quot;Plot&amp;quot; flag to true the creature will be immune to damage by any hostile effect. The &amp;quot;Immortal&amp;quot; flag allows the creature to be damaged, but it will never lose its last hit point - useful if you want a creature to get involved in a fight in a realistic manner but guarantee that it will survive the encounter. &amp;quot;No Permanent Death&amp;quot; tells the game engine not to dispose of the creature's body after it's killed and is used primarily for the player's companions.&lt;br /&gt;
&lt;br /&gt;
Here is the NPC in his final form, ready to be placed in the hut_exterior area to tell the player about the monsters inside:&lt;br /&gt;
&lt;br /&gt;
[[Image:Tutorial quest giver.png]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Tutorials]]&lt;br /&gt;
[[Category:Creatures]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Placeable_tutorial&amp;diff=7322</id>
		<title>Placeable tutorial</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Placeable_tutorial&amp;diff=7322"/>
				<updated>2009-10-28T23:43:38Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Placing / Adjusting your Placeable */ punctuation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In Dragon Age, &amp;quot;[[placeable]]s&amp;quot; are objects that a player can interact with or are objects simply added to the area to create greater detail. They are added to areas simply by dropping them into the area landscape. Once placed, they can easily be moved into position or rotated on their axis to achieve the look you want.&lt;br /&gt;
&lt;br /&gt;
In general, placeables can serve a wide variety of functions. They can render popup text. They can be destroyed or bashed or hold inventory or treasure within. They can be holders of conversations. In this tutorial we'll mainly stick to the basics, but placeables are an important part of any area design.&lt;br /&gt;
&lt;br /&gt;
== Creating A Placeable ==&lt;br /&gt;
&lt;br /&gt;
Similar to creating anything within the toolset, go to File &amp;gt; New &amp;gt; Placeable or right click in the Palette Window to access the New Placeable option.&lt;br /&gt;
&lt;br /&gt;
[[Image:New resource.png|thumb|New resource menu]]&lt;br /&gt;
&lt;br /&gt;
The first step is naming the placeable. We'll need a door for the tutorial so lets start with a door that will serve as an area transition. Name the placeable &amp;quot;transition_door&amp;quot;. Luckily and unluckily, the default object is a door. The lucky part is that it is a door. The unlucky part is that this is a non-area transition door. There are two types of doors, ones that open and allow for an area transition and ones that simply open. For the upcoming [[area tutorial]] we need a door that will allow the player to move from outside the hut to inside the hut.&lt;br /&gt;
&lt;br /&gt;
Doors that allow transitions are all grouped under the Appearance beginning with &amp;quot;Area Transition&amp;quot;. Change the appearance to be &amp;quot;Area Transition, Ferelden, Small&amp;quot;. The placeable has the exact same appearance it had but now it will be able to function as an area transition. For more detail on doors, please see [[door]]s. They are a bit unique within the placeable world so it is important to understand how the two types function as well as some of the finer options that are available.&lt;br /&gt;
&lt;br /&gt;
As you can see, placeables are straightforward and easy to create. Let's build one more for our module before moving along with the tutorial. Again create a new placeable and let's name it &amp;quot;statue&amp;quot;. Any good exterior can always use a statue. For this lets set the appearance to &amp;quot;Statue, Giant&amp;quot; and rename the placeable &amp;quot;Huge Statue&amp;quot;. By default, the placeable is &amp;quot;Interactive&amp;quot; so let's toggle that setting to false. You can either use the drop down menu OR just double click on TRUE to toggle the state. Now our statue is ready to be placed. It is basically an addition to the landscape. It won't be something you can interact with but it can add detail to your area and to your story.&lt;br /&gt;
&lt;br /&gt;
While we are in the tutorial, let's quickly cover checking in and checking out resources which is a new concept for Dragon Age. For a more detailed summary, please see [[Resource palette]]. Briefly, in Dragon Age resources are stored within databases. When you work on a module and alter any existing work or create new work, you are creating an instance of the object (be it a placeable, item, creature, area etc.). There are a number of benefits for this that are beyond the scope of this tutorial but when you edit something, it has to be &amp;quot;checked out&amp;quot; (or never checked in) with you working on an instance.&lt;br /&gt;
&lt;br /&gt;
For example, select your new statue and right click and you will see that many common tasks are NOT available because it has not been &amp;quot;checked in&amp;quot; to the database. For example, you can't rename or delete the placeable. In order to rename the placeable, we'll need to check in the placeable. Right click and select check in. Check the box for no comment or enter a comment and hit ok. At this point, the resource has been written to the database. Once the object is &amp;quot;checked in&amp;quot; you can adjust the name or delete it if you so choose (assuming it doesn't have other dependent resources).&lt;br /&gt;
&lt;br /&gt;
== Placing / Adjusting your Placeable ==&lt;br /&gt;
&lt;br /&gt;
That is a brief overview of how to create your first placeables. Now let's cover putting them into your module. To place a placeable, simply bring up an area (which we will make in the [[Area Tutorial]]), then highlight the placeable and left-click within the region.&lt;br /&gt;
&lt;br /&gt;
To adjust the position or orientation of the object, you'll need to use the Camera and Movement Toolbar:&lt;br /&gt;
&lt;br /&gt;
[[Image:Camera and movement toolbar labeled.png]]&lt;br /&gt;
&lt;br /&gt;
To adjust the x,y,z position either activate the Local Coordinates button [[Image:IconLocalCoordinates.png]] or use the keyboard shortcut 'q'. With this activated, you can mouse over any axis (notice the change to the yellow highlight) and the object will move only in the selected dimension. &lt;br /&gt;
&lt;br /&gt;
To adjust the rotational orientation, highlight the 3 Axis Rotation button [[Image:Icon3AxisRotation.png]] or use the keyboard shortcut 'e'. In a similar fashion, you can easily selected and adjust the rotational orientation of the placeable.&lt;br /&gt;
&lt;br /&gt;
(For much more detail regarding 3D controls please see the [[3D control]] page).&lt;br /&gt;
&lt;br /&gt;
Of course, you can use the Object Inspector to type in exact numbers for any of these parameters you choose. Simply ensure the object is selected within the area viewer and type in your changes.&lt;br /&gt;
&lt;br /&gt;
== Field Notes ==&lt;br /&gt;
&lt;br /&gt;
*'''Character''': Mapping a character to a placeable is done for VO when a placeable owns a conversation.&lt;br /&gt;
&lt;br /&gt;
[[Category:Placeables]]&lt;br /&gt;
[[Category:Tutorials]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Placeable_tutorial&amp;diff=7321</id>
		<title>Placeable tutorial</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Placeable_tutorial&amp;diff=7321"/>
				<updated>2009-10-28T23:43:08Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: /* Placing / Adjusting your Placeable */ grammar&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In Dragon Age, &amp;quot;[[placeable]]s&amp;quot; are objects that a player can interact with or are objects simply added to the area to create greater detail. They are added to areas simply by dropping them into the area landscape. Once placed, they can easily be moved into position or rotated on their axis to achieve the look you want.&lt;br /&gt;
&lt;br /&gt;
In general, placeables can serve a wide variety of functions. They can render popup text. They can be destroyed or bashed or hold inventory or treasure within. They can be holders of conversations. In this tutorial we'll mainly stick to the basics, but placeables are an important part of any area design.&lt;br /&gt;
&lt;br /&gt;
== Creating A Placeable ==&lt;br /&gt;
&lt;br /&gt;
Similar to creating anything within the toolset, go to File &amp;gt; New &amp;gt; Placeable or right click in the Palette Window to access the New Placeable option.&lt;br /&gt;
&lt;br /&gt;
[[Image:New resource.png|thumb|New resource menu]]&lt;br /&gt;
&lt;br /&gt;
The first step is naming the placeable. We'll need a door for the tutorial so lets start with a door that will serve as an area transition. Name the placeable &amp;quot;transition_door&amp;quot;. Luckily and unluckily, the default object is a door. The lucky part is that it is a door. The unlucky part is that this is a non-area transition door. There are two types of doors, ones that open and allow for an area transition and ones that simply open. For the upcoming [[area tutorial]] we need a door that will allow the player to move from outside the hut to inside the hut.&lt;br /&gt;
&lt;br /&gt;
Doors that allow transitions are all grouped under the Appearance beginning with &amp;quot;Area Transition&amp;quot;. Change the appearance to be &amp;quot;Area Transition, Ferelden, Small&amp;quot;. The placeable has the exact same appearance it had but now it will be able to function as an area transition. For more detail on doors, please see [[door]]s. They are a bit unique within the placeable world so it is important to understand how the two types function as well as some of the finer options that are available.&lt;br /&gt;
&lt;br /&gt;
As you can see, placeables are straightforward and easy to create. Let's build one more for our module before moving along with the tutorial. Again create a new placeable and let's name it &amp;quot;statue&amp;quot;. Any good exterior can always use a statue. For this lets set the appearance to &amp;quot;Statue, Giant&amp;quot; and rename the placeable &amp;quot;Huge Statue&amp;quot;. By default, the placeable is &amp;quot;Interactive&amp;quot; so let's toggle that setting to false. You can either use the drop down menu OR just double click on TRUE to toggle the state. Now our statue is ready to be placed. It is basically an addition to the landscape. It won't be something you can interact with but it can add detail to your area and to your story.&lt;br /&gt;
&lt;br /&gt;
While we are in the tutorial, let's quickly cover checking in and checking out resources which is a new concept for Dragon Age. For a more detailed summary, please see [[Resource palette]]. Briefly, in Dragon Age resources are stored within databases. When you work on a module and alter any existing work or create new work, you are creating an instance of the object (be it a placeable, item, creature, area etc.). There are a number of benefits for this that are beyond the scope of this tutorial but when you edit something, it has to be &amp;quot;checked out&amp;quot; (or never checked in) with you working on an instance.&lt;br /&gt;
&lt;br /&gt;
For example, select your new statue and right click and you will see that many common tasks are NOT available because it has not been &amp;quot;checked in&amp;quot; to the database. For example, you can't rename or delete the placeable. In order to rename the placeable, we'll need to check in the placeable. Right click and select check in. Check the box for no comment or enter a comment and hit ok. At this point, the resource has been written to the database. Once the object is &amp;quot;checked in&amp;quot; you can adjust the name or delete it if you so choose (assuming it doesn't have other dependent resources).&lt;br /&gt;
&lt;br /&gt;
== Placing / Adjusting your Placeable ==&lt;br /&gt;
&lt;br /&gt;
That is a brief overview of how to create your first placeables. Now let's cover putting them into your module. To place a placeable, simply bring up an area (which we will make in the [[Area Tutorial]]) then highlight the placeable and left-click within the region.&lt;br /&gt;
&lt;br /&gt;
To adjust the position or orientation of the object, you'll need to use the Camera and Movement Toolbar:&lt;br /&gt;
&lt;br /&gt;
[[Image:Camera and movement toolbar labeled.png]]&lt;br /&gt;
&lt;br /&gt;
To adjust the x,y,z position either activate the Local Coordinates button [[Image:IconLocalCoordinates.png]] or use the keyboard shortcut 'q'. With this activated, you can mouse over any axis (notice the change to the yellow highlight) and the object will move only in the selected dimension. &lt;br /&gt;
&lt;br /&gt;
To adjust the rotational orientation, highlight the 3 Axis Rotation button [[Image:Icon3AxisRotation.png]] or use the keyboard shortcut 'e'. In a similar fashion, you can easily selected and adjust the rotational orientation of the placeable.&lt;br /&gt;
&lt;br /&gt;
(For much more detail regarding 3D controls please see the [[3D control]] page).&lt;br /&gt;
&lt;br /&gt;
Of course, you can use the Object Inspector to type in exact numbers for any of these parameters you choose. Simply ensure the object is selected within the area viewer and type in your changes.&lt;br /&gt;
&lt;br /&gt;
== Field Notes ==&lt;br /&gt;
&lt;br /&gt;
*'''Character''': Mapping a character to a placeable is done for VO when a placeable owns a conversation.&lt;br /&gt;
&lt;br /&gt;
[[Category:Placeables]]&lt;br /&gt;
[[Category:Tutorials]]&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:Placeable_tutorial&amp;diff=7320</id>
		<title>Talk:Placeable tutorial</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:Placeable_tutorial&amp;diff=7320"/>
				<updated>2009-10-28T23:39:19Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;There is a poorly worded fragmented sentence in the Creating A Placeable section. 2nd to last paragraph, last sentence in the paragraph (the one about checking stuff in and out). I think I know what it is trying to say but am not confident about it. It's that &amp;quot;with you working on an instance&amp;quot; bit tacked onto the end there that's throwing me.&lt;br /&gt;
&lt;br /&gt;
I think it means to say that you must be working on an instance in order to make any changes, but in order to create an instance you can work on, you must check it out of the database first. The process of checking a resource out of the database creates this instance for you.&lt;br /&gt;
&lt;br /&gt;
Needs a better writer than me to fix it.&lt;br /&gt;
&lt;br /&gt;
There is also a surprise at the end of the following paragraph. You can freely change the name delete etc except (surprise) in this one case when you have dependent resources (which are ????).&lt;br /&gt;
&lt;br /&gt;
Maybe just one more sentence there to flesh out that special case a tad more. &lt;br /&gt;
&lt;br /&gt;
dependent resources ...such as when you have blah blah causing blah blah dependency.&lt;br /&gt;
&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 23:30, 28 October 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:Placeable_tutorial&amp;diff=7318</id>
		<title>Talk:Placeable tutorial</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:Placeable_tutorial&amp;diff=7318"/>
				<updated>2009-10-28T23:31:40Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;There is a poorly worded fragmented sentence in the Creating A Placeable section. 2nd to last paragraph, last sentence in the paragraph (the one about checking stuff in and out). I think I know what it is trying to say but am not confident about it. It's that &amp;quot;with you working on an instance&amp;quot; bit tacked onto the end there that's throwing me.&lt;br /&gt;
&lt;br /&gt;
I think it means to say that you must be working on an instance in order to make any changes, but in order to create an instance you can work on, you must check it out of the database first. The process of checking a resource out of the database creates this instance for you.&lt;br /&gt;
&lt;br /&gt;
Needs a better writer than me to fix it.&lt;br /&gt;
&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 23:30, 28 October 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	<entry>
		<id>http://datoolset.net/mw/index.php?title=Talk:Placeable_tutorial&amp;diff=7317</id>
		<title>Talk:Placeable tutorial</title>
		<link rel="alternate" type="text/html" href="http://datoolset.net/mw/index.php?title=Talk:Placeable_tutorial&amp;diff=7317"/>
				<updated>2009-10-28T23:30:39Z</updated>
		
		<summary type="html">&lt;p&gt;Axe Murderer: bad wording needs attention&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;There is a poorly worded fragmented sentence in the Creating A Placeable section. 2nd to last paragraph, last sentence in the paragraph (the one about checking stuff in and out). I think I know what it is trying to say but am not confident about it. It's that &amp;quot;with you working on an instance&amp;quot; bit tacked onto the end there that's throwing me.&lt;br /&gt;
I think it means to say that you must be working on an instance in order to make any changes, but in order to create an instance you can work on, you must check it out of the database first. The process of checking a resource out of the database creates this instance for you.&lt;br /&gt;
&lt;br /&gt;
Needs a better writer than me to fix it.&lt;br /&gt;
[[User:Axe Murderer|Axe Murderer]] 23:30, 28 October 2009 (UTC)&lt;/div&gt;</summary>
		<author><name>Axe Murderer</name></author>	</entry>

	</feed>