Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 1b1963e6d2 |
+1
-1
Submodule assets updated: b6027bf49f...2c75d24ddf
@@ -213,6 +213,7 @@ bool FirstPersonInputController<EventContext>::OnCommand(const Events::InputComm
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
EntityWrapper firstPersonModel = m_PlayerEntity.FirstChildByName("Hands");
|
||||
if (firstPersonModel.Valid()) {
|
||||
if (val > 0) { // Walk/Run
|
||||
|
||||
@@ -32,8 +32,6 @@ private:
|
||||
glm::vec3 m_LastPosition = glm::vec3();
|
||||
// Used to track afterimages for sprint effect.
|
||||
float m_SprintEffectTimer;
|
||||
// Used to track afterimages for dash effect.
|
||||
float m_DashEffectTimer;
|
||||
// The logic for making the sound play when player is moving
|
||||
void playerStep(double dt, EntityWrapper player);
|
||||
// Spawn a hexagon at origin of an Entity
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||
<BoostAssault xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="BoostAssault.xsd">
|
||||
<StrengthOfEffect>1.35</StrengthOfEffect>
|
||||
<StrengthOfEffect>2</StrengthOfEffect>
|
||||
</BoostAssault>
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
<MaxTravelAngle>0.174533</MaxTravelAngle> <!-- 0.174533 = 10 degrees -->
|
||||
<NumPellets>9</NumPellets>
|
||||
<RPM>120</RPM>
|
||||
<ViewPunch>0.15</ViewPunch>
|
||||
<ViewReturnSpeed>0.3</ViewReturnSpeed>
|
||||
<ViewPunch>0.03</ViewPunch>
|
||||
<ViewReturnSpeed>0.2</ViewReturnSpeed>
|
||||
<ReloadTime>0.5</ReloadTime>
|
||||
<TriggerHeld>false</TriggerHeld>
|
||||
<FireCooldown>0</FireCooldown>
|
||||
|
||||
@@ -3,6 +3,5 @@
|
||||
<FadeTime>1</FadeTime>
|
||||
<Time>0</Time>
|
||||
<Out>true</Out>
|
||||
<Loop>true</Loop>
|
||||
<Reverse>false</Reverse>
|
||||
</Fade>
|
||||
@@ -11,9 +11,6 @@
|
||||
<xs:element name="Out" type="t:bool" minOccurs="0">
|
||||
<xs:annotation><xs:documentation>If the entity should fade out or in.</xs:documentation></xs:annotation>
|
||||
</xs:element>
|
||||
<xs:element name="Loop" type="t:bool" minOccurs="0">
|
||||
<xs:annotation><xs:documentation>If the effect should loop when it is done.</xs:documentation></xs:annotation>
|
||||
</xs:element>
|
||||
<xs:element name="Reverse" type="t:bool" minOccurs="0">
|
||||
<xs:annotation><xs:documentation>If the entity should reverse the fade after finishing, this will double the speed.</xs:documentation></xs:annotation>
|
||||
</xs:element>
|
||||
|
||||
@@ -6,9 +6,7 @@
|
||||
<BaseDamage>20</BaseDamage>
|
||||
<RPM>500</RPM>
|
||||
<Automatic>false</Automatic>
|
||||
<ViewPunch>0.05</ViewPunch>
|
||||
<MaxTravelAngle>0.174533</MaxTravelAngle> <!-- 0.174533 = 10 degrees -->
|
||||
<ViewReturnSpeed>0.2</ViewReturnSpeed>
|
||||
<ViewPunch>0.01</ViewPunch>
|
||||
<ReloadTime>1.0</ReloadTime>
|
||||
<EquipTime>0.5</EquipTime>
|
||||
<TriggerHeld>false</TriggerHeld>
|
||||
@@ -16,5 +14,4 @@
|
||||
<ReloadQueued>false</ReloadQueued>
|
||||
<IsReloading>false</IsReloading>
|
||||
<ReloadTimer>0</ReloadTimer>
|
||||
<CurrentTravel>0</CurrentTravel>
|
||||
</SidearmWeapon>
|
||||
@@ -36,12 +36,6 @@
|
||||
<xs:element name="ViewPunch" type="t:float" minOccurs="0">
|
||||
<xs:annotation><xs:documentation>View punch in radians for each shell fired</xs:documentation></xs:annotation>
|
||||
</xs:element>
|
||||
<xs:element name="MaxTravelAngle" type="t:float" minOccurs="0">
|
||||
<xs:annotation><xs:documentation>Maximum vertical aim travel angle in radians</xs:documentation></xs:annotation>
|
||||
</xs:element>
|
||||
<xs:element name="ViewReturnSpeed" type="t:float" minOccurs="0">
|
||||
<xs:annotation><xs:documentation>The speed in radians per second the view returns to its original position after being punched</xs:documentation></xs:annotation>
|
||||
</xs:element>
|
||||
<xs:element name="ReloadTime" type="t:double" minOccurs="0">
|
||||
<xs:annotation><xs:documentation>Time it takes to load ONE SHELL into the weapon in seconds</xs:documentation></xs:annotation>
|
||||
</xs:element>
|
||||
@@ -53,7 +47,6 @@
|
||||
<xs:element name="ReloadQueued" type="t:bool" minOccurs="0"/>
|
||||
<xs:element name="IsReloading" type="t:bool" minOccurs="0"/>
|
||||
<xs:element name="ReloadTimer" type="t:double" minOccurs="0"/>
|
||||
<xs:element name="CurrentTravel" type="t:float" minOccurs="0"/>
|
||||
</xs:all>
|
||||
</xs:complexType>
|
||||
</xs:element>
|
||||
|
||||
+6036
-6131
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||
<Entity name="DashEffect" xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../Types/Entity.xsd">
|
||||
|
||||
<Components>
|
||||
<c:Lifetime>
|
||||
<Lifetime>0.5</Lifetime>
|
||||
</c:Lifetime>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
|
||||
<Children/>
|
||||
|
||||
</Entity>
|
||||
@@ -5,7 +5,6 @@
|
||||
<c:Lifetime>
|
||||
<Lifetime>0.079999998211860657</Lifetime>
|
||||
</c:Lifetime>
|
||||
<c:NetworkComponent/>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
|
||||
@@ -18,8 +17,10 @@
|
||||
<DiffuseTexture>Textures/Effects/NewRay5.png</DiffuseTexture>
|
||||
<Color A="1" B="2.35294127" G="1.17647064" R="0"/>
|
||||
<KeepRatio>true</KeepRatio>
|
||||
<Linear>true</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="-0.5"/>
|
||||
<Orientation X="0" Y="-1.57099998" Z="0"/>
|
||||
<Scale X="1" Y="0.0700000003" Z="0"/>
|
||||
</c:Transform>
|
||||
@@ -34,8 +35,10 @@
|
||||
<DiffuseTexture>Textures/Effects/NewRay5.png</DiffuseTexture>
|
||||
<Color A="1" B="2.35294127" G="1.17647064" R="0"/>
|
||||
<KeepRatio>true</KeepRatio>
|
||||
<Linear>true</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="-0.5"/>
|
||||
<Orientation X="0" Y="4.71218538" Z="3.14199996"/>
|
||||
<Scale X="1" Y="0.0700000003" Z="0"/>
|
||||
</c:Transform>
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
<c:Lifetime>
|
||||
<Lifetime>0.079999998211860657</Lifetime>
|
||||
</c:Lifetime>
|
||||
<c:NetworkComponent/>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
|
||||
@@ -18,10 +17,12 @@
|
||||
<DiffuseTexture>Textures/Effects/NewRay7.png</DiffuseTexture>
|
||||
<Color A="1" B="2.35294127" G="1.17647064" R="0"/>
|
||||
<KeepRatio>true</KeepRatio>
|
||||
<Linear>true</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="-0.5"/>
|
||||
<Orientation X="0" Y="-1.57099998" Z="0"/>
|
||||
<Scale X="1" Y="0.0700000003" Z="1"/>
|
||||
<Scale X="1" Y="0.0700000003" Z="0"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
@@ -34,10 +35,12 @@
|
||||
<DiffuseTexture>Textures/Effects/NewRay7.png</DiffuseTexture>
|
||||
<Color A="1" B="2.35294127" G="1.17647064" R="0"/>
|
||||
<KeepRatio>true</KeepRatio>
|
||||
<Linear>true</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="-0.5"/>
|
||||
<Orientation X="0" Y="4.71218538" Z="3.14199996"/>
|
||||
<Scale X="1" Y="0.0700000003" Z="1"/>
|
||||
<Scale X="1" Y="0.0700000003" Z="0"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
|
||||
@@ -3,12 +3,11 @@
|
||||
|
||||
<Components>
|
||||
<c:Lifetime>
|
||||
<Lifetime>0.080000000000000002</Lifetime>
|
||||
<Lifetime>0.08</Lifetime>
|
||||
</c:Lifetime>
|
||||
<c:Fade>
|
||||
<FadeTime>0.080000000000000002</FadeTime>
|
||||
<FadeTime>0.08</FadeTime>
|
||||
</c:Fade>
|
||||
<c:NetworkComponent/>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
|
||||
@@ -21,8 +20,10 @@
|
||||
<DiffuseTexture>Textures/Effects/NewRay5.png</DiffuseTexture>
|
||||
<Color A="1" B="2.35294127" G="1.17647064" R="0"/>
|
||||
<KeepRatio>true</KeepRatio>
|
||||
<Linear>true</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="-0.5"/>
|
||||
<Orientation X="0" Y="-1.57099998" Z="0"/>
|
||||
<Scale X="1" Y="0.0250000004" Z="0"/>
|
||||
</c:Transform>
|
||||
@@ -37,8 +38,10 @@
|
||||
<DiffuseTexture>Textures/Effects/NewRay5.png</DiffuseTexture>
|
||||
<Color A="1" B="2.35294127" G="1.17647064" R="0"/>
|
||||
<KeepRatio>true</KeepRatio>
|
||||
<Linear>true</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="-0.5"/>
|
||||
<Orientation X="0" Y="4.71218538" Z="3.14199996"/>
|
||||
<Scale X="1" Y="0.0250000004" Z="0"/>
|
||||
</c:Transform>
|
||||
|
||||
@@ -6,14 +6,12 @@
|
||||
<Lifetime>2</Lifetime>
|
||||
</c:Lifetime>
|
||||
<c:ExplosionEffect>
|
||||
<Velocity X="1.78000009" Y="0.0320000015" Z="0"/>
|
||||
<ExplosionOrigin X="0" Y="0.142000005" Z="-0.659000039"/>
|
||||
<EndColor A="0" B="19.6078434" G="0.00392156886" R="1.96078432"/>
|
||||
<RandomnessScalar>1.3399996757507324</RandomnessScalar>
|
||||
<Randomness>true</Randomness>
|
||||
<ColorByDistance>true</ColorByDistance>
|
||||
<Velocity X="1.63300014" Y="0.0320000015" Z="0"/>
|
||||
<ExplosionOrigin X="0" Y="0.0790000036" Z="-0.329000026"/>
|
||||
<ExponentialAccelaration>true</ExponentialAccelaration>
|
||||
<ColorDistanceScalar>5.0899982452392578</ColorDistanceScalar>
|
||||
<EndColor A="0" B="19.6078434" G="19.6078434" R="0"/>
|
||||
<Randomness>true</Randomness>
|
||||
</c:ExplosionEffect>
|
||||
<c:Model>
|
||||
<Resource>Models/Weapons/Blue/AssaultWeaponBlue.mesh</Resource>
|
||||
|
||||
@@ -18,126 +18,7 @@
|
||||
<Position X="-16.5" Y="0" Z="0"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="ScoreBoard_Red_Origin">
|
||||
<Components>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="RedSide">
|
||||
<Components>
|
||||
<c:Model>
|
||||
<Resource>Models/Core/UnitCube.mesh</Resource>
|
||||
<Color A="1" B="0" G="0.0862745121" R="1"/>
|
||||
<Visible>false</Visible>
|
||||
</c:Model>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="0.5"/>
|
||||
<Scale X="32" Y="23" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="ScoreBoard_Red">
|
||||
<Components>
|
||||
<c:Team>
|
||||
<Team>
|
||||
<Red/>
|
||||
</Team>
|
||||
</c:Team>
|
||||
<c:ScoreScreen>
|
||||
<Offset X="0" Y="-3" Z="0"/>
|
||||
</c:ScoreScreen>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="7" Z="1.5"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="IDText">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>ID</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Left/>
|
||||
</Alignment>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="-13" Y="2.5" Z="0"/>
|
||||
<Scale X="2" Y="2" Z="2"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="NameText">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>Name</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Left/>
|
||||
</Alignment>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="-10" Y="2.5" Z="0"/>
|
||||
<Scale X="2" Y="2" Z="2"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="KDText">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>KD</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Left/>
|
||||
</Alignment>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="1.28838646" Y="2.5" Z="0"/>
|
||||
<Scale X="2" Y="2" Z="2"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="KillsText">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>Kills</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Left/>
|
||||
</Alignment>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="4.6874299" Y="2.5" Z="0"/>
|
||||
<Scale X="2" Y="2" Z="2"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="DeathsText">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>Deaths</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Left/>
|
||||
</Alignment>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="8.9577198" Y="2.5" Z="0"/>
|
||||
<Scale X="2" Y="2" Z="2"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="Background_Main">
|
||||
<Components>
|
||||
@@ -175,126 +56,7 @@
|
||||
<Position X="16.5" Y="0" Z="0"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="ScoreBoard_Blue_Origin">
|
||||
<Components>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="BlueSide">
|
||||
<Components>
|
||||
<c:Model>
|
||||
<Resource>Models/Core/UnitCube.mesh</Resource>
|
||||
<Color A="1" B="1" G="0.505882382" R="0"/>
|
||||
<Visible>false</Visible>
|
||||
</c:Model>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="0.5"/>
|
||||
<Scale X="32" Y="23" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="ScoreBoard_Blue">
|
||||
<Components>
|
||||
<c:Team>
|
||||
<Team>
|
||||
<Blue/>
|
||||
</Team>
|
||||
</c:Team>
|
||||
<c:ScoreScreen>
|
||||
<Offset X="0" Y="-3" Z="0"/>
|
||||
</c:ScoreScreen>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="7" Z="1.5"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="IDText">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>ID</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Left/>
|
||||
</Alignment>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="-13" Y="2.5" Z="0"/>
|
||||
<Scale X="2" Y="2" Z="2"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="NameText">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>Name</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Left/>
|
||||
</Alignment>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="-10" Y="2.5" Z="0"/>
|
||||
<Scale X="2" Y="2" Z="2"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="KDText">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>KD</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Left/>
|
||||
</Alignment>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="1.28838646" Y="2.5" Z="0"/>
|
||||
<Scale X="2" Y="2" Z="2"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="KillsText">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>Kills</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Left/>
|
||||
</Alignment>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="4.6874299" Y="2.5" Z="0"/>
|
||||
<Scale X="2" Y="2" Z="2"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="DeathsText">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>Deaths</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Left/>
|
||||
</Alignment>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="8.9577198" Y="2.5" Z="0"/>
|
||||
<Scale X="2" Y="2" Z="2"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="ScoreBoard_Spectators">
|
||||
<Components>
|
||||
@@ -308,98 +70,6 @@
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="EndScreen">
|
||||
<Components>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="EndScreen_Origin">
|
||||
<Components>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="3.10000014" Z="42.9360008"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="Camera">
|
||||
<Components>
|
||||
<c:Camera/>
|
||||
<c:EndScreen/>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="Sprite_Origin">
|
||||
<Components>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0.65200001" Z="-1.72800004"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="SpriteRed">
|
||||
<Components>
|
||||
<c:Sprite>
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||
<BlurBackground>true</BlurBackground>
|
||||
<Color A="0.588235319" B="0" G="0" R="0.588235319"/>
|
||||
<Visible>false</Visible>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Scale X="1.30000007" Y="0.300000012" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="SpriteBlue">
|
||||
<Components>
|
||||
<c:Sprite>
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||
<BlurBackground>true</BlurBackground>
|
||||
<Color A="0.588235319" B="0.588235319" G="0" R="0"/>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Scale X="1.30000007" Y="0.300000012" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="TextBlue">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>Blue team win!</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Visible>false</Visible>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="-0.0670000017" Z="0.0299999993"/>
|
||||
<Scale X="0.150000006" Y="0.150000006" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="TextRed">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>Red team win!</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="-0.0670000017" Z="0.0299999993"/>
|
||||
<Scale X="0.150000006" Y="0.150000006" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
|
||||
</Entity>
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
<Entity name="SidearmWeapon" xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../Types/Entity.xsd">
|
||||
|
||||
<Components>
|
||||
<c:Shielded/>
|
||||
<c:Model>
|
||||
<Resource>Models/Weapons/Blue/SecondaryWeaponBlue.mesh</Resource>
|
||||
</c:Model>
|
||||
@@ -10,37 +9,16 @@
|
||||
</Components>
|
||||
|
||||
<Children>
|
||||
<Entity name="Muzzle">
|
||||
<Entity name="WeaponMuzzle">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/RayBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="-0.0169804785" Y="-0.0188358482" Z="-0.222064406"/>
|
||||
<Position X="0.0123999491" Y="0.102453232" Z="-0.273824364"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="WeaponMuzzleRay">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/RaySideArmBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0.125075191" Z="-0.206788138"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="WeaponMuzzleFlash">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/MuzzleFlashSideArmBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0.0240342002" Y="0.116005458" Z="-0.0419839472"/>
|
||||
<Scale X="0.5" Y="0.5" Z="0.5"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
|
||||
|
||||
@@ -11,6 +11,17 @@
|
||||
</Components>
|
||||
|
||||
<Children>
|
||||
<Entity name="WeaponMuzzle">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/Ray2Red.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0.105000004" Z="-0.256000012"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="AmmunitionHUD">
|
||||
<Components>
|
||||
<c:TextFieldReader>
|
||||
@@ -27,9 +38,8 @@
|
||||
<Entity name="AmmunitionHUDBackground">
|
||||
<Components>
|
||||
<c:Sprite>
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
||||
<GlowMap></GlowMap>
|
||||
<Color A="0.588235319" B="0" G="0" R="0"/>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
@@ -46,16 +56,16 @@
|
||||
<Children>
|
||||
<Entity name="MagazineAmmo">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>16</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Color A="1" B="3.92156863" G="1.17647064" R="0"/>
|
||||
</c:Text>
|
||||
<c:TextFieldReader>
|
||||
<ParentEntityName>Player</ParentEntityName>
|
||||
<ComponentType>SidearmWeapon</ComponentType>
|
||||
<Field>MagazineAmmo</Field>
|
||||
</c:TextFieldReader>
|
||||
<c:Text>
|
||||
<Content>16</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Color A="1" B="3.92156863" G="1.17647064" R="0"/>
|
||||
</c:Text>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="-0.00600000005" Z="0"/>
|
||||
<Scale X="0.0599999987" Y="0.0599999987" Z="0.0599999987"/>
|
||||
@@ -82,37 +92,6 @@
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
<Entity name="Muzzle">
|
||||
<Components>
|
||||
<c:Transform>
|
||||
<Position X="0.197295129" Y="-0.116625182" Z="-0.709192753"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="WeaponMuzzleRay">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/RaySideArmBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="-0.155046776"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="WeaponMuzzleFlash">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/MuzzleFlashSideArmBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Scale X="0.5" Y="0.5" Z="0.5"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
|
||||
</Entity>
|
||||
|
||||
+3746
-3769
File diff suppressed because it is too large
Load Diff
@@ -34,7 +34,7 @@
|
||||
<Axis X="0" Y="1" Z="0"/>
|
||||
</c:RaptorCopter>
|
||||
<c:Transform>
|
||||
<Orientation X="0" Y="214.830872" Z="0"/>
|
||||
<Orientation X="0" Y="98.9142075" Z="0"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
@@ -46,7 +46,7 @@
|
||||
</c:RaptorCopter>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="26" Z="40"/>
|
||||
<Orientation X="0" Y="-346.565979" Z="0"/>
|
||||
<Orientation X="0" Y="-114.726761" Z="0"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
@@ -92,6 +92,42 @@
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="ButtonCorner_Origin">
|
||||
<Components>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="TopRight">
|
||||
<Components>
|
||||
<c:Sprite>
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/HUD/ButtonCorner_16.png</DiffuseTexture>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0970000029" Y="0.0220000017" Z="0.00499999989"/>
|
||||
<Scale X="0.00499999989" Y="0.00499999989" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="BottomRight">
|
||||
<Components>
|
||||
<c:Sprite>
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/HUD/ButtonCorner_16.png</DiffuseTexture>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0970000029" Y="-0.0219999999" Z="0.00499999989"/>
|
||||
<Orientation X="0" Y="0" Z="4.71199989"/>
|
||||
<Scale X="0.00499999989" Y="0.00499999989" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
<Entity name="Button_1">
|
||||
<Components>
|
||||
<c:Button/>
|
||||
@@ -113,44 +149,6 @@
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="ButtonCorner_Origin">
|
||||
<Components>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="BottomRight">
|
||||
<Components>
|
||||
<c:Sprite>
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/HUD/ButtonCorner_16.png</DiffuseTexture>
|
||||
<Linear>false</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0970000029" Y="-0.0219999999" Z="0.00499999989"/>
|
||||
<Orientation X="0" Y="0" Z="4.71199989"/>
|
||||
<Scale X="0.00499999989" Y="0.00499999989" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="TopRight">
|
||||
<Components>
|
||||
<c:Sprite>
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/HUD/ButtonCorner_16.png</DiffuseTexture>
|
||||
<Linear>false</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0970000029" Y="0.0220000017" Z="0.00499999989"/>
|
||||
<Scale X="0.00499999989" Y="0.00499999989" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
<Entity name="Text">
|
||||
<Components>
|
||||
<c:Text>
|
||||
@@ -220,7 +218,6 @@
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/HUD/ButtonCorner_16.png</DiffuseTexture>
|
||||
<Linear>false</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0970000029" Y="-0.0219999999" Z="0.00499999989"/>
|
||||
@@ -236,7 +233,6 @@
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/HUD/ButtonCorner_16.png</DiffuseTexture>
|
||||
<Linear>false</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0970000029" Y="0.0220000017" Z="0.00499999989"/>
|
||||
@@ -267,7 +263,6 @@
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/HUD/ButtonCorner_16.png</DiffuseTexture>
|
||||
<Linear>false</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0970000029" Y="0.0220000017" Z="0.00499999989"/>
|
||||
@@ -282,7 +277,6 @@
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/HUD/ButtonCorner_16.png</DiffuseTexture>
|
||||
<Linear>false</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0970000029" Y="-0.0219999999" Z="0.00499999989"/>
|
||||
@@ -305,10 +299,6 @@
|
||||
<BlurBackground>true</BlurBackground>
|
||||
<Color A="0.392156869" B="0" G="0" R="0"/>
|
||||
</c:Sprite>
|
||||
<c:InputCmdButton>
|
||||
<Command>Options</Command>
|
||||
<PressValue>1</PressValue>
|
||||
</c:InputCmdButton>
|
||||
<c:Transform>
|
||||
<Scale X="0.200000003" Y="0.0500000007" Z="1"/>
|
||||
</c:Transform>
|
||||
@@ -318,7 +308,7 @@
|
||||
<Entity name="Text">
|
||||
<Components>
|
||||
<c:Text>
|
||||
<Content>Options</Content>
|
||||
<Content>Option</Content>
|
||||
<Resource>Fonts/DroidSans.ttf,64</Resource>
|
||||
<Alignment>
|
||||
<Right/>
|
||||
@@ -384,7 +374,6 @@
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/HUD/ButtonCorner_16.png</DiffuseTexture>
|
||||
<Linear>false</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0970000029" Y="-0.0219999999" Z="0.00499999989"/>
|
||||
@@ -400,7 +389,6 @@
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/HUD/ButtonCorner_16.png</DiffuseTexture>
|
||||
<Linear>false</Linear>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0970000029" Y="0.0220000017" Z="0.00499999989"/>
|
||||
@@ -431,36 +419,12 @@
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="OptionsSpawner">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/OptionMenu.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
<Entity name="TitleSprite">
|
||||
<Components>
|
||||
<c:Sprite>
|
||||
<Model>Models/Core/UnitQuad.mesh</Model>
|
||||
<GlowMap></GlowMap>
|
||||
<DiffuseTexture>Textures/Test/SmallDiff.png</DiffuseTexture>
|
||||
<ClampToBorder>true</ClampToBorder>
|
||||
</c:Sprite>
|
||||
<c:Transform>
|
||||
<Position X="0.0320000015" Y="0.0220000017" Z="-0.0550000034"/>
|
||||
<Scale X="0.0500000007" Y="0.0150000006" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
</c:BlendAdditive>
|
||||
<c:Model>
|
||||
<Resource>Models/Characters/Assault/FirstPersonAssaultBlue.mesh</Resource>
|
||||
<Shadow>false</Shadow>
|
||||
</c:Model>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
@@ -91,10 +90,9 @@
|
||||
<c:Model>
|
||||
<GlowIntensity>1.5</GlowIntensity>
|
||||
<Resource>Models/Weapons/Blue/AssaultWeaponBlue.mesh</Resource>
|
||||
<Shadow>false</Shadow>
|
||||
</c:Model>
|
||||
<c:Transform>
|
||||
<Position X="0.120748267" Y="-0.22843127" Z="-0.181454599"/>
|
||||
<Position X="0.120748267" Y="-0.22843127" Z="-0.181454584"/>
|
||||
<Orientation X="0.0102799674" Y="-0.00312504289" Z="0.0428140014"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
@@ -133,7 +131,7 @@
|
||||
<EntityFile>Schema/Entities/RayAssaultBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0.00179657922" Y="-0.00304772682" Z="-0.334699303"/>
|
||||
<Position X="0.00123506912" Y="-0.00209517847" Z="-0.681198895"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
<Entity name="AssaultWeapon" xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../Types/Entity.xsd">
|
||||
|
||||
<Components>
|
||||
<c:Shielded/>
|
||||
<c:Model>
|
||||
<Resource>Models/Weapons/Blue/AssaultWeaponBlue.mesh</Resource>
|
||||
</c:Model>
|
||||
@@ -10,6 +9,17 @@
|
||||
</Components>
|
||||
|
||||
<Children>
|
||||
<Entity name="WeaponMuzzle">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/RayBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0.00644115033" Y="0.096679531" Z="-0.436609417"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="ReloadSpawner">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
@@ -19,38 +29,6 @@
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="Muzzle">
|
||||
<Components>
|
||||
<c:Transform>
|
||||
<Position X="0.00728808995" Y="0.0896582007" Z="-0.643795013"/>
|
||||
<Orientation X="6.27600002" Y="0.00499999989" Z="0.00600000005"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="WeaponMuzzleFlash">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/MuzzleFlashBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="-8.41593719e-05" Y="-0.000816107844" Z="0.0612007342"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="WeaponMuzzleRay">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/RayAssaultBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0.00179657922" Y="-0.00304772682" Z="-0.334699303"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
|
||||
</Entity>
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
</c:BlendAdditive>
|
||||
<c:Model>
|
||||
<Resource>Models/Characters/Defender/FirstPersonDefenderBlue.mesh</Resource>
|
||||
<Shadow>false</Shadow>
|
||||
</c:Model>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
@@ -155,7 +154,7 @@
|
||||
<InheritScale>true</InheritScale>
|
||||
</c:BoneAttachment>
|
||||
<c:Transform>
|
||||
<Position X="0.0540262833" Y="-0.0954347998" Z="-0.225546926"/>
|
||||
<Position X="0.0540262833" Y="-0.0954347998" Z="-0.225546911"/>
|
||||
<Orientation X="0.00124507793" Y="0.077417776" Z="0.00737103401"/>
|
||||
<Scale X="0.300000012" Y="0.300000042" Z="0.299999952"/>
|
||||
</c:Transform>
|
||||
@@ -245,10 +244,9 @@
|
||||
</c:BoneAttachment>
|
||||
<c:Model>
|
||||
<Resource>Models/Weapons/Blue/DefenderWeaponBlue.mesh</Resource>
|
||||
<Shadow>false</Shadow>
|
||||
</c:Model>
|
||||
<c:Transform>
|
||||
<Position X="0.120748043" Y="-0.228436321" Z="-0.151475564"/>
|
||||
<Position X="0.120748043" Y="-0.228436321" Z="-0.151475549"/>
|
||||
<Orientation X="0.0102800643" Y="-0.00312487315" Z="0.0428144038"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
@@ -267,7 +265,7 @@
|
||||
<Entity name="Muzzle">
|
||||
<Components>
|
||||
<c:Transform>
|
||||
<Position X="0.119734153" Y="-0.145251781" Z="-0.564532101"/>
|
||||
<Position X="0.137428522" Y="-0.145251781" Z="-0.590083241"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
@@ -277,7 +275,7 @@
|
||||
<EntityFile>Schema/Entities/RayDefenderBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="-0.109966502"/>
|
||||
<Position X="0.0180841181" Y="0.0252480619" Z="-0.663679719"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
@@ -288,7 +286,7 @@
|
||||
<EntityFile>Schema/Entities/MuzzleFlashBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0.0201820824" Y="0" Z="0"/>
|
||||
<Position X="0.0201820824" Y="0.0212024488" Z="-0.0305794869"/>
|
||||
<Scale X="1.5" Y="1.5" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
<Entity name="ThirdPersonWeaponModel" xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../Types/Entity.xsd">
|
||||
|
||||
<Components>
|
||||
<c:Shielded/>
|
||||
<c:Model>
|
||||
<Resource>Models/Weapons/Blue/DefenderWeaponBlue.mesh</Resource>
|
||||
</c:Model>
|
||||
@@ -10,6 +9,17 @@
|
||||
</Components>
|
||||
|
||||
<Children>
|
||||
<Entity name="WeaponMuzzle">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/DefenderRayBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0.000284185546" Y="0.0318552479" Z="-0.193328083"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="ThirdPersonReloadSpawner">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
@@ -19,38 +29,6 @@
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="Muzzle">
|
||||
<Components>
|
||||
<c:Transform>
|
||||
<Position X="-0.0100463303" Y="0.0624945536" Z="-0.372351319"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="WeaponMuzzleRay">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/RayDefenderBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0.0180841181" Y="0.0252480619" Z="-0.135249734"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="WeaponMuzzleFlash">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/MuzzleFlashBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0.0201820824" Y="0.0212024488" Z="-0.0305794869"/>
|
||||
<Scale X="1.5" Y="1.5" Z="1"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
|
||||
</Entity>
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
</c:BlendAdditive>
|
||||
<c:Model>
|
||||
<Resource>Models/Characters/Assault/FirstPersonAssaultBlue.mesh</Resource>
|
||||
<Shadow>false</Shadow>
|
||||
</c:Model>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
@@ -184,7 +183,6 @@
|
||||
<c:Model>
|
||||
<GlowIntensity>1.2999999523162842</GlowIntensity>
|
||||
<Resource>Models/Weapons/Blue/SecondaryWeaponBlue.mesh</Resource>
|
||||
<Shadow>false</Shadow>
|
||||
</c:Model>
|
||||
<c:Transform>
|
||||
<Position X="0.185786247" Y="-0.21622014" Z="-0.412707269"/>
|
||||
@@ -206,7 +204,7 @@
|
||||
<Entity name="Muzzle">
|
||||
<Components>
|
||||
<c:Transform>
|
||||
<Position X="0.189540595" Y="-0.114737265" Z="-0.681462705"/>
|
||||
<Position X="0.197295129" Y="-0.116625182" Z="-0.709192753"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
@@ -215,7 +213,9 @@
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/RaySideArmBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform/>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="-0.155046776"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
</c:BlendAdditive>
|
||||
<c:Model>
|
||||
<Resource>Models/Characters/Defender/FirstPersonDefenderBlue.mesh</Resource>
|
||||
<Shadow>false</Shadow>
|
||||
</c:Model>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
@@ -87,7 +86,7 @@
|
||||
<BoneName>R_Ammo_Joint</BoneName>
|
||||
</c:BoneAttachment>
|
||||
<c:Transform>
|
||||
<Position X="0.109812573" Y="-0.0832190216" Z="-0.373473227"/>
|
||||
<Position X="0.109812573" Y="-0.0832190216" Z="-0.373473197"/>
|
||||
<Orientation X="0.00118373742" Y="0.077411525" Z="0.00458352407"/>
|
||||
<Scale X="0.400000006" Y="0.400000006" Z="0.400000006"/>
|
||||
</c:Transform>
|
||||
@@ -184,10 +183,9 @@
|
||||
<c:Model>
|
||||
<GlowIntensity>1.5</GlowIntensity>
|
||||
<Resource>Models/Weapons/Blue/SecondaryWeaponBlue.mesh</Resource>
|
||||
<Shadow>false</Shadow>
|
||||
</c:Model>
|
||||
<c:Transform>
|
||||
<Position X="0.18578662" Y="-0.216220587" Z="-0.382728726"/>
|
||||
<Position X="0.18578662" Y="-0.216220587" Z="-0.382728696"/>
|
||||
<Orientation X="0.010279973" Y="-0.00312555139" Z="0.0428142436"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
@@ -206,19 +204,10 @@
|
||||
<Entity name="Muzzle">
|
||||
<Components>
|
||||
<c:Transform>
|
||||
<Position X="0.192775041" Y="-0.117133088" Z="-0.647809923"/>
|
||||
<Position X="0.196999997" Y="-0.116999999" Z="-0.668634355"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children>
|
||||
<Entity name="WeaponMuzzleRay">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/RaySideArmBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform/>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="WeaponMuzzleFlash">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
@@ -230,6 +219,17 @@
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
<Entity name="WeaponMuzzleRay">
|
||||
<Components>
|
||||
<c:Spawner>
|
||||
<EntityFile>Schema/Entities/RaySideArmBlue.xml</EntityFile>
|
||||
</c:Spawner>
|
||||
<c:Transform>
|
||||
<Position X="0" Y="0" Z="-0.155000001"/>
|
||||
</c:Transform>
|
||||
</Components>
|
||||
<Children/>
|
||||
</Entity>
|
||||
</Children>
|
||||
</Entity>
|
||||
</Children>
|
||||
|
||||
@@ -24,14 +24,14 @@ void FadeSystem::UpdateComponent(EntityWrapper& entity, ComponentWrapper& cFade,
|
||||
currentTime += dTime;
|
||||
|
||||
if(currentTime > fadeTime) {
|
||||
currentTime = 0.0 + fadeTime * (bool)cFade["Loop"];
|
||||
currentTime = 0.0;
|
||||
if ((bool)cFade["Reverse"]) {
|
||||
(Field<bool>)cFade["Out"] = !(bool)cFade["Out"];
|
||||
currentTime = fadeTime;
|
||||
}
|
||||
}
|
||||
if(currentTime < 0.0) {
|
||||
currentTime = fadeTime * (bool)cFade["Loop"];
|
||||
currentTime = fadeTime;
|
||||
if ((bool)cFade["Reverse"]) {
|
||||
(Field<bool>)cFade["Out"] = !(bool)cFade["Out"];
|
||||
currentTime = 0.0;
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
PlayerMovementSystem::PlayerMovementSystem(SystemParams params)
|
||||
: System(params)
|
||||
, m_SprintEffectTimer(0.f)
|
||||
, m_DashEffectTimer(0.f)
|
||||
{
|
||||
EVENT_SUBSCRIBE_MEMBER(m_EPlayerSpawned, &PlayerMovementSystem::OnPlayerSpawned);
|
||||
EVENT_SUBSCRIBE_MEMBER(m_EDoubleJump, &PlayerMovementSystem::OnDoubleJump);
|
||||
@@ -25,57 +24,23 @@ void PlayerMovementSystem::Update(double dt)
|
||||
if (LocalPlayer.Valid()){
|
||||
updateVelocity(LocalPlayer, dt);
|
||||
}
|
||||
//m_SprintEffectTimer += dt;
|
||||
//if (m_SprintEffectTimer < 0.016f) {
|
||||
// return;
|
||||
//}
|
||||
//m_SprintEffectTimer = 0.f;
|
||||
//auto pool = m_World->GetComponents("SprintAbility");
|
||||
//if (pool == nullptr) {
|
||||
// return;
|
||||
//}
|
||||
//for (auto cSprint : *pool) {
|
||||
// if (cSprint.EntityID != LocalPlayer.ID && (bool)cSprint["Active"]) {
|
||||
// // Spawn one afterimage for each player that sprints.
|
||||
// EntityWrapper player(m_World, cSprint.EntityID);
|
||||
// auto entityFile = ResourceManager::Load<EntityFile>("Schema/Entities/SprintEffect.xml");
|
||||
// EntityWrapper sprintEffect = entityFile->MergeInto(m_World);
|
||||
// auto playerModel = player.FirstChildByName("PlayerModel");
|
||||
// if (!playerModel.Valid()) {
|
||||
// continue;
|
||||
// }
|
||||
// if (!playerModel.HasComponent("Model")) {
|
||||
// continue;
|
||||
// }
|
||||
// if (!playerModel.HasComponent("Animation")) {
|
||||
// continue;
|
||||
// }
|
||||
// auto playerEntityModel = playerModel["Model"];
|
||||
// auto playerEntityAnimation = playerModel["Animation"];
|
||||
// playerEntityModel.Copy(sprintEffect["Model"]);
|
||||
// playerEntityAnimation.Copy(sprintEffect["Animation"]);
|
||||
// sprintEffect["ExplosionEffect"]["EndColor"] = (glm::vec4)playerEntityModel["Color"];
|
||||
// ((Field<glm::vec4>)sprintEffect["ExplosionEffect"]["EndColor"]).w(0.f);
|
||||
// sprintEffect["Animation"]["Speed1"] = 0.0;
|
||||
// sprintEffect["Animation"]["Speed2"] = 0.0;
|
||||
// sprintEffect["Animation"]["Speed3"] = 0.0;
|
||||
// sprintEffect["Transform"]["Position"] = (glm::vec3)player["Transform"]["Position"];
|
||||
// sprintEffect["Transform"]["Orientation"] = (glm::vec3)player["Transform"]["Orientation"];
|
||||
// }
|
||||
//}
|
||||
m_DashEffectTimer += dt;
|
||||
if (m_DashEffectTimer < 0.075f) {
|
||||
|
||||
|
||||
m_SprintEffectTimer += dt;
|
||||
if (m_SprintEffectTimer < 0.016f) {
|
||||
return;
|
||||
}
|
||||
m_DashEffectTimer = 0.f;
|
||||
auto pool = m_World->GetComponents("DashAbility");
|
||||
m_SprintEffectTimer = 0.f;
|
||||
auto pool = m_World->GetComponents("SprintAbility");
|
||||
if (pool == nullptr) {
|
||||
return;
|
||||
}
|
||||
for (auto cDash : *pool) {
|
||||
if (cDash.EntityID != LocalPlayer.ID && (double)cDash["CoolDownMaxTimer"] - (double)cDash["CoolDownTimer"] < 0.5) {
|
||||
// Spawn one afterimage for each player that Dashes.
|
||||
EntityWrapper player(m_World, cDash.EntityID);
|
||||
for (auto cSprint : *pool) {
|
||||
if (cSprint.EntityID != LocalPlayer.ID && (bool)cSprint["Active"]) {
|
||||
// Spawn one afterimage for each player that sprints.
|
||||
EntityWrapper player(m_World, cSprint.EntityID);
|
||||
auto entityFile = ResourceManager::Load<EntityFile>("Schema/Entities/SprintEffect.xml");
|
||||
EntityWrapper sprintEffect = entityFile->MergeInto(m_World);
|
||||
auto playerModel = player.FirstChildByName("PlayerModel");
|
||||
if (!playerModel.Valid()) {
|
||||
continue;
|
||||
@@ -83,28 +48,20 @@ void PlayerMovementSystem::Update(double dt)
|
||||
if (!playerModel.HasComponent("Model")) {
|
||||
continue;
|
||||
}
|
||||
EntityWrapper dashEffect = playerModel.Clone();
|
||||
for (auto& cAnim : dashEffect.ChildrenWithComponent("Animation")) {
|
||||
cAnim["Animation"]["Play"] = false;
|
||||
if (!playerModel.HasComponent("Animation")) {
|
||||
continue;
|
||||
}
|
||||
const double fadeTime = 0.5f;
|
||||
for (auto& cModel : dashEffect.ChildrenWithComponent("Model")) {
|
||||
EntityWrapper e(m_World, cModel.ID);
|
||||
e.AttachComponent("Lifetime");
|
||||
e.AttachComponent("Fade");
|
||||
e["Fade"]["Loop"] = false;
|
||||
e["Fade"]["FadeTime"] = fadeTime;
|
||||
e["Fade"]["Time"] = fadeTime;
|
||||
e["Lifetime"]["Lifetime"] = fadeTime;
|
||||
}
|
||||
dashEffect.AttachComponent("Lifetime");
|
||||
dashEffect.AttachComponent("Fade");
|
||||
dashEffect["Fade"]["Loop"] = false;
|
||||
dashEffect["Fade"]["FadeTime"] = fadeTime;
|
||||
dashEffect["Fade"]["Time"] = fadeTime;
|
||||
dashEffect["Lifetime"]["Lifetime"] = fadeTime;
|
||||
dashEffect["Transform"]["Position"] = (glm::vec3)player["Transform"]["Position"];
|
||||
dashEffect["Transform"]["Orientation"] = (glm::vec3)player["Transform"]["Orientation"];
|
||||
auto playerEntityModel = playerModel["Model"];
|
||||
auto playerEntityAnimation = playerModel["Animation"];
|
||||
playerEntityModel.Copy(sprintEffect["Model"]);
|
||||
playerEntityAnimation.Copy(sprintEffect["Animation"]);
|
||||
sprintEffect["ExplosionEffect"]["EndColor"] = (glm::vec4)playerEntityModel["Color"];
|
||||
((Field<glm::vec4>)sprintEffect["ExplosionEffect"]["EndColor"]).w(0.f);
|
||||
sprintEffect["Animation"]["Speed1"] = 0.0;
|
||||
sprintEffect["Animation"]["Speed2"] = 0.0;
|
||||
sprintEffect["Animation"]["Speed3"] = 0.0;
|
||||
sprintEffect["Transform"]["Position"] = (glm::vec3)player["Transform"]["Position"];
|
||||
sprintEffect["Transform"]["Orientation"] = (glm::vec3)player["Transform"]["Orientation"];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,7 +14,19 @@ void AssaultWeaponBehaviour::UpdateWeapon(ComponentWrapper cWeapon, WeaponInfo&
|
||||
// Start reloading automatically if at 0 mag ammo
|
||||
Field<int> magAmmo = cWeapon["MagazineAmmo"];
|
||||
if (m_ConfigAutoReload && magAmmo <= 0) {
|
||||
OnReload(cWeapon, wi);
|
||||
//OnReload(cWeapon, wi);
|
||||
// Send an input command instead of reloading immediately so the server
|
||||
// has a chance to catch up.
|
||||
if (IsClient) {
|
||||
Events::InputCommand e;
|
||||
e.Player = wi.Player;
|
||||
e.PlayerID = -1;
|
||||
e.Command = "Reload";
|
||||
e.Value = 1;
|
||||
m_EventBroker->Publish(e);
|
||||
e.Value = 0;
|
||||
m_EventBroker->Publish(e);
|
||||
}
|
||||
}
|
||||
|
||||
// Only start reloading once we're done firing
|
||||
@@ -235,8 +247,7 @@ void AssaultWeaponBehaviour::fireBullet(ComponentWrapper cWeapon, WeaponInfo& wi
|
||||
float distance = traceRayDistance(origin, direction);
|
||||
EntityWrapper ray = SpawnerSystem::Spawn(tracerSpawner, tracerSpawner);
|
||||
if (ray.Valid()) {
|
||||
((Field<glm::vec3>)ray["Transform"]["Scale"]).x(distance);
|
||||
((Field<glm::vec3>)ray["Transform"]["Position"]).z(-distance/2.f);
|
||||
((Field<glm::vec3>)ray["Transform"]["Scale"]).z(distance);
|
||||
}
|
||||
}
|
||||
//MuzzleFlash
|
||||
|
||||
@@ -324,23 +324,23 @@ void DefenderWeaponBehaviour::fireShell(ComponentWrapper cWeapon, WeaponInfo& wi
|
||||
spawnTracers(cWeapon, wi, pattern);
|
||||
|
||||
// View punch
|
||||
if (IsClient) {
|
||||
EntityWrapper camera = wi.Player.FirstChildByName("Camera");
|
||||
if (camera.Valid()) {
|
||||
Field<glm::vec3> cameraOrientation = camera["Transform"]["Orientation"];
|
||||
float viewPunch = cWeapon["ViewPunch"];
|
||||
float maxTravelAngle = (const float&)cWeapon["MaxTravelAngle"];
|
||||
Field<float> currentTravel = cWeapon["CurrentTravel"];
|
||||
if (currentTravel < maxTravelAngle) {
|
||||
float change = viewPunch;
|
||||
if (currentTravel + change > maxTravelAngle) {
|
||||
change = maxTravelAngle - currentTravel;
|
||||
}
|
||||
cameraOrientation.x(cameraOrientation.x() + change);
|
||||
currentTravel += change;
|
||||
}
|
||||
}
|
||||
}
|
||||
//if (IsClient) {
|
||||
// EntityWrapper camera = wi.Player.FirstChildByName("Camera");
|
||||
// if (camera.Valid()) {
|
||||
// glm::vec3& cameraOrientation = camera["Transform"]["Orientation"];
|
||||
// float viewPunch = cWeapon["ViewPunch"];
|
||||
// float maxTravelAngle = cWeapon["MaxTravelAngle"];
|
||||
// float& currentTravel = cWeapon["CurrentTravel"];
|
||||
// if (currentTravel < maxTravelAngle) {
|
||||
// float change = viewPunch;
|
||||
// if (currentTravel + change > maxTravelAngle) {
|
||||
// change = maxTravelAngle - currentTravel;
|
||||
// }
|
||||
// cameraOrientation.x += change;
|
||||
// currentTravel += change;
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
|
||||
// Play animation
|
||||
playAnimationAndReturn(wi.FirstPersonEntity, "FinalBlend", "Fire");
|
||||
@@ -395,12 +395,9 @@ void DefenderWeaponBehaviour::spawnTracers(ComponentWrapper cWeapon, WeaponInfo&
|
||||
glm::vec3 muzzlePosition = TransformSystem::AbsolutePosition(muzzle);
|
||||
glm::quat muzzleOrientation = TransformSystem::AbsoluteOrientation(muzzle);
|
||||
|
||||
rayOrigin = muzzlePosition;
|
||||
|
||||
glm::vec3 muzzleToHit = hitPosition - muzzlePosition;
|
||||
|
||||
rayOrigin = muzzlePosition + (muzzleToHit/2.f);
|
||||
|
||||
|
||||
glm::vec3 lookVector = glm::normalize(-muzzleToHit);
|
||||
float pitch = std::asin(-lookVector.y);
|
||||
float yaw = std::atan2(lookVector.x, lookVector.z);
|
||||
@@ -462,8 +459,8 @@ void DefenderWeaponBehaviour::dealDamage(ComponentWrapper cWeapon, WeaponInfo& w
|
||||
}
|
||||
|
||||
// Temp hit decal
|
||||
// EntityWrapper hit = ResourceManager::Load<EntityFile>("Schema/Entities/HitTest.xml")->MergeInto(m_World);
|
||||
// (Field<glm::vec3>)hit["Transform"]["Position"] = pick.Position;
|
||||
EntityWrapper hit = ResourceManager::Load<EntityFile>("Schema/Entities/HitTest.xml")->MergeInto(m_World);
|
||||
(Field<glm::vec3>)hit["Transform"]["Position"] = pick.Position;
|
||||
|
||||
// Don't let us shoot ourselves in the foot somehow
|
||||
if (victim == LocalPlayer) {
|
||||
@@ -480,17 +477,12 @@ void DefenderWeaponBehaviour::dealDamage(ComponentWrapper cWeapon, WeaponInfo& w
|
||||
|
||||
// Check for friendly fire
|
||||
if ((ComponentInfo::EnumType)victim["Team"]["Team"] == (ComponentInfo::EnumType)wi.Player["Team"]["Team"]) {
|
||||
// Give boost
|
||||
Events::PlayerDamage ePlayerDamage;
|
||||
ePlayerDamage.Inflictor = wi.Player;
|
||||
ePlayerDamage.Victim = victim;
|
||||
ePlayerDamage.Damage = 0;
|
||||
m_EventBroker->Publish(ePlayerDamage);
|
||||
// TODO: Ammo sharing
|
||||
continue;
|
||||
}
|
||||
|
||||
damageSum[victim] += pelletDamage;
|
||||
// ((Field<glm::vec4>)hit["Model"]["Color"]).z(1.f);
|
||||
((Field<glm::vec4>)hit["Model"]["Color"]).z(1.f);
|
||||
}
|
||||
|
||||
// Deal damage!
|
||||
@@ -501,6 +493,7 @@ void DefenderWeaponBehaviour::dealDamage(ComponentWrapper cWeapon, WeaponInfo& w
|
||||
ePlayerDamage.Victim = kv.first;
|
||||
ePlayerDamage.Damage = kv.second;
|
||||
m_EventBroker->Publish(ePlayerDamage);
|
||||
LOG_DEBUG("Dealt %f damage to #%i", kv.second, kv.first.ID);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -69,21 +69,6 @@ void SidearmWeaponBehaviour::UpdateWeapon(ComponentWrapper cWeapon, WeaponInfo&
|
||||
}
|
||||
}
|
||||
|
||||
// Restore view angle
|
||||
if (IsClient) {
|
||||
Field<float> currentTravel = cWeapon["CurrentTravel"];
|
||||
Field<float> returnSpeed = cWeapon["ViewReturnSpeed"];
|
||||
if (currentTravel > 0) {
|
||||
float change = returnSpeed * dt;
|
||||
currentTravel = glm::max(0.f, currentTravel - change);
|
||||
EntityWrapper camera = wi.Player.FirstChildByName("Camera");
|
||||
if (camera.Valid()) {
|
||||
Field<glm::vec3> cameraOrientation = camera["Transform"]["Orientation"];
|
||||
cameraOrientation.x(cameraOrientation.x() - change);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ((bool)cWeapon["Automatic"] && canFire(cWeapon)) {
|
||||
fireBullet(cWeapon, wi);
|
||||
}
|
||||
@@ -198,41 +183,21 @@ void SidearmWeaponBehaviour::fireBullet(ComponentWrapper cWeapon, WeaponInfo& wi
|
||||
magAmmo -= 1;
|
||||
}
|
||||
|
||||
// View punch
|
||||
if (IsClient) {
|
||||
EntityWrapper camera = wi.Player.FirstChildByName("Camera");
|
||||
if (camera.Valid()) {
|
||||
Field<glm::vec3> cameraOrientation = camera["Transform"]["Orientation"];
|
||||
float viewPunch = cWeapon["ViewPunch"];
|
||||
float maxTravelAngle = cWeapon["MaxTravelAngle"];
|
||||
Field<float> currentTravel = cWeapon["CurrentTravel"];
|
||||
if (currentTravel < maxTravelAngle) {
|
||||
float change = viewPunch;
|
||||
if (currentTravel + change > maxTravelAngle) {
|
||||
change = maxTravelAngle - currentTravel;
|
||||
}
|
||||
cameraOrientation.x(cameraOrientation.x() + change);
|
||||
currentTravel += change;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Get weapon model based on current person
|
||||
EntityWrapper weaponModelEntity = getRelevantWeaponEntity(wi);
|
||||
if (!weaponModelEntity.Valid()) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Tracer
|
||||
//Tracer
|
||||
EntityWrapper tracerSpawner = weaponModelEntity.FirstChildByName("WeaponMuzzleRay");
|
||||
if (tracerSpawner.Valid()) {
|
||||
glm::vec3 origin = TransformSystem::AbsolutePosition(tracerSpawner);
|
||||
glm::vec3 direction = glm::quat(TransformSystem::AbsoluteOrientationEuler(tracerSpawner)) * glm::vec3(0, 0, -1);
|
||||
glm::vec3 direction = TransformSystem::AbsoluteOrientation(tracerSpawner) * glm::vec3(0, 0, -1);
|
||||
float distance = traceRayDistance(origin, direction);
|
||||
EntityWrapper ray = SpawnerSystem::Spawn(tracerSpawner, tracerSpawner);
|
||||
if (ray.Valid()) {
|
||||
((Field<glm::vec3>)ray["Transform"]["Scale"]).x(distance);
|
||||
((Field<glm::vec3>)ray["Transform"]["Position"]).z(-distance/2.f);
|
||||
((Field<glm::vec3>)ray["Transform"]["Scale"]).z(distance);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user