mirror of
https://github.com/Relintai/entity_spell_system.git
synced 2025-04-17 21:26:35 +02:00
Added a brief description for most of the classes. Started writing method documentaion for aura.
This commit is contained in:
parent
d008221f8d
commit
1cc9d1ace2
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="AIFormation" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Class for scriptable AI formations. Not yet used. Needs pet support.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ActionBarButtonEntry" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores the data for an actionbar button. ProfileManager uses it.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ActionBarEntry" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores the data for an actionbar. ProfileManager uses it.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ActionBarProfile" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores all actionbar-related data for a class. ProfileManager uses it.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="Aura" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Base Aura class. Contains data, and callbacks for aura scripts. Inherit from this to create auras with different functionality.
|
||||
Future: Standard funtionality will be implemented by default, you will only need to inherit for unique spell effects.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
@ -15,6 +17,7 @@
|
||||
<argument index="1" name="data" type="AuraApplyInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Override to change the default damage calculation formula. Serverside only.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_calculate_initial_heal" qualifiers="virtual">
|
||||
@ -25,6 +28,7 @@
|
||||
<argument index="1" name="info" type="AuraApplyInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Override to change the default heal calculation formula. Serverside Only.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_aura_added" qualifiers="virtual">
|
||||
@ -33,6 +37,7 @@
|
||||
<argument index="0" name="data" type="AuraData">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when this aura is applied to an [Entity]. You can apply visual effects here.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_aura_refresh" qualifiers="virtual">
|
||||
@ -41,6 +46,7 @@
|
||||
<argument index="0" name="data" type="AuraData">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when this aura's duration is refreshed on an [Entity].
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_aura_removed" qualifiers="virtual">
|
||||
@ -49,6 +55,7 @@
|
||||
<argument index="0" name="data" type="AuraData">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when this aura's is removed from an [Entity].
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_cast_failed" qualifiers="virtual">
|
||||
@ -59,6 +66,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when an [Entity]'s cast fails.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_cast_finished" qualifiers="virtual">
|
||||
@ -69,6 +77,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when an [Entity]'s cast finsihes.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_cast_started" qualifiers="virtual">
|
||||
@ -79,6 +88,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when an [Entity]'s cast starts.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_cast_state_changed" qualifiers="virtual">
|
||||
@ -89,6 +99,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when an [Entity]'s cast state changes. Not yet used.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_category_cooldown_added" qualifiers="virtual">
|
||||
@ -99,6 +110,7 @@
|
||||
<argument index="1" name="category_cooldown" type="CategoryCooldown">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when an [Entity] receives a [CategoryCooldown].
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_category_cooldown_removed" qualifiers="virtual">
|
||||
@ -109,6 +121,7 @@
|
||||
<argument index="1" name="category_cooldown" type="CategoryCooldown">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when an [Entity]'s [CategoryCooldown] is removed / expires.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_cooldown_added" qualifiers="virtual">
|
||||
@ -119,6 +132,7 @@
|
||||
<argument index="1" name="cooldown" type="Cooldown">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when an [Entity] receives a [Cooldown].
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_cooldown_removed" qualifiers="virtual">
|
||||
@ -129,6 +143,7 @@
|
||||
<argument index="1" name="cooldown" type="Cooldown">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside when an [Entity]'s [Cooldown] is removed / expires.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_damage_dealt" qualifiers="virtual">
|
||||
@ -139,6 +154,7 @@
|
||||
<argument index="1" name="info" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] receives damage.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_dealt_damage" qualifiers="virtual">
|
||||
@ -149,6 +165,7 @@
|
||||
<argument index="1" name="info" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] who deals damage.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_dealt_heal" qualifiers="virtual">
|
||||
@ -159,6 +176,7 @@
|
||||
<argument index="1" name="info" type="SpellHealInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] who deals heal.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_death" qualifiers="virtual">
|
||||
@ -167,6 +185,7 @@
|
||||
<argument index="0" name="data" type="AuraData">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] who dies.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_equip_fail" qualifiers="virtual">
|
||||
@ -183,6 +202,7 @@
|
||||
<argument index="4" name="bag_slot" type="int">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] when equipping an item fails.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_equip_success" qualifiers="virtual">
|
||||
@ -199,6 +219,7 @@
|
||||
<argument index="4" name="bag_slot" type="int">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] when equipping an item succeeds.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_gcd_finished" qualifiers="virtual">
|
||||
@ -207,6 +228,7 @@
|
||||
<argument index="0" name="data" type="AuraData">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] when a global cooldown finishes.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_gcd_started" qualifiers="virtual">
|
||||
@ -217,6 +239,7 @@
|
||||
<argument index="1" name="gcd" type="float">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] when a global cooldown starts.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_heal_dealt" qualifiers="virtual">
|
||||
@ -227,6 +250,7 @@
|
||||
<argument index="1" name="info" type="SpellHealInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] who receives heal.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_level_up" qualifiers="virtual">
|
||||
@ -237,6 +261,7 @@
|
||||
<argument index="1" name="value" type="int">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] who levels up.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_spell_cast_success" qualifiers="virtual">
|
||||
@ -247,6 +272,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] whos spell cast succeeds.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_con_xp_gained" qualifiers="virtual">
|
||||
@ -257,6 +283,7 @@
|
||||
<argument index="1" name="value" type="int">
|
||||
</argument>
|
||||
<description>
|
||||
Called clientside for an [Entity] who gains xp.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_handle_aura_damage" qualifiers="virtual">
|
||||
@ -267,6 +294,7 @@
|
||||
<argument index="1" name="data" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called when this aura wants to deal damage. Serverside only.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_handle_aura_heal" qualifiers="virtual">
|
||||
@ -277,6 +305,7 @@
|
||||
<argument index="1" name="spell_heal_info" type="SpellHealInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called when this aura wants to deal damage. Serverside only.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_sadd" qualifiers="virtual">
|
||||
@ -285,6 +314,7 @@
|
||||
<argument index="0" name="aura" type="AuraData">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when this aura gets added to an [Entity].
|
||||
</description>
|
||||
</method>
|
||||
<method name="_sapply" qualifiers="virtual">
|
||||
@ -293,6 +323,7 @@
|
||||
<argument index="0" name="info" type="AuraApplyInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when this aura gets applied to an [Entity].
|
||||
</description>
|
||||
</method>
|
||||
<method name="_sapply_passives_damage_deal" qualifiers="virtual">
|
||||
@ -301,6 +332,7 @@
|
||||
<argument index="0" name="data" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside, apply damage passives of the caster [Entity] into the [SpellDamageInfo] in this method.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_sapply_passives_damage_receive" qualifiers="virtual">
|
||||
@ -309,6 +341,7 @@
|
||||
<argument index="0" name="data" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside, apply damage passives of the target [Entity] into the [SpellDamageInfo] in this method.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_sapply_passives_heal_deal" qualifiers="virtual">
|
||||
@ -317,6 +350,7 @@
|
||||
<argument index="0" name="info" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside, apply heal passives of the caster [Entity] into the [SpellHealInfo] in this method.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_sapply_passives_heal_receive" qualifiers="virtual">
|
||||
@ -325,6 +359,7 @@
|
||||
<argument index="0" name="info" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside, apply heal passives of the target [Entity] into the [SpellHealInfo] in this method.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_sdeapply" qualifiers="virtual">
|
||||
@ -333,6 +368,7 @@
|
||||
<argument index="0" name="info" type="AuraData">
|
||||
</argument>
|
||||
<description>
|
||||
Called when this aura is getting removed from an [Entity].
|
||||
</description>
|
||||
</method>
|
||||
<method name="_setup_aura_data" qualifiers="virtual">
|
||||
@ -343,6 +379,7 @@
|
||||
<argument index="1" name="data" type="AuraApplyInfo">
|
||||
</argument>
|
||||
<description>
|
||||
This method sets up the given [AuraData] based on the given [AuraApplyInfo]. Override it, if you need to do something special. Serverside.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_should_deny_equip" qualifiers="virtual">
|
||||
@ -355,6 +392,7 @@
|
||||
<argument index="2" name="item" type="ItemInstance">
|
||||
</argument>
|
||||
<description>
|
||||
Gets called if an [Entity] wants to equip an [ItemInstance]. Return true, if tou want this [Aura] to prevent the equip. Serverside.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_after_aura_applied" qualifiers="virtual">
|
||||
@ -371,6 +409,7 @@
|
||||
<argument index="0" name="data" type="AuraData">
|
||||
</argument>
|
||||
<description>
|
||||
Called before an [Aura] gets applied to the [Entity] this [Aura] is on.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_before_cast" qualifiers="virtual">
|
||||
@ -381,6 +420,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside before a cast starts by [Entity] this is on.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_before_cast_target" qualifiers="virtual">
|
||||
@ -391,6 +431,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside before an [Entity]'s cast starts targeting the [Entity] this is on.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_before_damage" qualifiers="virtual">
|
||||
@ -401,6 +442,7 @@
|
||||
<argument index="1" name="data" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside before the [Entity] this [Aura] is on receives damage.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_before_damage_hit" qualifiers="virtual">
|
||||
@ -411,6 +453,7 @@
|
||||
<argument index="1" name="data" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside before the [Entity] this [Aura] is on getting hit by a spell that deals damage.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_before_heal" qualifiers="virtual">
|
||||
@ -421,6 +464,7 @@
|
||||
<argument index="1" name="data" type="SpellHealInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside before the [Entity] this [Aura] is on receives heal.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_before_heal_hit" qualifiers="virtual">
|
||||
@ -431,6 +475,7 @@
|
||||
<argument index="1" name="data" type="SpellHealInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside before the [Entity] this [Aura] is on getting hit by a spell that deals heal.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_cast_failed" qualifiers="virtual">
|
||||
@ -441,6 +486,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when the [Entity]'s cast this [Aura] is on fails. (It moved for example, and the [Spell] did not allow it.)
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_cast_finished" qualifiers="virtual">
|
||||
@ -451,6 +497,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when the [Entity]'s cast this [Aura] is on finishes.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_cast_finished_target" qualifiers="virtual">
|
||||
@ -461,6 +508,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when an [Entity] finishes a cast targeting the [Entity] this [Aura] is on finishes.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_cast_started" qualifiers="virtual">
|
||||
@ -471,6 +519,7 @@
|
||||
<argument index="1" name="info" type="SpellCastInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when the [Entity]'s cast this [Aura] is on starts.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_category_cooldown_added" qualifiers="virtual">
|
||||
@ -481,6 +530,7 @@
|
||||
<argument index="1" name="category_cooldown" type="CategoryCooldown">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when the [Entity] this [Aura] is on receives a [CategoryCooldown].
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_category_cooldown_removed" qualifiers="virtual">
|
||||
@ -491,6 +541,7 @@
|
||||
<argument index="1" name="category_cooldown" type="CategoryCooldown">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when a [CategoryCooldown] of the [Entity] this [Aura] is on gets removed.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_cooldown_added" qualifiers="virtual">
|
||||
@ -501,6 +552,7 @@
|
||||
<argument index="1" name="cooldown" type="Cooldown">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when the [Entity] this [Aura] is on receives a [Cooldown].
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_cooldown_removed" qualifiers="virtual">
|
||||
@ -511,6 +563,7 @@
|
||||
<argument index="1" name="cooldown" type="Cooldown">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when a [Cooldown] of the [Entity] this [Aura] is on gets removed.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_damage_dealt" qualifiers="virtual">
|
||||
@ -521,6 +574,7 @@
|
||||
<argument index="1" name="data" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when an [Entity] this [Aura] is dealt damage.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_damage_receive" qualifiers="virtual">
|
||||
@ -531,6 +585,7 @@
|
||||
<argument index="1" name="data" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when an [Entity] this [Aura] is on receives damage.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_dealt_damage" qualifiers="virtual">
|
||||
@ -541,6 +596,7 @@
|
||||
<argument index="1" name="data" type="SpellDamageInfo">
|
||||
</argument>
|
||||
<description>
|
||||
Called serverside when an [Entity] deals damage to the [Entity] this [Aura] is on.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_dealt_heal" qualifiers="virtual">
|
||||
@ -551,6 +607,7 @@
|
||||
<argument index="1" name="data" type="SpellHealInfo">
|
||||
</argument>
|
||||
<description>
|
||||
|
||||
</description>
|
||||
</method>
|
||||
<method name="_son_death" qualifiers="virtual">
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="AuraApplyInfo" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Helper class, which is used to apply an [Aura] to an [Entity].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="AuraData" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores an [Aura]'s runtime data on an [Entity].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,8 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="AuraGroup" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Used to make some [Aura]s override each other.
|
||||
</brief_description>
|
||||
<description>
|
||||
Only one [Aura] with the same group is allowed on an [Entity] by the same caster by default.
|
||||
|
||||
For example if an [Entity] wants to apply the same [Aura] except different ranks to a target, this is how you can prevent it easily.
|
||||
</description>
|
||||
<tutorials>
|
||||
</tutorials>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="AuraStatAttribute" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores [Stat] modifiers for [Aura]s.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="AuraTriggerData" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
[Aura] effect trigger information. Not yet complete.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="Bag" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores [Entity] inventory.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,8 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="CategoryCooldown" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores [Spell] category cooldown information during runtime.
|
||||
</brief_description>
|
||||
<description>
|
||||
These are interrupts in MMORPGS.
|
||||
</description>
|
||||
<tutorials>
|
||||
</tutorials>
|
||||
|
@ -1,8 +1,14 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="CharacterSkeleton" inherits="Spatial" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores character visual information.
|
||||
</brief_description>
|
||||
<description>
|
||||
This is an abstraction, so [Entity] can equip items, and swap bodyparts without worrying about the implementation itself.
|
||||
|
||||
This class does nothing, but it's not abstract, because you can use this when an [Entity] does not need to be ablke to equip items.
|
||||
|
||||
For example some beasts, or chests, interactable items, etc.
|
||||
</description>
|
||||
<tutorials>
|
||||
</tutorials>
|
||||
|
@ -1,6 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="CharacterSkeleton3D" inherits="CharacterSkeleton" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
3d implementation for [CharacterSkeleton].
|
||||
|
||||
Note: Most of the logic implementation for this is still in gdscript. It will be ported.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,8 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="CharacterSpec" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains data for a character's specialization.
|
||||
</brief_description>
|
||||
<description>
|
||||
Specialization in ESS means talents, and talent tabs.
|
||||
</description>
|
||||
<tutorials>
|
||||
</tutorials>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ClassProfile" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains all profile information for an [Entity]'s class. Related to [ProfileManager].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ComplexLevelStatData" inherits="LevelStatData" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Per level stat information for an [Entity].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="Cooldown" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains the runtime data for one of the [Cooldown]s of an [Entity].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="CraftRecipe" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Recipe data for the crafting system.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="CraftRecipeHelper" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains one item entry for [CraftRecipes]s
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ESDragAndDrop" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Drag and drop helper class for the actionbars, and inventory.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,8 +1,14 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="Entity" inherits="KinematicBody" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Represents an [Entity] inside the world. Entities can be players, mobs, chests, or any kind of interactable things.
|
||||
</brief_description>
|
||||
<description>
|
||||
Functions starting, or having an 's' in them (like adds_cooldown, or sapply_item etc) are only called, or meant to be called by serverside code.
|
||||
Functions with a 'c' in them (like addc_cooldown, cdeapply_item etc) are only called, or meant to be called from clientside code.
|
||||
|
||||
Functions that have a virtual variant starting with an underscore, should be called, they will call the virtual version.
|
||||
They will check if the virtual properly exists, also usually they check if the parameters are valid, so you don't have to do it every time in gdscript.
|
||||
</description>
|
||||
<tutorials>
|
||||
</tutorials>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntityAI" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
You can implement AI for [Entities] with this.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntityClassData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains all of information for an [Entity]'s class. (Ingame class)
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntityCreateInfo" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Helper class used for [Entity] creation, and setup.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntityData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains all data for a given [Entity]. Think of this as all the data for a mob, or a player.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,8 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntityDataManager" inherits="Node" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
This class should be added as an autoload. (Or be present in the scene when you want to spawn entities).
|
||||
|
||||
This loads in and stores all information required.
|
||||
</brief_description>
|
||||
<description>
|
||||
The main reason for this class is networking, when the server sends the client an aura, you need to be able to look it up by an id.
|
||||
</description>
|
||||
<tutorials>
|
||||
</tutorials>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntityEnums" inherits="Object" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains lots of general-use enums for entities.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntityResource" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
An instance of an entity resource. Resource in this context is things like mana.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntityResourceCostData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains a resource cost. Resource in this context is things like mana.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntityResourceData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
The data for an [Entity]'s resource. Resource in this context is things like mana.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,8 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntitySkill" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains runtime skill data for an [Entity].
|
||||
</brief_description>
|
||||
<description>
|
||||
Skills can be things like axes. You can change values for these using scripts.
|
||||
</description>
|
||||
<tutorials>
|
||||
</tutorials>
|
||||
|
@ -1,8 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntitySkillData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains skill data for an [Entity].
|
||||
</brief_description>
|
||||
<description>
|
||||
Skills can be things like axes.
|
||||
</description>
|
||||
<tutorials>
|
||||
</tutorials>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EntitySpeciesData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains visual data for a species.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EquipmentData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores equipment information.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="EquipmentDataEntry" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores equipment information.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="InputProfile" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Will store keybind information. [ProfileManager] related.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="InputProfileModifier" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores data for bindable modifiers. Not yet implemented.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="InputProfileModifierEntry" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
One key entry for a key.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ItemEnums" inherits="Object" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains lots of general-use enums for items.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ItemInstance" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Runtime information for an item.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ItemStatModifier" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Runtime item [Stat] modifier data.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ItemTemplate" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains item information.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ItemTemplateStatModifier" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
[Stat] modifier data for [ItemTemplates].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ItemVisual" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
contains an item's visual information.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ItemVisualEntry" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
One Entry for [ItemVisual].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="LevelStatData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Base class for storing level stat information for entities.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="LootDataBase" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Base class for storing loot information for entities.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="LootDataContainter" inherits="LootDataBase" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Container class for storing loot information for entities.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="LootDataItem" inherits="LootDataBase" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains one item's loot information for entities.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="ProfileManager" inherits="Node" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores, saves, loads per class profile data.
|
||||
|
||||
Should be added as an autoload, or at least is should be in the scene before spawning entities.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="SimpleLevelStatData" inherits="LevelStatData" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Simple per-level [Stat] information for entities.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="SkeletonModelEntry" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Runtime model item entry helper for skeletons. Used by [CharacterSkeleton3D] for example.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="SpeciesModelData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores model information for [EntitySpeciesData].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="Spell" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Base Spell class. Contains data, and callbacks for spell scripts. Inherit from this to create spells with different functionality.
|
||||
|
||||
Future: Standard funtionality will be implemented by default, you will only need to inherit for unique spell effects.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="SpellCastInfo" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains spell cast related information, for easy manipulation with auras, spell callbacks, etc.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="SpellCooldownManipulationData" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains data for easy spell cooldown manipulations. Not yet implemented.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="SpellDamageInfo" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains damage information. It is passed around in callbacks, so things can modify values. (absorbs, immunities etc.)
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="SpellEffectVisual" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Base class for storing spell visual information, like particle effects.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="SpellEffectVisualSimple" inherits="SpellEffectVisual" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Simple implementation od [SpellEfectVisual].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="SpellEnums" inherits="Object" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains lots of general-use enums for spells.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="SpellHealInfo" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains heal information. It is passed around in callbacks, so things can modify values. (absorbs, immunities etc.)
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="Stat" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains the runtime data of a stat.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="StatData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains a [Stat]'s data.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="StatDataEntry" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
One entry for [StatData].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="StatModifier" inherits="Reference" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Class for holding the runtime information for a stat modifier.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="TalentRowData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains one row of for a talent specialization.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="UnitFrame" inherits="Panel" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Unitframe's base class. Will probably be removed.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="VendorItemData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains vendor item data for an [Entity]/[EntityData].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="VendorItemDataEntry" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains one entry for a [VendorItemData].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="WorldSpell" inherits="Spatial" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Represents a [Spell] projectile in the world.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="WorldSpellData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Stores the data for a [WorldSpell].
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<class name="XPData" inherits="Resource" category="Core" version="3.2">
|
||||
<brief_description>
|
||||
Contains the XP values required to level up for entities.
|
||||
</brief_description>
|
||||
<description>
|
||||
</description>
|
||||
|
142
meshes/editor_import_collada_mdr.cpp
Normal file
142
meshes/editor_import_collada_mdr.cpp
Normal file
@ -0,0 +1,142 @@
|
||||
#include "editor_import_collada_mdr.h"
|
||||
|
||||
String EditorImportColladaMdr::get_importer_name() const {
|
||||
return "collada_mdr";
|
||||
}
|
||||
|
||||
String EditorImportColladaMdr::get_visible_name() const {
|
||||
return "Collada MDR";
|
||||
}
|
||||
|
||||
void EditorImportColladaMdr::get_recognized_extensions(List<String> *p_extensions) const {
|
||||
p_extensions->push_back("dae");
|
||||
}
|
||||
|
||||
String EditorImportColladaMdr::get_save_extension() const {
|
||||
return "res";
|
||||
}
|
||||
|
||||
String EditorImportColladaMdr::get_resource_type() const {
|
||||
return "MeshDataResource";
|
||||
}
|
||||
|
||||
float EditorImportColladaMdr::get_priority() const {
|
||||
return 1.0;
|
||||
}
|
||||
|
||||
int EditorImportColladaMdr::get_preset_count() const {
|
||||
return 0;
|
||||
}
|
||||
|
||||
String EditorImportColladaMdr::get_preset_name(int p_idx) const {
|
||||
return "";
|
||||
}
|
||||
|
||||
void EditorImportColladaMdr::get_import_options(List<ImportOption> *r_options, int p_preset) const {
|
||||
r_options->push_back(ImportOption(PropertyInfo(Variant::VECTOR3, "offset"), Vector3(0, 0, 0)));
|
||||
r_options->push_back(ImportOption(PropertyInfo(Variant::VECTOR3, "rotation"), Vector3(0, 0, -(3.141592 / 2.0))));
|
||||
r_options->push_back(ImportOption(PropertyInfo(Variant::VECTOR3, "scale"), Vector3(0.011, 0.011, 0.011)));
|
||||
}
|
||||
|
||||
bool EditorImportColladaMdr::get_option_visibility(const String &p_option, const Map<StringName, Variant> &p_options) const {
|
||||
return true;
|
||||
}
|
||||
|
||||
Error EditorImportColladaMdr::import(const String &p_source_file, const String &p_save_path, const Map<StringName, Variant> &p_options, List<String> *r_platform_variants, List<String> *r_gen_files, Variant *r_metadata) {
|
||||
Node *n = _importer->import_scene(p_source_file, 0, 15);
|
||||
|
||||
if (n == NULL) {
|
||||
n->queue_delete();
|
||||
return Error::ERR_PARSE_ERROR;
|
||||
}
|
||||
|
||||
for (int i = 0; i < n->get_child_count(); ++i) {
|
||||
Node *c = n->get_child(i);
|
||||
print_error(String::num(i));
|
||||
|
||||
if (c == NULL) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (Object::cast_to<MeshInstance>(c)) {
|
||||
MeshInstance *mi = Object::cast_to<MeshInstance>(c);
|
||||
|
||||
Ref<ArrayMesh> mesh = mi->get_mesh();
|
||||
|
||||
if (mesh.is_valid()) {
|
||||
Ref<MeshDataResource> mdr;
|
||||
mdr.instance();
|
||||
|
||||
Array arrays = mesh->surface_get_arrays(0);
|
||||
|
||||
mdr->set_array(apply_transforms(arrays, p_options));
|
||||
|
||||
n->queue_delete();
|
||||
|
||||
return ResourceSaver::save(p_save_path + "." + get_save_extension(), mdr);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
n->queue_delete();
|
||||
return Error::ERR_PARSE_ERROR;
|
||||
}
|
||||
|
||||
|
||||
Array EditorImportColladaMdr::apply_transforms(Array &array, const Map<StringName, Variant> &p_options) {
|
||||
Vector3 offset = p_options["offset"];
|
||||
Vector3 rotation = p_options["rotation"];
|
||||
Vector3 scale = p_options["scale"];
|
||||
|
||||
Transform transform = Transform(Basis(rotation).scaled(scale), offset);
|
||||
|
||||
Array verts = array.get(Mesh::ARRAY_VERTEX);
|
||||
|
||||
for (int i = 0; i < verts.size(); ++i) {
|
||||
Vector3 vert = verts[i];
|
||||
|
||||
vert = transform.xform(vert);
|
||||
|
||||
verts.set(i, (vert));
|
||||
}
|
||||
|
||||
Array normals = array.get(Mesh::ARRAY_NORMAL);
|
||||
|
||||
for (int i = 0; i < normals.size(); ++i) {
|
||||
Vector3 normal = normals[i];
|
||||
|
||||
normal = transform.basis.xform(normal);
|
||||
|
||||
normals.set(i, normal);
|
||||
}
|
||||
|
||||
Array tangents = array.get(Mesh::ARRAY_TANGENT);
|
||||
|
||||
if (tangents.size() == verts.size() * 4) {
|
||||
|
||||
for (int i = 0; i < verts.size(); ++i) {
|
||||
|
||||
Plane p(tangents[i * 4 + 0], tangents[i * 4 + 1], tangents[i * 4 + 2], tangents[i * 4 + 3]);
|
||||
|
||||
Vector3 tangent = p.normal;
|
||||
|
||||
tangent = transform.basis.xform(tangent);
|
||||
|
||||
tangents.set(i, tangent);
|
||||
}
|
||||
}
|
||||
|
||||
array.set(Mesh::ARRAY_VERTEX, verts);
|
||||
array.set(Mesh::ARRAY_NORMAL, normals);
|
||||
array.set(Mesh::ARRAY_TANGENT, tangents);
|
||||
|
||||
return array;
|
||||
}
|
||||
|
||||
EditorImportColladaMdr::EditorImportColladaMdr() {
|
||||
_importer.instance();
|
||||
}
|
||||
|
||||
EditorImportColladaMdr::~EditorImportColladaMdr() {
|
||||
_importer.unref();
|
||||
}
|
47
meshes/editor_import_collada_mdr.h
Normal file
47
meshes/editor_import_collada_mdr.h
Normal file
@ -0,0 +1,47 @@
|
||||
|
||||
#ifndef EDITOR_IMPORT_COLLADA_MDR
|
||||
#define EDITOR_IMPORT_COLLADA_MDR
|
||||
|
||||
#include "editor/import/editor_import_plugin.h"
|
||||
#include "core/ustring.h"
|
||||
#include "scene/main/node.h"
|
||||
#include "scene/resources/mesh.h"
|
||||
#include "scene/3d/mesh_instance.h"
|
||||
#include "core/io/resource_saver.h"
|
||||
#include "core/array.h"
|
||||
#include "core/math/basis.h"
|
||||
#include "core/math/transform.h"
|
||||
|
||||
#include "mesh_data_resource.h"
|
||||
#include "editor/import/editor_import_collada.h"
|
||||
|
||||
class EditorImportColladaMdr : public EditorImportPlugin {
|
||||
|
||||
GDCLASS(EditorImportColladaMdr, EditorImportPlugin);
|
||||
|
||||
public:
|
||||
virtual String get_importer_name() const;
|
||||
virtual String get_visible_name() const;
|
||||
virtual void get_recognized_extensions(List<String> *p_extensions) const;
|
||||
virtual String get_save_extension() const;
|
||||
virtual String get_resource_type() const;
|
||||
virtual float get_priority() const;
|
||||
|
||||
virtual int get_preset_count() const;
|
||||
virtual String get_preset_name(int p_idx) const;
|
||||
|
||||
virtual void get_import_options(List<ImportOption> *r_options, int p_preset = 0) const;
|
||||
virtual bool get_option_visibility(const String &p_option, const Map<StringName, Variant> &p_options) const;
|
||||
|
||||
virtual Error import(const String &p_source_file, const String &p_save_path, const Map<StringName, Variant> &p_options, List<String> *r_platform_variants, List<String> *r_gen_files = NULL, Variant *r_metadata = NULL);
|
||||
|
||||
Array apply_transforms(Array &array, const Map<StringName, Variant> &p_options);
|
||||
|
||||
EditorImportColladaMdr();
|
||||
~EditorImportColladaMdr();
|
||||
|
||||
private:
|
||||
Ref<EditorSceneImporterCollada> _importer;
|
||||
};
|
||||
|
||||
#endif
|
22
meshes/editor_plugin_collada_mdr.cpp
Normal file
22
meshes/editor_plugin_collada_mdr.cpp
Normal file
@ -0,0 +1,22 @@
|
||||
#include "editor_plugin_collada_mdr.h"
|
||||
|
||||
void EditorPluginColladaMdr::_notification(int p_what) {
|
||||
switch (p_what) {
|
||||
case NOTIFICATION_ENTER_TREE:
|
||||
_importer.instance();
|
||||
|
||||
add_import_plugin(_importer);
|
||||
|
||||
break;
|
||||
case NOTIFICATION_EXIT_TREE:
|
||||
remove_import_plugin(_importer);
|
||||
|
||||
_importer.unref();
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
EditorPluginColladaMdr::EditorPluginColladaMdr(EditorNode *node) {
|
||||
_node = node;
|
||||
}
|
25
meshes/editor_plugin_collada_mdr.h
Normal file
25
meshes/editor_plugin_collada_mdr.h
Normal file
@ -0,0 +1,25 @@
|
||||
|
||||
#ifndef EDITOR_PLUGIN_COLLADA_MDR
|
||||
#define EDITOR_PLUGIN_COLLADA_MDR
|
||||
|
||||
#include "editor/editor_plugin.h"
|
||||
#include "core/ustring.h"
|
||||
|
||||
#include "editor_import_collada_mdr.h"
|
||||
|
||||
class EditorPluginColladaMdr : public EditorPlugin {
|
||||
|
||||
GDCLASS(EditorPluginColladaMdr, EditorPlugin);
|
||||
|
||||
public:
|
||||
EditorPluginColladaMdr(EditorNode *node);
|
||||
|
||||
protected:
|
||||
void _notification(int p_what);
|
||||
|
||||
private:
|
||||
EditorNode *_node;
|
||||
Ref<EditorImportColladaMdr> _importer;
|
||||
};
|
||||
|
||||
#endif
|
20
meshes/mesh_data_resource.cpp
Normal file
20
meshes/mesh_data_resource.cpp
Normal file
@ -0,0 +1,20 @@
|
||||
#include "mesh_data_resource.h"
|
||||
|
||||
Array MeshDataResource::get_array() {
|
||||
return _arrays;
|
||||
}
|
||||
void MeshDataResource::set_array(const Array &p_arrays) {
|
||||
_arrays.clear();
|
||||
|
||||
_arrays = p_arrays.duplicate(true);
|
||||
}
|
||||
|
||||
MeshDataResource::MeshDataResource() {
|
||||
|
||||
}
|
||||
|
||||
void MeshDataResource::_bind_methods() {
|
||||
ClassDB::bind_method(D_METHOD("get_array"), &MeshDataResource::get_array);
|
||||
ClassDB::bind_method(D_METHOD("set_array", "array"), &MeshDataResource::set_array);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::ARRAY, "array"), "set_array", "get_array");
|
||||
}
|
26
meshes/mesh_data_resource.h
Normal file
26
meshes/mesh_data_resource.h
Normal file
@ -0,0 +1,26 @@
|
||||
#ifndef MESH_DATA_REOURCE_H
|
||||
#define MESH_DATA_REOURCE_H
|
||||
|
||||
#include "core/resource.h"
|
||||
#include "core/array.h"
|
||||
#include "scene/resources/mesh.h"
|
||||
|
||||
class MeshDataResource : public Resource {
|
||||
|
||||
GDCLASS(MeshDataResource, Resource);
|
||||
RES_BASE_EXTENSION("mdres");
|
||||
|
||||
public:
|
||||
Array get_array();
|
||||
void set_array(const Array &p_arrays);
|
||||
|
||||
MeshDataResource();
|
||||
|
||||
protected:
|
||||
static void _bind_methods();
|
||||
|
||||
private:
|
||||
Array _arrays;
|
||||
};
|
||||
|
||||
#endif
|
Loading…
Reference in New Issue
Block a user