Merge remote-tracking branch 'origin/master' into DashAbiltyEffect
This commit is contained in:
+1
-1
Submodule assets updated: 10a611659d...72530423ad
@@ -13,7 +13,8 @@ struct Captured : Event
|
|||||||
{
|
{
|
||||||
int TeamNumberThatCapturedCapturePoint;
|
int TeamNumberThatCapturedCapturePoint;
|
||||||
EntityID CapturePointTakenID;
|
EntityID CapturePointTakenID;
|
||||||
EntityWrapper NextCapturePoint;
|
EntityWrapper BlueTeamNextCapturePoint;
|
||||||
|
EntityWrapper RedTeamNextCapturePoint;
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ public:
|
|||||||
void InitializeFrameBuffers();
|
void InitializeFrameBuffers();
|
||||||
void InitializeShaderPrograms();
|
void InitializeShaderPrograms();
|
||||||
|
|
||||||
void Draw(GLuint sceneTexture, GLuint bloomTexture, GLuint sceneTextureLowRes, GLuint bloomTextureLowRes, GLfloat gamma, GLfloat exposure);
|
void Draw(GLuint sceneTexture, GLuint bloomTexture, GLfloat gamma, GLfloat exposure);
|
||||||
private:
|
private:
|
||||||
const IRenderer* m_Renderer;
|
const IRenderer* m_Renderer;
|
||||||
|
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
class DrawFinalPass
|
class DrawFinalPass
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
DrawFinalPass(IRenderer* renderer, LightCullingPass* lightCullingPass, CubeMapPass* cubeMapPass, SSAOPass* ssaoPass, GLuint* depthBuffer);
|
DrawFinalPass(IRenderer* renderer, LightCullingPass* lightCullingPass, CubeMapPass* cubeMapPass, SSAOPass* ssaoPass);
|
||||||
~DrawFinalPass() { }
|
~DrawFinalPass() { }
|
||||||
void InitializeTextures();
|
void InitializeTextures();
|
||||||
void InitializeFrameBuffers();
|
void InitializeFrameBuffers();
|
||||||
@@ -26,20 +26,17 @@ public:
|
|||||||
|
|
||||||
//Return the texture that is used in later stages to apply the bloom effect
|
//Return the texture that is used in later stages to apply the bloom effect
|
||||||
GLuint BloomTexture() const { return m_BloomTexture; }
|
GLuint BloomTexture() const { return m_BloomTexture; }
|
||||||
GLuint BloomTextureLowRes() const { return m_BloomTextureLowRes; }
|
|
||||||
//Return the texture with diffuse and lighting of the scene.
|
//Return the texture with diffuse and lighting of the scene.
|
||||||
GLuint SceneTexture() const { return m_SceneTexture; }
|
GLuint SceneTexture() const { return m_SceneTexture; }
|
||||||
GLuint SceneTextureLowRes() const { return m_SceneTextureLowRes; }
|
|
||||||
//Return the framebuffer used in the scene rendering stage.
|
//Return the framebuffer used in the scene rendering stage.
|
||||||
FrameBuffer* FinalPassFrameBuffer() { return &m_FinalPassFrameBuffer; }
|
FrameBuffer* FinalPassFrameBuffer() { return &m_FinalPassFrameBuffer; }
|
||||||
FrameBuffer* FinalPassFrameBufferLowRes() { return &m_FinalPassFrameBufferLowRes; }
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void DrawSprites(std::list<std::shared_ptr<RenderJob>>&jobs, RenderScene& scene);
|
void DrawSprites(std::list<std::shared_ptr<RenderJob>>&jobs, RenderScene& scene);
|
||||||
void DrawModelRenderQueues(std::list<std::shared_ptr<RenderJob>>& jobs, RenderScene& scene);
|
void DrawModelRenderQueues(std::list<std::shared_ptr<RenderJob>>& jobs, RenderScene& scene);
|
||||||
void DrawShieldToStencilBuffer(std::list<std::shared_ptr<RenderJob>>& jobs, RenderScene& scene);
|
void DrawModelRenderQueuesWithShieldCheck(std::list<std::shared_ptr<RenderJob>>& jobs, RenderScene& scene);
|
||||||
void DrawShieldedModelRenderQueue(std::list<std::shared_ptr<RenderJob>>& jobs, RenderScene& scene);
|
void DrawShieldedModelRenderQueue(std::list<std::shared_ptr<RenderJob>>& jobs, RenderScene& scene);
|
||||||
void DrawToDepthBuffer(std::list<std::shared_ptr<RenderJob>>& jobs, RenderScene& scene);
|
void DrawToDepthStencilBuffer(std::list<std::shared_ptr<RenderJob>>& jobs, RenderScene& scene);
|
||||||
|
|
||||||
void BindExplosionUniforms(GLuint shaderHandle, std::shared_ptr<ExplosionEffectJob>& job, RenderScene& scene);
|
void BindExplosionUniforms(GLuint shaderHandle, std::shared_ptr<ExplosionEffectJob>& job, RenderScene& scene);
|
||||||
void BindModelUniforms(GLuint shaderHandle, std::shared_ptr<ModelJob>& job, RenderScene& scene);
|
void BindModelUniforms(GLuint shaderHandle, std::shared_ptr<ModelJob>& job, RenderScene& scene);
|
||||||
@@ -54,13 +51,11 @@ private:
|
|||||||
Texture* m_ErrorTexture;
|
Texture* m_ErrorTexture;
|
||||||
|
|
||||||
FrameBuffer m_FinalPassFrameBuffer;
|
FrameBuffer m_FinalPassFrameBuffer;
|
||||||
FrameBuffer m_FinalPassFrameBufferLowRes;
|
FrameBuffer m_ShieldDepthFrameBuffer;
|
||||||
GLuint m_BloomTexture;
|
GLuint m_BloomTexture;
|
||||||
GLuint m_SceneTexture;
|
GLuint m_SceneTexture;
|
||||||
GLuint m_BloomTextureLowRes;
|
GLuint m_DepthBuffer;
|
||||||
GLuint m_SceneTextureLowRes;
|
GLuint m_ShieldBuffer;
|
||||||
GLuint* m_DepthBuffer;
|
|
||||||
GLuint m_DepthBufferLowRes;
|
|
||||||
GLuint m_CubeMapTexture;
|
GLuint m_CubeMapTexture;
|
||||||
|
|
||||||
//maqke this component based i guess?
|
//maqke this component based i guess?
|
||||||
@@ -76,16 +71,27 @@ private:
|
|||||||
ShaderProgram* m_ExplosionEffectSplatMapProgram;
|
ShaderProgram* m_ExplosionEffectSplatMapProgram;
|
||||||
ShaderProgram* m_SpriteProgram;
|
ShaderProgram* m_SpriteProgram;
|
||||||
ShaderProgram* m_ForwardPlusSplatMapProgram;
|
ShaderProgram* m_ForwardPlusSplatMapProgram;
|
||||||
ShaderProgram* m_ShieldToStencilProgram;
|
ShaderProgram* m_FillDepthStencilBufferProgram;
|
||||||
ShaderProgram* m_FillDepthBufferProgram;
|
|
||||||
|
ShaderProgram* m_ForwardPlusShieldCheckProgram;
|
||||||
|
ShaderProgram* m_ExplosionEffectShieldCheckProgram;
|
||||||
|
ShaderProgram* m_ExplosionEffectSplatMapShieldCheckProgram;
|
||||||
|
ShaderProgram* m_SpriteShieldCheckProgram;
|
||||||
|
ShaderProgram* m_ForwardPlusSplatMapShieldCheckProgram;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
ShaderProgram* m_ForwardPlusSkinnedProgram;
|
ShaderProgram* m_ForwardPlusSkinnedProgram;
|
||||||
ShaderProgram* m_ExplosionEffectSkinnedProgram;
|
ShaderProgram* m_ExplosionEffectSkinnedProgram;
|
||||||
ShaderProgram* m_ExplosionEffectSplatMapSkinnedProgram;
|
ShaderProgram* m_ExplosionEffectSplatMapSkinnedProgram;
|
||||||
ShaderProgram* m_ForwardPlusSplatMapSkinnedProgram;
|
ShaderProgram* m_ForwardPlusSplatMapSkinnedProgram;
|
||||||
ShaderProgram* m_ShieldToStencilSkinnedProgram;
|
ShaderProgram* m_FillDepthStencilBufferSkinnedProgram;
|
||||||
ShaderProgram* m_FillDepthBufferSkinnedProgram;
|
|
||||||
|
ShaderProgram* m_ForwardPlusSkinnedShieldCheckProgram;
|
||||||
|
ShaderProgram* m_ExplosionEffectSkinnedShieldCheckProgram;
|
||||||
|
ShaderProgram* m_ExplosionEffectSplatMapSkinnedShieldCheckProgram;
|
||||||
|
ShaderProgram* m_ForwardPlusSplatMapSkinnedShieldCheckProgram;
|
||||||
|
ShaderProgram* m_FillDepthBufferSkinnedShieldCheckProgram;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
@@ -15,8 +15,8 @@
|
|||||||
|
|
||||||
struct ExplosionEffectJob : ModelJob
|
struct ExplosionEffectJob : ModelJob
|
||||||
{
|
{
|
||||||
ExplosionEffectJob(ComponentWrapper explosionEffectComponent, ::Model* model, Camera* camera, glm::mat4 matrix, ::RawModel::MaterialProperties matGroup, ComponentWrapper modelComponent, ::World* world, glm::vec4 fillColor, float fillPercentage)
|
ExplosionEffectJob(ComponentWrapper explosionEffectComponent, ::Model* model, Camera* camera, glm::mat4 matrix, ::RawModel::MaterialProperties matGroup, ComponentWrapper modelComponent, ::World* world, glm::vec4 fillColor, float fillPercentage, bool isShielded)
|
||||||
: ModelJob(model, camera, matrix, matGroup, modelComponent, world, fillColor, fillPercentage)
|
: ModelJob(model, camera, matrix, matGroup, modelComponent, world, fillColor, fillPercentage, isShielded)
|
||||||
{
|
{
|
||||||
ExplosionOrigin = (glm::vec3)explosionEffectComponent["ExplosionOrigin"];
|
ExplosionOrigin = (glm::vec3)explosionEffectComponent["ExplosionOrigin"];
|
||||||
TimeSinceDeath = (double)explosionEffectComponent["TimeSinceDeath"];
|
TimeSinceDeath = (double)explosionEffectComponent["TimeSinceDeath"];
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
|
|
||||||
struct ModelJob : RenderJob
|
struct ModelJob : RenderJob
|
||||||
{
|
{
|
||||||
ModelJob(Model* model, Camera* camera, glm::mat4 matrix, ::RawModel::MaterialProperties matProp, ComponentWrapper modelComponent, World* world, glm::vec4 fillColor, float fillPercentage)
|
ModelJob(Model* model, Camera* camera, glm::mat4 matrix, ::RawModel::MaterialProperties matProp, ComponentWrapper modelComponent, World* world, glm::vec4 fillColor, float fillPercentage, bool isShielded)
|
||||||
: RenderJob()
|
: RenderJob()
|
||||||
{
|
{
|
||||||
Model = model;
|
Model = model;
|
||||||
@@ -117,7 +117,7 @@ struct ModelJob : RenderJob
|
|||||||
|
|
||||||
FillColor = fillColor;
|
FillColor = fillColor;
|
||||||
FillPercentage = fillPercentage;
|
FillPercentage = fillPercentage;
|
||||||
|
IsShielded = isShielded;
|
||||||
|
|
||||||
if (model->IsSkinned()) {
|
if (model->IsSkinned()) {
|
||||||
Skeleton = Model->m_RawModel->m_Skeleton;
|
Skeleton = Model->m_RawModel->m_Skeleton;
|
||||||
@@ -181,7 +181,7 @@ struct ModelJob : RenderJob
|
|||||||
|
|
||||||
glm::vec4 FillColor = glm::vec4(0);
|
glm::vec4 FillColor = glm::vec4(0);
|
||||||
float FillPercentage = 0.0;
|
float FillPercentage = 0.0;
|
||||||
|
bool IsShielded;
|
||||||
void CalculateHash() override
|
void CalculateHash() override
|
||||||
{
|
{
|
||||||
Hash = ShaderID << 20 + ModelID << 10 + TextureID;
|
Hash = ShaderID << 20 + ModelID << 10 + TextureID;
|
||||||
|
|||||||
@@ -24,7 +24,6 @@ struct RenderScene
|
|||||||
std::list<std::shared_ptr<RenderJob>> OpaqueObjects;
|
std::list<std::shared_ptr<RenderJob>> OpaqueObjects;
|
||||||
std::list<std::shared_ptr<RenderJob>> TransparentObjects;
|
std::list<std::shared_ptr<RenderJob>> TransparentObjects;
|
||||||
std::list<std::shared_ptr<RenderJob>> OpaqueShieldedObjects;
|
std::list<std::shared_ptr<RenderJob>> OpaqueShieldedObjects;
|
||||||
std::list<std::shared_ptr<RenderJob>> TransparentShieldedObjects;
|
|
||||||
std::list<std::shared_ptr<RenderJob>> ShieldObjects;
|
std::list<std::shared_ptr<RenderJob>> ShieldObjects;
|
||||||
std::list<std::shared_ptr<RenderJob>> SpriteJob;
|
std::list<std::shared_ptr<RenderJob>> SpriteJob;
|
||||||
std::list<std::shared_ptr<RenderJob>> PointLight;
|
std::list<std::shared_ptr<RenderJob>> PointLight;
|
||||||
@@ -41,7 +40,6 @@ struct RenderScene
|
|||||||
Jobs.OpaqueObjects.clear();
|
Jobs.OpaqueObjects.clear();
|
||||||
Jobs.TransparentObjects.clear();
|
Jobs.TransparentObjects.clear();
|
||||||
Jobs.OpaqueShieldedObjects.clear();
|
Jobs.OpaqueShieldedObjects.clear();
|
||||||
Jobs.TransparentShieldedObjects.clear();
|
|
||||||
Jobs.ShieldObjects.clear();
|
Jobs.ShieldObjects.clear();
|
||||||
Jobs.SpriteJob.clear();
|
Jobs.SpriteJob.clear();
|
||||||
Jobs.DirectionalLight.clear();
|
Jobs.DirectionalLight.clear();
|
||||||
|
|||||||
@@ -20,6 +20,9 @@ public:
|
|||||||
private:
|
private:
|
||||||
EventRelay<AmmoPickupSystem, Events::TriggerTouch> m_ETriggerTouch;
|
EventRelay<AmmoPickupSystem, Events::TriggerTouch> m_ETriggerTouch;
|
||||||
bool OnTriggerTouch(Events::TriggerTouch& e);
|
bool OnTriggerTouch(Events::TriggerTouch& e);
|
||||||
|
EventRelay<AmmoPickupSystem, Events::TriggerLeave> m_ETriggerLeave;
|
||||||
|
bool OnTriggerLeave(Events::TriggerLeave& e);
|
||||||
|
|
||||||
EventRelay<AmmoPickupSystem, Events::AmmoPickup> m_EAmmoPickup;
|
EventRelay<AmmoPickupSystem, Events::AmmoPickup> m_EAmmoPickup;
|
||||||
bool OnAmmoPickup(Events::AmmoPickup& e);
|
bool OnAmmoPickup(Events::AmmoPickup& e);
|
||||||
|
|
||||||
@@ -31,5 +34,11 @@ private:
|
|||||||
EntityID parentID;
|
EntityID parentID;
|
||||||
};
|
};
|
||||||
std::vector<NewAmmoPickup> m_ETriggerTouchVector;
|
std::vector<NewAmmoPickup> m_ETriggerTouchVector;
|
||||||
|
struct EntityAtMaxValuePickupStruct {
|
||||||
|
EntityWrapper player;
|
||||||
|
EntityWrapper trigger;
|
||||||
|
};
|
||||||
|
std::vector<EntityAtMaxValuePickupStruct> m_PickupAtMaximum;
|
||||||
|
void DoPickup(EntityWrapper &player, EntityWrapper &trigger);
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -0,0 +1,21 @@
|
|||||||
|
#ifndef BoostSystem_h__
|
||||||
|
#define BoostSystem_h__
|
||||||
|
|
||||||
|
#include "Core/System.h"
|
||||||
|
#include "Core/ResourceManager.h"
|
||||||
|
#include "Core/EntityFileParser.h"
|
||||||
|
#include "Core/EPlayerDamage.h"
|
||||||
|
#include "Common.h"
|
||||||
|
|
||||||
|
class BoostSystem : public System
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
BoostSystem(SystemParams params);
|
||||||
|
|
||||||
|
private:
|
||||||
|
EventRelay<BoostSystem, Events::PlayerDamage> m_EPlayerDamage;
|
||||||
|
bool OnPlayerDamage(Events::PlayerDamage& e);
|
||||||
|
|
||||||
|
std::string DetermineClass(EntityWrapper player);
|
||||||
|
};
|
||||||
|
#endif
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
#ifndef CapturePointArrowHUDSystem_h__
|
||||||
|
#define CapturePointArrowHUDSystem_h__
|
||||||
|
|
||||||
|
#include <GLFW/glfw3.h>
|
||||||
|
#include <glm/common.hpp>
|
||||||
|
#include <glm/gtx/vector_angle.hpp>
|
||||||
|
|
||||||
|
#include "Common.h"
|
||||||
|
#include "Core/System.h"
|
||||||
|
#include "Core/Transform.h"
|
||||||
|
#include "Core/ECaptured.h"
|
||||||
|
|
||||||
|
|
||||||
|
class CapturePointArrowHUDSystem : public ImpureSystem
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
CapturePointArrowHUDSystem(SystemParams params);
|
||||||
|
|
||||||
|
virtual void Update(double dt) override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
EventRelay<CapturePointArrowHUDSystem, Events::Captured> m_ECapturedEvent;
|
||||||
|
bool OnCapturePointCaptured(Events::Captured& e);
|
||||||
|
|
||||||
|
bool m_InitialtargetsSet = false;
|
||||||
|
glm::vec3 m_RedTeamCurrentTarget;
|
||||||
|
glm::vec3 m_BlueTeamCurrentTarget;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif
|
||||||
@@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
#include "Common.h"
|
#include "Common.h"
|
||||||
#include "Core/System.h"
|
#include "Core/System.h"
|
||||||
#include "Engine/Collision/ETrigger.h"
|
#include "Collision/ETrigger.h"
|
||||||
|
|
||||||
class CapturePointHUDSystem : public ImpureSystem
|
class CapturePointHUDSystem : public ImpureSystem
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -9,7 +9,6 @@
|
|||||||
#include "Core/EPlayerHealthPickup.h"
|
#include "Core/EPlayerHealthPickup.h"
|
||||||
#include "Engine/Collision/ETrigger.h"
|
#include "Engine/Collision/ETrigger.h"
|
||||||
#include "Common.h"
|
#include "Common.h"
|
||||||
#include <tuple>
|
|
||||||
|
|
||||||
class PickupSpawnSystem : public ImpureSystem
|
class PickupSpawnSystem : public ImpureSystem
|
||||||
{
|
{
|
||||||
@@ -21,6 +20,8 @@ public:
|
|||||||
private:
|
private:
|
||||||
EventRelay<PickupSpawnSystem, Events::TriggerTouch> m_ETriggerTouch;
|
EventRelay<PickupSpawnSystem, Events::TriggerTouch> m_ETriggerTouch;
|
||||||
bool OnTriggerTouch(Events::TriggerTouch& e);
|
bool OnTriggerTouch(Events::TriggerTouch& e);
|
||||||
|
EventRelay<PickupSpawnSystem, Events::TriggerLeave> m_ETriggerLeave;
|
||||||
|
bool OnTriggerLeave(Events::TriggerLeave& e);
|
||||||
|
|
||||||
struct NewHealthPickup {
|
struct NewHealthPickup {
|
||||||
glm::vec3 Pos;
|
glm::vec3 Pos;
|
||||||
@@ -30,5 +31,11 @@ private:
|
|||||||
EntityID parentID;
|
EntityID parentID;
|
||||||
};
|
};
|
||||||
std::vector<NewHealthPickup> m_ETriggerTouchVector;
|
std::vector<NewHealthPickup> m_ETriggerTouchVector;
|
||||||
|
struct EntityAtMaxValuePickupStruct {
|
||||||
|
EntityWrapper player;
|
||||||
|
EntityWrapper trigger;
|
||||||
|
};
|
||||||
|
std::vector<EntityAtMaxValuePickupStruct> m_PickupAtMaximum;
|
||||||
|
void DoPickup(EntityWrapper &player, EntityWrapper &trigger);
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -68,5 +68,17 @@ Contrast=1.5
|
|||||||
Intensity=1.0
|
Intensity=1.0
|
||||||
NumSamples=24
|
NumSamples=24
|
||||||
NumTurns=17
|
NumTurns=17
|
||||||
NumIterations=13
|
NumIterations=9
|
||||||
TextureQuality=0
|
TextureQuality=0
|
||||||
|
|
||||||
|
[GLOW]
|
||||||
|
Quality=3;
|
||||||
|
|
||||||
|
[GLOW1]
|
||||||
|
NumIterations=5
|
||||||
|
|
||||||
|
[GLOW2]
|
||||||
|
NumIterations=9
|
||||||
|
|
||||||
|
[GLOW3]
|
||||||
|
NumIterations=13
|
||||||
@@ -35,7 +35,12 @@
|
|||||||
<xs:include schemaLocation="Components/AmmoPickup.xsd"/>
|
<xs:include schemaLocation="Components/AmmoPickup.xsd"/>
|
||||||
<xs:include schemaLocation="Components/AnimationOffset.xsd"/>
|
<xs:include schemaLocation="Components/AnimationOffset.xsd"/>
|
||||||
<xs:include schemaLocation="Components/DashAbility.xsd"/>
|
<xs:include schemaLocation="Components/DashAbility.xsd"/>
|
||||||
|
<xs:include schemaLocation="Components/ShieldAbility.xsd"/>
|
||||||
|
<xs:include schemaLocation="Components/SprintAbility.xsd"/>
|
||||||
<xs:include schemaLocation="Components/AssaultWeapon.xsd"/>
|
<xs:include schemaLocation="Components/AssaultWeapon.xsd"/>
|
||||||
|
<xs:include schemaLocation="Components/BoostAssault.xsd"/>
|
||||||
|
<xs:include schemaLocation="Components/BoostDefender.xsd"/>
|
||||||
|
<xs:include schemaLocation="Components/BoostSniper.xsd"/>
|
||||||
<xs:include schemaLocation="Components/Shield.xsd"/>
|
<xs:include schemaLocation="Components/Shield.xsd"/>
|
||||||
<xs:include schemaLocation="Components/Sprite.xsd"/>
|
<xs:include schemaLocation="Components/Sprite.xsd"/>
|
||||||
<xs:include schemaLocation="Components/Shielded.xsd"/>
|
<xs:include schemaLocation="Components/Shielded.xsd"/>
|
||||||
@@ -50,4 +55,5 @@
|
|||||||
<xs:include schemaLocation="Components/WeaponAttachment.xsd"/>
|
<xs:include schemaLocation="Components/WeaponAttachment.xsd"/>
|
||||||
<xs:include schemaLocation="Components/DefenderWeapon.xsd"/>
|
<xs:include schemaLocation="Components/DefenderWeapon.xsd"/>
|
||||||
<xs:include schemaLocation="Components/CapturePointGameMode.xsd"/>
|
<xs:include schemaLocation="Components/CapturePointGameMode.xsd"/>
|
||||||
|
<xs:include schemaLocation="Components/CapturePointArrowHUD.xsd"/>
|
||||||
</xs:schema>
|
</xs:schema>
|
||||||
@@ -0,0 +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>2</StrengthOfEffect>
|
||||||
|
</BoostAssault>
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
<?xml version="1.0"?>
|
||||||
|
|
||||||
|
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:t="types">
|
||||||
|
<xs:import schemaLocation="../Types.xsd" namespace="types"/>
|
||||||
|
|
||||||
|
<xs:element name="BoostAssault">
|
||||||
|
<xs:annotation>
|
||||||
|
<xs:documentation>This is the assault's class boost component</xs:documentation>
|
||||||
|
</xs:annotation>
|
||||||
|
<xs:complexType>
|
||||||
|
<xs:all>
|
||||||
|
<xs:element name="StrengthOfEffect" type="t:double" minOccurs="0">
|
||||||
|
<xs:annotation><xs:documentation>This is the strength of the boost effect</xs:documentation></xs:annotation>
|
||||||
|
</xs:element>
|
||||||
|
</xs:all>
|
||||||
|
</xs:complexType>
|
||||||
|
</xs:element>
|
||||||
|
</xs:schema>
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||||
|
<BoostDefender xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="BoostDefender.xsd">
|
||||||
|
<StrengthOfEffect>10</StrengthOfEffect>
|
||||||
|
</BoostDefender>
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
<?xml version="1.0"?>
|
||||||
|
|
||||||
|
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:t="types">
|
||||||
|
<xs:import schemaLocation="../Types.xsd" namespace="types"/>
|
||||||
|
|
||||||
|
<xs:element name="BoostDefender">
|
||||||
|
<xs:annotation>
|
||||||
|
<xs:documentation>This is the defender's class boost component</xs:documentation>
|
||||||
|
</xs:annotation>
|
||||||
|
<xs:complexType>
|
||||||
|
<xs:all>
|
||||||
|
<xs:element name="StrengthOfEffect" type="t:double" minOccurs="0">
|
||||||
|
<xs:annotation><xs:documentation>This is the strength of the boost effect</xs:documentation></xs:annotation>
|
||||||
|
</xs:element>
|
||||||
|
</xs:all>
|
||||||
|
</xs:complexType>
|
||||||
|
</xs:element>
|
||||||
|
</xs:schema>
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||||
|
<BoostSniper xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="BoostSniper.xsd">
|
||||||
|
<StrengthOfEffect>10</StrengthOfEffect>
|
||||||
|
</BoostSniper>
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
<?xml version="1.0"?>
|
||||||
|
|
||||||
|
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:t="types">
|
||||||
|
<xs:import schemaLocation="../Types.xsd" namespace="types"/>
|
||||||
|
|
||||||
|
<xs:element name="BoostSniper">
|
||||||
|
<xs:annotation>
|
||||||
|
<xs:documentation>This is the sniper's class boost component</xs:documentation>
|
||||||
|
</xs:annotation>
|
||||||
|
<xs:complexType>
|
||||||
|
<xs:all>
|
||||||
|
<xs:element name="StrengthOfEffect" type="t:double" minOccurs="0">
|
||||||
|
<xs:annotation><xs:documentation>This is the strength of the boost effect</xs:documentation></xs:annotation>
|
||||||
|
</xs:element>
|
||||||
|
</xs:all>
|
||||||
|
</xs:complexType>
|
||||||
|
</xs:element>
|
||||||
|
</xs:schema>
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||||
|
<CapturePointArrowHUD xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="CapturePointArrowHUD.xsd">
|
||||||
|
<CurrentTarget>0</CurrentTarget>
|
||||||
|
</CapturePointArrowHUD>
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
<?xml version="1.0"?>
|
||||||
|
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:t="types">
|
||||||
|
<xs:import schemaLocation="../Types.xsd" namespace="types"/>
|
||||||
|
<xs:element name="CapturePointArrowHUD">
|
||||||
|
<xs:annotation>
|
||||||
|
<xs:documentation>HUD element for tracking next capturable Capture Point.</xs:documentation>
|
||||||
|
</xs:annotation>
|
||||||
|
<xs:complexType>
|
||||||
|
<xs:all>
|
||||||
|
<xs:element name="CurrentTarget" type="t:int" minOccurs="0">
|
||||||
|
<xs:annotation>
|
||||||
|
<xs:documentation>Corresponds to the current capturepoint the arrow points Towards</xs:documentation>
|
||||||
|
</xs:annotation>
|
||||||
|
</xs:element>
|
||||||
|
</xs:all>
|
||||||
|
</xs:complexType>
|
||||||
|
</xs:element>
|
||||||
|
</xs:schema>
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||||
|
<ShieldAbility xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="ShieldAbility.xsd">
|
||||||
|
<CoolDownMaxTimer>2.0</CoolDownMaxTimer>
|
||||||
|
</ShieldAbility>
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
<?xml version="1.0"?>
|
||||||
|
|
||||||
|
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:t="types">
|
||||||
|
<xs:import schemaLocation="../Types.xsd" namespace="types"/>
|
||||||
|
|
||||||
|
<xs:element name="ShieldAbility">
|
||||||
|
<xs:annotation>
|
||||||
|
<xs:documentation>A shield component for one of the classes</xs:documentation>
|
||||||
|
</xs:annotation>
|
||||||
|
<xs:complexType>
|
||||||
|
<xs:all>
|
||||||
|
<xs:element name="CoolDownMaxTimer" type="t:double" minOccurs="0">
|
||||||
|
<xs:annotation><xs:documentation>This is the cooldown on shield</xs:documentation></xs:annotation>
|
||||||
|
</xs:element>
|
||||||
|
</xs:all>
|
||||||
|
</xs:complexType>
|
||||||
|
</xs:element>
|
||||||
|
</xs:schema>
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||||
|
<SprintAbility xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="SprintAbility.xsd">
|
||||||
|
<CoolDownMaxTimer>2.0</CoolDownMaxTimer>
|
||||||
|
</SprintAbility>
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
<?xml version="1.0"?>
|
||||||
|
|
||||||
|
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:t="types">
|
||||||
|
<xs:import schemaLocation="../Types.xsd" namespace="types"/>
|
||||||
|
|
||||||
|
<xs:element name="SprintAbility">
|
||||||
|
<xs:annotation>
|
||||||
|
<xs:documentation>A sprint component for one of the classes</xs:documentation>
|
||||||
|
</xs:annotation>
|
||||||
|
<xs:complexType>
|
||||||
|
<xs:all>
|
||||||
|
<xs:element name="CoolDownMaxTimer" type="t:double" minOccurs="0">
|
||||||
|
<xs:annotation><xs:documentation>This is the cooldown on sprint</xs:documentation></xs:annotation>
|
||||||
|
</xs:element>
|
||||||
|
</xs:all>
|
||||||
|
</xs:complexType>
|
||||||
|
</xs:element>
|
||||||
|
</xs:schema>
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||||
|
<Entity xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../Types/Entity.xsd">
|
||||||
|
|
||||||
|
<Components>
|
||||||
|
<c:BoostAssault/>
|
||||||
|
<c:Lifetime>
|
||||||
|
<Lifetime>10</Lifetime>
|
||||||
|
</c:Lifetime>
|
||||||
|
<c:Transform/>
|
||||||
|
</Components>
|
||||||
|
|
||||||
|
<Children/>
|
||||||
|
|
||||||
|
</Entity>
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,14 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||||
|
<Entity xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../Types/Entity.xsd">
|
||||||
|
|
||||||
|
<Components>
|
||||||
|
<c:BoostDefender/>
|
||||||
|
<c:Lifetime>
|
||||||
|
<Lifetime>10</Lifetime>
|
||||||
|
</c:Lifetime>
|
||||||
|
<c:Transform/>
|
||||||
|
</Components>
|
||||||
|
|
||||||
|
<Children/>
|
||||||
|
|
||||||
|
</Entity>
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||||
|
<Entity xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../Types/Entity.xsd">
|
||||||
|
|
||||||
|
<Components>
|
||||||
|
<c:BoostSniper/>
|
||||||
|
<c:Lifetime>
|
||||||
|
<Lifetime>10</Lifetime>
|
||||||
|
</c:Lifetime>
|
||||||
|
<c:Transform/>
|
||||||
|
</Components>
|
||||||
|
|
||||||
|
<Children/>
|
||||||
|
|
||||||
|
</Entity>
|
||||||
@@ -5019,7 +5019,7 @@
|
|||||||
</Team>
|
</Team>
|
||||||
</c:Team>
|
</c:Team>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="-60.3695679" Y="5.64500046" Z="-79.3789597"/>
|
<Position X="-60.3695679" Y="5.14500046" Z="-79.3789597"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -5089,7 +5089,7 @@
|
|||||||
</Team>
|
</Team>
|
||||||
</c:Team>
|
</c:Team>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="60.0169258" Y="5.78000021" Z="76.2893906"/>
|
<Position X="60.0169258" Y="6.0800004" Z="76.2893906"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -5165,7 +5165,7 @@
|
|||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="48.9189453" Y="7.06223536" Z="-78.9347992"/>
|
<Position X="48.9189453" Y="7.06223536" Z="-78.9347992"/>
|
||||||
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
||||||
<Orientation X="0" Y="75.6124268" Z="0"/>
|
<Orientation X="0" Y="74.6042328" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
<c:Trigger/>
|
||||||
</Components>
|
</Components>
|
||||||
@@ -5184,7 +5184,7 @@
|
|||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="-59.3499641" Y="7.46932745" Z="-20.6276321"/>
|
<Position X="-59.3499641" Y="7.46932745" Z="-20.6276321"/>
|
||||||
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
||||||
<Orientation X="0" Y="72.2667694" Z="0"/>
|
<Orientation X="0" Y="71.2585754" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
<c:Trigger/>
|
||||||
</Components>
|
</Components>
|
||||||
@@ -5203,7 +5203,7 @@
|
|||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="-1.13644195" Y="1.38919806" Z="38.9768829"/>
|
<Position X="-1.13644195" Y="1.38919806" Z="38.9768829"/>
|
||||||
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
||||||
<Orientation X="0" Y="69.8748016" Z="0"/>
|
<Orientation X="0" Y="68.8666077" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
<c:Trigger/>
|
||||||
</Components>
|
</Components>
|
||||||
@@ -5222,7 +5222,7 @@
|
|||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="54.7225227" Y="6.51863909" Z="29.0052128"/>
|
<Position X="54.7225227" Y="6.51863909" Z="29.0052128"/>
|
||||||
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
||||||
<Orientation X="0" Y="70.1887283" Z="0"/>
|
<Orientation X="0" Y="69.180542" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
<c:Trigger/>
|
||||||
</Components>
|
</Components>
|
||||||
@@ -5241,7 +5241,7 @@
|
|||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="-51.6792374" Y="8.44526482" Z="32.5153465"/>
|
<Position X="-51.6792374" Y="8.44526482" Z="32.5153465"/>
|
||||||
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
||||||
<Orientation X="0" Y="69.6374512" Z="0"/>
|
<Orientation X="0" Y="68.6292572" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
<c:Trigger/>
|
||||||
</Components>
|
</Components>
|
||||||
@@ -5260,7 +5260,7 @@
|
|||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="-42.3974304" Y="7.28327894" Z="81.9305344"/>
|
<Position X="-42.3974304" Y="7.28327894" Z="81.9305344"/>
|
||||||
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
||||||
<Orientation X="0" Y="67.7666702" Z="0"/>
|
<Orientation X="0" Y="66.7584839" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
<c:Trigger/>
|
||||||
</Components>
|
</Components>
|
||||||
@@ -5279,7 +5279,7 @@
|
|||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="-9.85184956" Y="8.25567532" Z="39.6119232"/>
|
<Position X="-9.85184956" Y="8.25567532" Z="39.6119232"/>
|
||||||
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
||||||
<Orientation X="0" Y="66.8154602" Z="0"/>
|
<Orientation X="0" Y="65.8073425" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
<c:Trigger/>
|
||||||
</Components>
|
</Components>
|
||||||
@@ -5298,7 +5298,7 @@
|
|||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="49.2257118" Y="7.39368248" Z="-31.1810112"/>
|
<Position X="49.2257118" Y="7.39368248" Z="-31.1810112"/>
|
||||||
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
<Scale X="0.300000012" Y="0.300000012" Z="0.300000012"/>
|
||||||
<Orientation X="0" Y="64.0265808" Z="0"/>
|
<Orientation X="0" Y="63.0184822" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
<c:Trigger/>
|
||||||
</Components>
|
</Components>
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -13,7 +13,7 @@
|
|||||||
</c:AssaultWeapon>
|
</c:AssaultWeapon>
|
||||||
<c:Collidable/>
|
<c:Collidable/>
|
||||||
<c:DefenderWeapon>
|
<c:DefenderWeapon>
|
||||||
<TimeSinceLastFire>1.6944730461160304</TimeSinceLastFire>
|
<TimeSinceLastFire>52.867678870419283</TimeSinceLastFire>
|
||||||
</c:DefenderWeapon>
|
</c:DefenderWeapon>
|
||||||
<c:DoubleJump/>
|
<c:DoubleJump/>
|
||||||
<c:Health/>
|
<c:Health/>
|
||||||
@@ -37,7 +37,10 @@
|
|||||||
<Children>
|
<Children>
|
||||||
<Entity name="Camera">
|
<Entity name="Camera">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Camera/>
|
<c:Camera>
|
||||||
|
<NearClip>0.10000000149011612</NearClip>
|
||||||
|
<FarClip>300</FarClip>
|
||||||
|
</c:Camera>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="1.27700007" Z="0"/>
|
<Position X="0" Y="1.27700007" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
@@ -372,7 +375,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Animation>
|
<c:Animation>
|
||||||
<AnimationName1>Idle</AnimationName1>
|
<AnimationName1>Idle</AnimationName1>
|
||||||
<Time1>0.67172915251515519</Time1>
|
<Time1>1.9408570429715581</Time1>
|
||||||
<Speed1>1</Speed1>
|
<Speed1>1</Speed1>
|
||||||
<AnimationName2></AnimationName2>
|
<AnimationName2></AnimationName2>
|
||||||
<AnimationName3></AnimationName3>
|
<AnimationName3></AnimationName3>
|
||||||
@@ -386,25 +389,25 @@
|
|||||||
<Children>
|
<Children>
|
||||||
<Entity name="PrimaryAttachment">
|
<Entity name="PrimaryAttachment">
|
||||||
<Components>
|
<Components>
|
||||||
|
<c:WeaponAttachment>
|
||||||
|
<Weapon>DefenderWeapon</Weapon>
|
||||||
|
</c:WeaponAttachment>
|
||||||
<c:Spawner>
|
<c:Spawner>
|
||||||
<EntityFile>Schema/Entities/DefenderWeaponView.xml</EntityFile>
|
<EntityFile>Schema/Entities/DefenderWeaponView.xml</EntityFile>
|
||||||
</c:Spawner>
|
</c:Spawner>
|
||||||
<c:Transform/>
|
<c:Transform/>
|
||||||
<c:WeaponAttachment>
|
|
||||||
<Weapon>DefenderWeapon</Weapon>
|
|
||||||
</c:WeaponAttachment>
|
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
<Entity name="SecondaryAttachment">
|
<Entity name="SecondaryAttachment">
|
||||||
<Components>
|
<Components>
|
||||||
|
<c:WeaponAttachment>
|
||||||
|
<Weapon>AssaultWeapon</Weapon>
|
||||||
|
</c:WeaponAttachment>
|
||||||
<c:Spawner>
|
<c:Spawner>
|
||||||
<EntityFile>Schema/Entities/AssaultWeaponView.xml</EntityFile>
|
<EntityFile>Schema/Entities/AssaultWeaponView.xml</EntityFile>
|
||||||
</c:Spawner>
|
</c:Spawner>
|
||||||
<c:Transform/>
|
<c:Transform/>
|
||||||
<c:WeaponAttachment>
|
|
||||||
<Weapon>AssaultWeapon</Weapon>
|
|
||||||
</c:WeaponAttachment>
|
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
@@ -414,7 +417,10 @@
|
|||||||
</Entity>
|
</Entity>
|
||||||
<Entity name="ThirdPersonCamera">
|
<Entity name="ThirdPersonCamera">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Camera/>
|
<c:Camera>
|
||||||
|
<NearClip>0.10000000149011612</NearClip>
|
||||||
|
<FarClip>300</FarClip>
|
||||||
|
</c:Camera>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Widgets/Camera.mesh</Resource>
|
<Resource>Models/Widgets/Camera.mesh</Resource>
|
||||||
<Visible>false</Visible>
|
<Visible>false</Visible>
|
||||||
@@ -430,6 +436,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Animation>
|
<c:Animation>
|
||||||
<AnimationName1>Idle</AnimationName1>
|
<AnimationName1>Idle</AnimationName1>
|
||||||
|
<Time1>1.5631122524686134</Time1>
|
||||||
<Speed1>1</Speed1>
|
<Speed1>1</Speed1>
|
||||||
<AnimationName2></AnimationName2>
|
<AnimationName2></AnimationName2>
|
||||||
<AnimationName3></AnimationName3>
|
<AnimationName3></AnimationName3>
|
||||||
@@ -449,31 +456,31 @@
|
|||||||
<Children>
|
<Children>
|
||||||
<Entity name="PrimaryAttachment">
|
<Entity name="PrimaryAttachment">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Spawner>
|
|
||||||
<EntityFile>Schema/Entities/DefenderWeaponWorld.xml</EntityFile>
|
|
||||||
</c:Spawner>
|
|
||||||
<c:Transform/>
|
|
||||||
<c:WeaponAttachment>
|
<c:WeaponAttachment>
|
||||||
<Weapon>DefenderWeapon</Weapon>
|
<Weapon>DefenderWeapon</Weapon>
|
||||||
<Person>
|
<Person>
|
||||||
<ThirdPerson/>
|
<ThirdPerson/>
|
||||||
</Person>
|
</Person>
|
||||||
</c:WeaponAttachment>
|
</c:WeaponAttachment>
|
||||||
|
<c:Spawner>
|
||||||
|
<EntityFile>Schema/Entities/DefenderWeaponWorld.xml</EntityFile>
|
||||||
|
</c:Spawner>
|
||||||
|
<c:Transform/>
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
<Entity name="SecondaryAttachment">
|
<Entity name="SecondaryAttachment">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Spawner>
|
|
||||||
<EntityFile>Schema/Entities/AssaultWeaponWorld.xml</EntityFile>
|
|
||||||
</c:Spawner>
|
|
||||||
<c:Transform/>
|
|
||||||
<c:WeaponAttachment>
|
<c:WeaponAttachment>
|
||||||
<Weapon>AssaultWeapon</Weapon>
|
<Weapon>AssaultWeapon</Weapon>
|
||||||
<Person>
|
<Person>
|
||||||
<ThirdPerson/>
|
<ThirdPerson/>
|
||||||
</Person>
|
</Person>
|
||||||
</c:WeaponAttachment>
|
</c:WeaponAttachment>
|
||||||
|
<c:Spawner>
|
||||||
|
<EntityFile>Schema/Entities/AssaultWeaponWorld.xml</EntityFile>
|
||||||
|
</c:Spawner>
|
||||||
|
<c:Transform/>
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
</c:AssaultWeapon>
|
</c:AssaultWeapon>
|
||||||
<c:Collidable/>
|
<c:Collidable/>
|
||||||
<c:DefenderWeapon>
|
<c:DefenderWeapon>
|
||||||
<TimeSinceLastFire>1.6944730461160304</TimeSinceLastFire>
|
<TimeSinceLastFire>22.22055262342397</TimeSinceLastFire>
|
||||||
</c:DefenderWeapon>
|
</c:DefenderWeapon>
|
||||||
<c:DoubleJump/>
|
<c:DoubleJump/>
|
||||||
<c:Health/>
|
<c:Health/>
|
||||||
@@ -37,7 +37,10 @@
|
|||||||
<Children>
|
<Children>
|
||||||
<Entity name="Camera">
|
<Entity name="Camera">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Camera/>
|
<c:Camera>
|
||||||
|
<NearClip>0.10000000149011612</NearClip>
|
||||||
|
<FarClip>300</FarClip>
|
||||||
|
</c:Camera>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="1.27700007" Z="0"/>
|
<Position X="0" Y="1.27700007" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
@@ -372,7 +375,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Animation>
|
<c:Animation>
|
||||||
<AnimationName1>Idle</AnimationName1>
|
<AnimationName1>Idle</AnimationName1>
|
||||||
<Time1>0.67172915251515519</Time1>
|
<Time1>1.1978087298230946</Time1>
|
||||||
<Speed1>1</Speed1>
|
<Speed1>1</Speed1>
|
||||||
<AnimationName2></AnimationName2>
|
<AnimationName2></AnimationName2>
|
||||||
<AnimationName3></AnimationName3>
|
<AnimationName3></AnimationName3>
|
||||||
@@ -386,25 +389,25 @@
|
|||||||
<Children>
|
<Children>
|
||||||
<Entity name="PrimaryAttachment">
|
<Entity name="PrimaryAttachment">
|
||||||
<Components>
|
<Components>
|
||||||
|
<c:WeaponAttachment>
|
||||||
|
<Weapon>DefenderWeapon</Weapon>
|
||||||
|
</c:WeaponAttachment>
|
||||||
<c:Spawner>
|
<c:Spawner>
|
||||||
<EntityFile>Schema/Entities/DefenderWeaponViewRed.xml</EntityFile>
|
<EntityFile>Schema/Entities/DefenderWeaponViewRed.xml</EntityFile>
|
||||||
</c:Spawner>
|
</c:Spawner>
|
||||||
<c:Transform/>
|
<c:Transform/>
|
||||||
<c:WeaponAttachment>
|
|
||||||
<Weapon>DefenderWeapon</Weapon>
|
|
||||||
</c:WeaponAttachment>
|
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
<Entity name="SecondaryAttachment">
|
<Entity name="SecondaryAttachment">
|
||||||
<Components>
|
<Components>
|
||||||
|
<c:WeaponAttachment>
|
||||||
|
<Weapon>AssaultWeapon</Weapon>
|
||||||
|
</c:WeaponAttachment>
|
||||||
<c:Spawner>
|
<c:Spawner>
|
||||||
<EntityFile>Schema/Entities/AssaultWeaponView.xml</EntityFile>
|
<EntityFile>Schema/Entities/AssaultWeaponView.xml</EntityFile>
|
||||||
</c:Spawner>
|
</c:Spawner>
|
||||||
<c:Transform/>
|
<c:Transform/>
|
||||||
<c:WeaponAttachment>
|
|
||||||
<Weapon>AssaultWeapon</Weapon>
|
|
||||||
</c:WeaponAttachment>
|
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
@@ -414,7 +417,10 @@
|
|||||||
</Entity>
|
</Entity>
|
||||||
<Entity name="ThirdPersonCamera">
|
<Entity name="ThirdPersonCamera">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Camera/>
|
<c:Camera>
|
||||||
|
<NearClip>0.10000000149011612</NearClip>
|
||||||
|
<FarClip>300</FarClip>
|
||||||
|
</c:Camera>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Widgets/Camera.mesh</Resource>
|
<Resource>Models/Widgets/Camera.mesh</Resource>
|
||||||
<Visible>false</Visible>
|
<Visible>false</Visible>
|
||||||
@@ -430,6 +436,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Animation>
|
<c:Animation>
|
||||||
<AnimationName1>Idle</AnimationName1>
|
<AnimationName1>Idle</AnimationName1>
|
||||||
|
<Time1>0.69274608502888668</Time1>
|
||||||
<Speed1>1</Speed1>
|
<Speed1>1</Speed1>
|
||||||
<AnimationName2></AnimationName2>
|
<AnimationName2></AnimationName2>
|
||||||
<AnimationName3></AnimationName3>
|
<AnimationName3></AnimationName3>
|
||||||
@@ -449,31 +456,31 @@
|
|||||||
<Children>
|
<Children>
|
||||||
<Entity name="PrimaryAttachment">
|
<Entity name="PrimaryAttachment">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Spawner>
|
|
||||||
<EntityFile>Schema/Entities/DefenderWeaponWorldRed.xml</EntityFile>
|
|
||||||
</c:Spawner>
|
|
||||||
<c:Transform/>
|
|
||||||
<c:WeaponAttachment>
|
<c:WeaponAttachment>
|
||||||
<Weapon>DefenderWeapon</Weapon>
|
<Weapon>DefenderWeapon</Weapon>
|
||||||
<Person>
|
<Person>
|
||||||
<ThirdPerson/>
|
<ThirdPerson/>
|
||||||
</Person>
|
</Person>
|
||||||
</c:WeaponAttachment>
|
</c:WeaponAttachment>
|
||||||
|
<c:Spawner>
|
||||||
|
<EntityFile>Schema/Entities/DefenderWeaponWorldRed.xml</EntityFile>
|
||||||
|
</c:Spawner>
|
||||||
|
<c:Transform/>
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
<Entity name="SecondaryAttachment">
|
<Entity name="SecondaryAttachment">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Spawner>
|
|
||||||
<EntityFile>Schema/Entities/AssaultWeaponWorld.xml</EntityFile>
|
|
||||||
</c:Spawner>
|
|
||||||
<c:Transform/>
|
|
||||||
<c:WeaponAttachment>
|
<c:WeaponAttachment>
|
||||||
<Weapon>AssaultWeapon</Weapon>
|
<Weapon>AssaultWeapon</Weapon>
|
||||||
<Person>
|
<Person>
|
||||||
<ThirdPerson/>
|
<ThirdPerson/>
|
||||||
</Person>
|
</Person>
|
||||||
</c:WeaponAttachment>
|
</c:WeaponAttachment>
|
||||||
|
<c:Spawner>
|
||||||
|
<EntityFile>Schema/Entities/AssaultWeaponWorld.xml</EntityFile>
|
||||||
|
</c:Spawner>
|
||||||
|
<c:Transform/>
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
|
|||||||
@@ -2,6 +2,9 @@
|
|||||||
<Entity xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../Types/Entity.xsd">
|
<Entity xmlns:c="components" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../Types/Entity.xsd">
|
||||||
|
|
||||||
<Components>
|
<Components>
|
||||||
|
<c:CapturePointGameMode>
|
||||||
|
<RespawnTime>4.7473226580121377</RespawnTime>
|
||||||
|
</c:CapturePointGameMode>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="-1" Z="0"/>
|
<Position X="0" Y="-1" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
@@ -40,7 +43,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="8433.37305" Z="0"/>
|
<Orientation X="0" Y="9038.11328" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -81,19 +84,19 @@
|
|||||||
</Entity>
|
</Entity>
|
||||||
<Entity name="DirectionalLight">
|
<Entity name="DirectionalLight">
|
||||||
<Components>
|
<Components>
|
||||||
|
<c:RaptorCopter>
|
||||||
|
<Speed>1</Speed>
|
||||||
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
|
</c:RaptorCopter>
|
||||||
<c:DirectionalLight>
|
<c:DirectionalLight>
|
||||||
<Intensity>0.80000001192092896</Intensity>
|
<Intensity>0.80000001192092896</Intensity>
|
||||||
</c:DirectionalLight>
|
</c:DirectionalLight>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Widgets/Lights/DirectionalLightWidget.mesh</Resource>
|
<Resource>Models/Widgets/Lights/DirectionalLightWidget.mesh</Resource>
|
||||||
</c:Model>
|
</c:Model>
|
||||||
<c:RaptorCopter>
|
|
||||||
<Speed>1</Speed>
|
|
||||||
<Axis X="0" Y="1" Z="0"/>
|
|
||||||
</c:RaptorCopter>
|
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="2.1529963" Y="6.59221172" Z="0.169116676"/>
|
<Position X="2.1529963" Y="6.59221172" Z="0.169116676"/>
|
||||||
<Orientation X="4.16300011" Y="18271.9141" Z="0"/>
|
<Orientation X="4.16300011" Y="18876.6172" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
@@ -108,7 +111,11 @@
|
|||||||
<Children>
|
<Children>
|
||||||
<Entity name="RunAnim">
|
<Entity name="RunAnim">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Animation/>
|
<c:Animation>
|
||||||
|
<AnimationName1></AnimationName1>
|
||||||
|
<AnimationName2></AnimationName2>
|
||||||
|
<AnimationName3></AnimationName3>
|
||||||
|
</c:Animation>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Characters/Assault/AssaultAnimated.mesh</Resource>
|
<Resource>Models/Characters/Assault/AssaultAnimated.mesh</Resource>
|
||||||
</c:Model>
|
</c:Model>
|
||||||
@@ -120,7 +127,11 @@
|
|||||||
</Entity>
|
</Entity>
|
||||||
<Entity name="Walkanim">
|
<Entity name="Walkanim">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Animation/>
|
<c:Animation>
|
||||||
|
<AnimationName1></AnimationName1>
|
||||||
|
<AnimationName2></AnimationName2>
|
||||||
|
<AnimationName3></AnimationName3>
|
||||||
|
</c:Animation>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Characters/Assault/AssaultAnimated.mesh</Resource>
|
<Resource>Models/Characters/Assault/AssaultAnimated.mesh</Resource>
|
||||||
</c:Model>
|
</c:Model>
|
||||||
@@ -168,13 +179,17 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="2553.63574" Z="0"/>
|
<Orientation X="0" Y="2856.05518" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
<Entity name="Asset">
|
<Entity name="Asset">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Animation/>
|
<c:Animation>
|
||||||
|
<AnimationName1></AnimationName1>
|
||||||
|
<AnimationName2></AnimationName2>
|
||||||
|
<AnimationName3></AnimationName3>
|
||||||
|
</c:Animation>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Characters/Assault/AssaultAnimated.mesh</Resource>
|
<Resource>Models/Characters/Assault/AssaultAnimated.mesh</Resource>
|
||||||
</c:Model>
|
</c:Model>
|
||||||
@@ -213,7 +228,7 @@
|
|||||||
<Axis X="1" Y="1" Z="1"/>
|
<Axis X="1" Y="1" Z="1"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="16862.3945" Y="16862.3945" Z="16862.3945"/>
|
<Orientation X="17467.0977" Y="17467.0977" Z="17467.0977"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -277,7 +292,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="16658.3906" Z="0"/>
|
<Orientation X="0" Y="17263.0938" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -309,7 +324,7 @@
|
|||||||
<Axis X="0.699999988" Y="1" Z="0.300000012"/>
|
<Axis X="0.699999988" Y="1" Z="0.300000012"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="12206.665" Y="17385.8008" Z="5202.3335"/>
|
<Orientation X="12630.0664" Y="17990.5039" Z="5383.80176"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -659,7 +674,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="851.386902" Z="0"/>
|
<Orientation X="0" Y="1153.80225" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -706,7 +721,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="851.386902" Z="0"/>
|
<Orientation X="0" Y="1153.80225" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -766,7 +781,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="851.386902" Z="0"/>
|
<Orientation X="0" Y="1153.80225" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -813,7 +828,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="851.386902" Z="0"/>
|
<Orientation X="0" Y="1153.80225" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -859,7 +874,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="851.386902" Z="0"/>
|
<Orientation X="0" Y="1153.80225" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -906,7 +921,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="851.386902" Z="0"/>
|
<Orientation X="0" Y="1153.80225" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -953,7 +968,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="851.386902" Z="0"/>
|
<Orientation X="0" Y="1153.80225" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -1013,6 +1028,7 @@
|
|||||||
</HomePointForTeam>
|
</HomePointForTeam>
|
||||||
<CaptureTimer>15</CaptureTimer>
|
<CaptureTimer>15</CaptureTimer>
|
||||||
</c:CapturePoint>
|
</c:CapturePoint>
|
||||||
|
<c:Trigger/>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Core/UnitCube.mesh</Resource>
|
<Resource>Models/Core/UnitCube.mesh</Resource>
|
||||||
<Color A="0.300000012" B="0" G="0" R="1"/>
|
<Color A="0.300000012" B="0" G="0" R="1"/>
|
||||||
@@ -1027,7 +1043,6 @@
|
|||||||
<Position X="0" Y="2" Z="0"/>
|
<Position X="0" Y="2" Z="0"/>
|
||||||
<Scale X="8" Y="4" Z="8"/>
|
<Scale X="8" Y="4" Z="8"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
@@ -1063,6 +1078,7 @@
|
|||||||
<c:CapturePoint>
|
<c:CapturePoint>
|
||||||
<CapturePointNumber>1</CapturePointNumber>
|
<CapturePointNumber>1</CapturePointNumber>
|
||||||
</c:CapturePoint>
|
</c:CapturePoint>
|
||||||
|
<c:Trigger/>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Core/UnitCube.mesh</Resource>
|
<Resource>Models/Core/UnitCube.mesh</Resource>
|
||||||
<Color A="0.300000012" B="1" G="1" R="1"/>
|
<Color A="0.300000012" B="1" G="1" R="1"/>
|
||||||
@@ -1073,7 +1089,6 @@
|
|||||||
<Position X="0" Y="2" Z="0"/>
|
<Position X="0" Y="2" Z="0"/>
|
||||||
<Scale X="8" Y="4" Z="8"/>
|
<Scale X="8" Y="4" Z="8"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
@@ -1107,6 +1122,7 @@
|
|||||||
<c:CapturePoint>
|
<c:CapturePoint>
|
||||||
<CapturePointNumber>2</CapturePointNumber>
|
<CapturePointNumber>2</CapturePointNumber>
|
||||||
</c:CapturePoint>
|
</c:CapturePoint>
|
||||||
|
<c:Trigger/>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Core/UnitCube.mesh</Resource>
|
<Resource>Models/Core/UnitCube.mesh</Resource>
|
||||||
<Color A="0.300000012" B="1" G="1" R="1"/>
|
<Color A="0.300000012" B="1" G="1" R="1"/>
|
||||||
@@ -1117,7 +1133,6 @@
|
|||||||
<Position X="0" Y="2" Z="0"/>
|
<Position X="0" Y="2" Z="0"/>
|
||||||
<Scale X="8" Y="4" Z="8"/>
|
<Scale X="8" Y="4" Z="8"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
@@ -1153,6 +1168,7 @@
|
|||||||
<c:CapturePoint>
|
<c:CapturePoint>
|
||||||
<CapturePointNumber>3</CapturePointNumber>
|
<CapturePointNumber>3</CapturePointNumber>
|
||||||
</c:CapturePoint>
|
</c:CapturePoint>
|
||||||
|
<c:Trigger/>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Core/UnitCube.mesh</Resource>
|
<Resource>Models/Core/UnitCube.mesh</Resource>
|
||||||
<Color A="0.300000012" B="1" G="1" R="1"/>
|
<Color A="0.300000012" B="1" G="1" R="1"/>
|
||||||
@@ -1163,7 +1179,6 @@
|
|||||||
<Position X="0" Y="2" Z="0"/>
|
<Position X="0" Y="2" Z="0"/>
|
||||||
<Scale X="8" Y="4" Z="8"/>
|
<Scale X="8" Y="4" Z="8"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
@@ -1203,6 +1218,7 @@
|
|||||||
<CaptureTimer>-15</CaptureTimer>
|
<CaptureTimer>-15</CaptureTimer>
|
||||||
<CapturePointNumber>4</CapturePointNumber>
|
<CapturePointNumber>4</CapturePointNumber>
|
||||||
</c:CapturePoint>
|
</c:CapturePoint>
|
||||||
|
<c:Trigger/>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Core/UnitCube.mesh</Resource>
|
<Resource>Models/Core/UnitCube.mesh</Resource>
|
||||||
<Color A="0.300000012" B="1" G="0" R="0"/>
|
<Color A="0.300000012" B="1" G="0" R="0"/>
|
||||||
@@ -1217,7 +1233,6 @@
|
|||||||
<Position X="0" Y="2" Z="0"/>
|
<Position X="0" Y="2" Z="0"/>
|
||||||
<Scale X="8" Y="4" Z="8"/>
|
<Scale X="8" Y="4" Z="8"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
<c:Trigger/>
|
|
||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
@@ -1367,7 +1382,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="1385.11243" Z="0"/>
|
<Orientation X="0" Y="1687.52917" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -1376,7 +1391,7 @@
|
|||||||
<c:ExplosionEffect>
|
<c:ExplosionEffect>
|
||||||
<ColorByDistance>true</ColorByDistance>
|
<ColorByDistance>true</ColorByDistance>
|
||||||
<Velocity X="0.800000012" Y="0.0379999988" Z="0"/>
|
<Velocity X="0.800000012" Y="0.0379999988" Z="0"/>
|
||||||
<TimeSinceDeath>0.8256214817261025</TimeSinceDeath>
|
<TimeSinceDeath>2.5396116058983438</TimeSinceDeath>
|
||||||
<ExplosionDuration>3.7999999523162842</ExplosionDuration>
|
<ExplosionDuration>3.7999999523162842</ExplosionDuration>
|
||||||
<EndColor A="0" B="23.5294113" G="11.7647057" R="0"/>
|
<EndColor A="0" B="23.5294113" G="11.7647057" R="0"/>
|
||||||
<Randomness>true</Randomness>
|
<Randomness>true</Randomness>
|
||||||
@@ -1423,7 +1438,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="1385.11243" Z="0"/>
|
<Orientation X="0" Y="1687.52917" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -1432,7 +1447,7 @@
|
|||||||
<c:ExplosionEffect>
|
<c:ExplosionEffect>
|
||||||
<Velocity X="0.5" Y="1" Z="0"/>
|
<Velocity X="0.5" Y="1" Z="0"/>
|
||||||
<ExplosionOrigin X="0" Y="0.900000036" Z="0"/>
|
<ExplosionOrigin X="0" Y="0.900000036" Z="0"/>
|
||||||
<TimeSinceDeath>1.8641349174045843</TimeSinceDeath>
|
<TimeSinceDeath>1.5396208215609732</TimeSinceDeath>
|
||||||
</c:ExplosionEffect>
|
</c:ExplosionEffect>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
<Resource>Models/Characters/Assault/AssaultTPose.mesh</Resource>
|
<Resource>Models/Characters/Assault/AssaultTPose.mesh</Resource>
|
||||||
@@ -1475,18 +1490,22 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="1385.11243" Z="0"/>
|
<Orientation X="0" Y="1687.52917" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
<Entity name="Asset">
|
<Entity name="Asset">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Animation/>
|
<c:Animation>
|
||||||
|
<AnimationName1></AnimationName1>
|
||||||
|
<AnimationName2></AnimationName2>
|
||||||
|
<AnimationName3></AnimationName3>
|
||||||
|
</c:Animation>
|
||||||
<c:ExplosionEffect>
|
<c:ExplosionEffect>
|
||||||
<ColorByDistance>true</ColorByDistance>
|
<ColorByDistance>true</ColorByDistance>
|
||||||
<Velocity X="0.300000012" Y="2" Z="0"/>
|
<Velocity X="0.300000012" Y="2" Z="0"/>
|
||||||
<ExplosionOrigin X="0" Y="1.30000007" Z="-0.200000003"/>
|
<ExplosionOrigin X="0" Y="1.30000007" Z="-0.200000003"/>
|
||||||
<TimeSinceDeath>1.8641349174045843</TimeSinceDeath>
|
<TimeSinceDeath>1.5396208215609732</TimeSinceDeath>
|
||||||
<EndColor A="0" B="0.333333343" G="0.933333337" R="3.92156863"/>
|
<EndColor A="0" B="0.333333343" G="0.933333337" R="3.92156863"/>
|
||||||
<Randomness>true</Randomness>
|
<Randomness>true</Randomness>
|
||||||
</c:ExplosionEffect>
|
</c:ExplosionEffect>
|
||||||
@@ -1531,7 +1550,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="1392.89258" Z="0"/>
|
<Orientation X="0" Y="1695.30933" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -1541,7 +1560,7 @@
|
|||||||
<ColorByDistance>true</ColorByDistance>
|
<ColorByDistance>true</ColorByDistance>
|
||||||
<Velocity X="0" Y="0.699999988" Z="0"/>
|
<Velocity X="0" Y="0.699999988" Z="0"/>
|
||||||
<ExplosionOrigin X="0" Y="-1.10000002" Z="0"/>
|
<ExplosionOrigin X="0" Y="-1.10000002" Z="0"/>
|
||||||
<TimeSinceDeath>1.2301962937648341</TimeSinceDeath>
|
<TimeSinceDeath>4.4522528839264339</TimeSinceDeath>
|
||||||
<ExplosionDuration>10</ExplosionDuration>
|
<ExplosionDuration>10</ExplosionDuration>
|
||||||
<EndColor A="1" B="0" G="0" R="1"/>
|
<EndColor A="1" B="0" G="0" R="1"/>
|
||||||
<RandomnessScalar>3</RandomnessScalar>
|
<RandomnessScalar>3</RandomnessScalar>
|
||||||
@@ -1589,7 +1608,7 @@
|
|||||||
<Axis X="0" Y="1" Z="0"/>
|
<Axis X="0" Y="1" Z="0"/>
|
||||||
</c:RaptorCopter>
|
</c:RaptorCopter>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Orientation X="0" Y="991.007263" Z="0"/>
|
<Orientation X="0" Y="1293.42383" Z="0"/>
|
||||||
</c:Transform>
|
</c:Transform>
|
||||||
</Components>
|
</Components>
|
||||||
<Children>
|
<Children>
|
||||||
@@ -1599,7 +1618,7 @@
|
|||||||
<ColorByDistance>true</ColorByDistance>
|
<ColorByDistance>true</ColorByDistance>
|
||||||
<Velocity X="6" Y="0.100000001" Z="0"/>
|
<Velocity X="6" Y="0.100000001" Z="0"/>
|
||||||
<ExplosionOrigin X="0" Y="-10" Z="0"/>
|
<ExplosionOrigin X="0" Y="-10" Z="0"/>
|
||||||
<TimeSinceDeath>3.4214855659573402</TimeSinceDeath>
|
<TimeSinceDeath>3.2362842141074992</TimeSinceDeath>
|
||||||
<ExponentialAccelaration>true</ExponentialAccelaration>
|
<ExponentialAccelaration>true</ExponentialAccelaration>
|
||||||
<ExplosionDuration>5</ExplosionDuration>
|
<ExplosionDuration>5</ExplosionDuration>
|
||||||
<Randomness>true</Randomness>
|
<Randomness>true</Randomness>
|
||||||
@@ -1690,6 +1709,7 @@
|
|||||||
</c:Physics>
|
</c:Physics>
|
||||||
<c:Player>
|
<c:Player>
|
||||||
<MovementSpeed>5</MovementSpeed>
|
<MovementSpeed>5</MovementSpeed>
|
||||||
|
<CurrentWeapon></CurrentWeapon>
|
||||||
</c:Player>
|
</c:Player>
|
||||||
<c:Team>
|
<c:Team>
|
||||||
<Team>
|
<Team>
|
||||||
@@ -1712,6 +1732,7 @@
|
|||||||
<Entity name="PlayerName">
|
<Entity name="PlayerName">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Text>
|
<c:Text>
|
||||||
|
<Content></Content>
|
||||||
<Resource>Fonts/DroidSans.ttf,100</Resource>
|
<Resource>Fonts/DroidSans.ttf,100</Resource>
|
||||||
<Color A="1" B="0" G="1" R="0"/>
|
<Color A="1" B="0" G="1" R="0"/>
|
||||||
</c:Text>
|
</c:Text>
|
||||||
@@ -1780,7 +1801,7 @@
|
|||||||
<c:ExplosionEffect>
|
<c:ExplosionEffect>
|
||||||
<ColorByDistance>true</ColorByDistance>
|
<ColorByDistance>true</ColorByDistance>
|
||||||
<Velocity X="0.800000012" Y="0.0379999988" Z="0"/>
|
<Velocity X="0.800000012" Y="0.0379999988" Z="0"/>
|
||||||
<TimeSinceDeath>0.8256214817261025</TimeSinceDeath>
|
<TimeSinceDeath>2.5396116058983438</TimeSinceDeath>
|
||||||
<ExplosionDuration>3.7999999523162842</ExplosionDuration>
|
<ExplosionDuration>3.7999999523162842</ExplosionDuration>
|
||||||
<EndColor A="0" B="23.5294113" G="11.7647057" R="0"/>
|
<EndColor A="0" B="23.5294113" G="11.7647057" R="0"/>
|
||||||
<Randomness>true</Randomness>
|
<Randomness>true</Randomness>
|
||||||
@@ -1823,7 +1844,11 @@
|
|||||||
</Entity>
|
</Entity>
|
||||||
<Entity name="PlayerModel">
|
<Entity name="PlayerModel">
|
||||||
<Components>
|
<Components>
|
||||||
<c:Animation/>
|
<c:Animation>
|
||||||
|
<AnimationName1></AnimationName1>
|
||||||
|
<AnimationName2></AnimationName2>
|
||||||
|
<AnimationName3></AnimationName3>
|
||||||
|
</c:Animation>
|
||||||
<c:Shielded/>
|
<c:Shielded/>
|
||||||
<c:HiddenForLocalPlayer/>
|
<c:HiddenForLocalPlayer/>
|
||||||
<c:Model>
|
<c:Model>
|
||||||
@@ -1925,6 +1950,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Props/FoliageDiff.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Props/FoliageDiff.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform/>
|
<c:Transform/>
|
||||||
</Components>
|
</Components>
|
||||||
@@ -1934,6 +1960,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Props/FoliageDiff.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Props/FoliageDiff.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="-0.177861199" Y="0" Z="-1.04673338"/>
|
<Position X="-0.177861199" Y="0" Z="-1.04673338"/>
|
||||||
@@ -1954,6 +1981,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
<Color A="0.300000012" B="1" G="1" R="1"/>
|
<Color A="0.300000012" B="1" G="1" R="1"/>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
@@ -1971,6 +1999,7 @@
|
|||||||
</c:Fill>
|
</c:Fill>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/UnitHexagon_Rotated.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/UnitHexagon_Rotated.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0" Z="0.00999999978"/>
|
<Position X="0" Y="0" Z="0.00999999978"/>
|
||||||
@@ -1986,6 +2015,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
<Color A="0.300000012" B="1" G="1" R="1"/>
|
<Color A="0.300000012" B="1" G="1" R="1"/>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
@@ -2003,6 +2033,7 @@
|
|||||||
</c:Fill>
|
</c:Fill>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/UnitHexagon_Rotated.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/UnitHexagon_Rotated.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0" Z="0.00999999978"/>
|
<Position X="0" Y="0" Z="0.00999999978"/>
|
||||||
@@ -2018,6 +2049,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
<Color A="0.699999988" B="1" G="0.200000003" R="0"/>
|
<Color A="0.699999988" B="1" G="0.200000003" R="0"/>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
@@ -2036,6 +2068,7 @@
|
|||||||
</c:Fill>
|
</c:Fill>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/UnitHexagon_Rotated.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/UnitHexagon_Rotated.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0" Z="0.00999999978"/>
|
<Position X="0" Y="0" Z="0.00999999978"/>
|
||||||
@@ -2051,6 +2084,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
<Color A="0.300000012" B="1" G="1" R="1"/>
|
<Color A="0.300000012" B="1" G="1" R="1"/>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
@@ -2068,6 +2102,7 @@
|
|||||||
</c:Fill>
|
</c:Fill>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/UnitHexagon_Rotated.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/UnitHexagon_Rotated.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0" Z="0.00999999978"/>
|
<Position X="0" Y="0" Z="0.00999999978"/>
|
||||||
@@ -2083,6 +2118,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/UnitHexagon.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
<Color A="0.699999988" B="0" G="0" R="1"/>
|
<Color A="0.699999988" B="0" G="0" R="1"/>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
@@ -2099,6 +2135,7 @@
|
|||||||
</c:Fill>
|
</c:Fill>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/UnitHexagon_Rotated.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/UnitHexagon_Rotated.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0" Z="0.00999999978"/>
|
<Position X="0" Y="0" Z="0.00999999978"/>
|
||||||
@@ -2167,6 +2204,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/ErrorTexture.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/ErrorTexture.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0" Z="-1"/>
|
<Position X="0" Y="0" Z="-1"/>
|
||||||
@@ -2178,6 +2216,7 @@
|
|||||||
<c:Button/>
|
<c:Button/>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0.388422519" Z="0.0627754927"/>
|
<Position X="0" Y="0.388422519" Z="0.0627754927"/>
|
||||||
@@ -2206,6 +2245,7 @@
|
|||||||
<c:Button/>
|
<c:Button/>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0.214031488" Z="0.0627754927"/>
|
<Position X="0" Y="0.214031488" Z="0.0627754927"/>
|
||||||
@@ -2234,6 +2274,7 @@
|
|||||||
<c:Button/>
|
<c:Button/>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0.0367300175" Z="0.0627754927"/>
|
<Position X="0" Y="0.0367300175" Z="0.0627754927"/>
|
||||||
@@ -2262,6 +2303,7 @@
|
|||||||
<c:Button/>
|
<c:Button/>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="-0.148274168" Z="0.0627754927"/>
|
<Position X="0" Y="-0.148274168" Z="0.0627754927"/>
|
||||||
@@ -2290,6 +2332,7 @@
|
|||||||
<c:Button/>
|
<c:Button/>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="-0.335298717" Z="0.0627754927"/>
|
<Position X="0" Y="-0.335298717" Z="0.0627754927"/>
|
||||||
@@ -2331,6 +2374,7 @@
|
|||||||
<Components>
|
<Components>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/ErrorTexture.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/ErrorTexture.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0" Z="-1"/>
|
<Position X="0" Y="0" Z="-1"/>
|
||||||
@@ -2342,6 +2386,7 @@
|
|||||||
<c:Button/>
|
<c:Button/>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0.375197947" Z="0.0627754927"/>
|
<Position X="0" Y="0.375197947" Z="0.0627754927"/>
|
||||||
@@ -2370,6 +2415,7 @@
|
|||||||
<c:Button/>
|
<c:Button/>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0.199327558" Z="0.0627754927"/>
|
<Position X="0" Y="0.199327558" Z="0.0627754927"/>
|
||||||
@@ -2398,6 +2444,7 @@
|
|||||||
<c:Button/>
|
<c:Button/>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="0.0159880854" Z="0.0627754927"/>
|
<Position X="0" Y="0.0159880854" Z="0.0627754927"/>
|
||||||
@@ -2426,6 +2473,7 @@
|
|||||||
<c:Button/>
|
<c:Button/>
|
||||||
<c:Sprite>
|
<c:Sprite>
|
||||||
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
<DiffuseTexture>Textures/Core/White.png</DiffuseTexture>
|
||||||
|
<GlowMap></GlowMap>
|
||||||
</c:Sprite>
|
</c:Sprite>
|
||||||
<c:Transform>
|
<c:Transform>
|
||||||
<Position X="0" Y="-0.164955258" Z="0.0627754927"/>
|
<Position X="0" Y="-0.164955258" Z="0.0627754927"/>
|
||||||
@@ -2482,6 +2530,36 @@
|
|||||||
</Components>
|
</Components>
|
||||||
<Children/>
|
<Children/>
|
||||||
</Entity>
|
</Entity>
|
||||||
|
<Entity>
|
||||||
|
<Components>
|
||||||
|
<c:Team/>
|
||||||
|
<c:Transform>
|
||||||
|
<Position X="9.42733288" Y="8.22214794" Z="0"/>
|
||||||
|
</c:Transform>
|
||||||
|
</Components>
|
||||||
|
<Children>
|
||||||
|
<Entity name="CapturePointArrow">
|
||||||
|
<Components>
|
||||||
|
<c:CapturePointArrowHUD>
|
||||||
|
<CurrentTarget>2</CurrentTarget>
|
||||||
|
</c:CapturePointArrowHUD>
|
||||||
|
<c:Model>
|
||||||
|
<Resource>Models/Weapons/Blue/AssaultWeaponBlue.mesh</Resource>
|
||||||
|
</c:Model>
|
||||||
|
<c:Team>
|
||||||
|
<Team>
|
||||||
|
<Red/>
|
||||||
|
</Team>
|
||||||
|
</c:Team>
|
||||||
|
<c:Transform>
|
||||||
|
<Scale X="10.7000008" Y="1.4000001" Z="5.30000019"/>
|
||||||
|
<Orientation X="-0.648448348" Y="-0.417814791" Z="0"/>
|
||||||
|
</c:Transform>
|
||||||
|
</Components>
|
||||||
|
<Children/>
|
||||||
|
</Entity>
|
||||||
|
</Children>
|
||||||
|
</Entity>
|
||||||
</Children>
|
</Children>
|
||||||
|
|
||||||
</Entity>
|
</Entity>
|
||||||
|
|||||||
@@ -52,6 +52,7 @@
|
|||||||
<xs:element ref="c:Button" minOccurs="0"/>
|
<xs:element ref="c:Button" minOccurs="0"/>
|
||||||
<xs:element ref="c:WeaponAttachment" minOccurs="0"/>
|
<xs:element ref="c:WeaponAttachment" minOccurs="0"/>
|
||||||
<xs:element ref="c:DefenderWeapon" minOccurs="0"/>
|
<xs:element ref="c:DefenderWeapon" minOccurs="0"/>
|
||||||
|
<xs:element ref="c:CapturePointArrowHUD" minOccurs="0"/>
|
||||||
</xs:all>
|
</xs:all>
|
||||||
</xs:complexType>
|
</xs:complexType>
|
||||||
</xs:element>
|
</xs:element>
|
||||||
|
|||||||
@@ -2,8 +2,6 @@
|
|||||||
|
|
||||||
layout (binding = 0) uniform sampler2D SceneTexture;
|
layout (binding = 0) uniform sampler2D SceneTexture;
|
||||||
layout (binding = 1) uniform sampler2D BloomTexture;
|
layout (binding = 1) uniform sampler2D BloomTexture;
|
||||||
layout (binding = 2) uniform sampler2D SceneTextureLowRes;
|
|
||||||
layout (binding = 3) uniform sampler2D BloomTextureLowRes;
|
|
||||||
uniform float Exposure;
|
uniform float Exposure;
|
||||||
uniform float Gamma;
|
uniform float Gamma;
|
||||||
|
|
||||||
@@ -17,21 +15,12 @@ void main()
|
|||||||
{
|
{
|
||||||
vec4 hdrColor = texture(SceneTexture, Input.TextureCoordinate);
|
vec4 hdrColor = texture(SceneTexture, Input.TextureCoordinate);
|
||||||
vec4 bloomColor = texture(BloomTexture, Input.TextureCoordinate);
|
vec4 bloomColor = texture(BloomTexture, Input.TextureCoordinate);
|
||||||
vec4 hdrColorLowRes = texture(SceneTextureLowRes, Input.TextureCoordinate);
|
|
||||||
vec4 bloomColorLowRes = texture(BloomTextureLowRes, Input.TextureCoordinate);
|
|
||||||
|
|
||||||
//hdrColor = hdrColor * SSAO;
|
//hdrColor = hdrColor * SSAO;
|
||||||
hdrColor += bloomColor;
|
hdrColor += bloomColor;
|
||||||
hdrColorLowRes;
|
|
||||||
|
|
||||||
float hdrColorsum = hdrColorLowRes.r + hdrColorLowRes.g + hdrColorLowRes.b;
|
|
||||||
//Toon mapping thingy
|
//Toon mapping thingy
|
||||||
vec3 result;
|
vec3 result = vec3(1.0) - exp(-hdrColor.rgb * Exposure);
|
||||||
if(hdrColorsum > 0.0) {
|
|
||||||
result = vec3(1.0) - exp(-hdrColorLowRes.rgb * Exposure);
|
|
||||||
} else {
|
|
||||||
result = vec3(1.0) - exp(-hdrColor.rgb * Exposure);
|
|
||||||
}
|
|
||||||
|
|
||||||
//gamme correction
|
//gamme correction
|
||||||
result = pow(result, vec3(1.0 / Gamma));
|
result = pow(result, vec3(1.0 / Gamma));
|
||||||
|
|||||||
@@ -0,0 +1,207 @@
|
|||||||
|
#version 430
|
||||||
|
|
||||||
|
#define MIN_AMBIENT_LIGHT 0.3
|
||||||
|
|
||||||
|
uniform mat4 M;
|
||||||
|
uniform mat4 V;
|
||||||
|
uniform mat4 P;
|
||||||
|
uniform vec4 Color;
|
||||||
|
uniform vec4 DiffuseColor;
|
||||||
|
uniform vec2 ScreenDimensions;
|
||||||
|
uniform vec4 FillColor;
|
||||||
|
uniform vec4 AmbientColor;
|
||||||
|
uniform float FillPercentage;
|
||||||
|
uniform float GlowIntensity = 10;
|
||||||
|
uniform vec3 CameraPosition;
|
||||||
|
uniform int SSAOQuality;
|
||||||
|
|
||||||
|
uniform vec2 DiffuseUVRepeat;
|
||||||
|
uniform vec2 NormalUVRepeat;
|
||||||
|
uniform vec2 SpecularUVRepeat;
|
||||||
|
uniform vec2 GlowUVRepeat;
|
||||||
|
layout (binding = 0) uniform sampler2D AOTexture;
|
||||||
|
layout (binding = 1) uniform sampler2D DiffuseTexture;
|
||||||
|
layout (binding = 2) uniform sampler2D NormalMapTexture;
|
||||||
|
layout (binding = 3) uniform sampler2D SpecularMapTexture;
|
||||||
|
layout (binding = 4) uniform sampler2D GlowMapTexture;
|
||||||
|
layout (binding = 5) uniform samplerCube CubeMap;
|
||||||
|
layout (binding = 31) uniform sampler2D ShieldBuffer;
|
||||||
|
|
||||||
|
#define TILE_SIZE 16
|
||||||
|
|
||||||
|
struct LightSource {
|
||||||
|
vec4 Position;
|
||||||
|
vec4 Direction;
|
||||||
|
vec4 Color;
|
||||||
|
float Radius;
|
||||||
|
float Intensity;
|
||||||
|
float Falloff;
|
||||||
|
int Type;
|
||||||
|
};
|
||||||
|
|
||||||
|
layout (std430, binding = 1) buffer LightBuffer
|
||||||
|
{
|
||||||
|
LightSource List[];
|
||||||
|
} LightSources;
|
||||||
|
|
||||||
|
struct LightGrid {
|
||||||
|
float Start;
|
||||||
|
float Amount;
|
||||||
|
vec2 Padding;
|
||||||
|
};
|
||||||
|
|
||||||
|
layout (std430, binding = 2) buffer LightGridBuffer
|
||||||
|
{
|
||||||
|
LightGrid Data[];
|
||||||
|
} LightGrids;
|
||||||
|
|
||||||
|
layout (std430, binding = 4) buffer LightIndexBuffer
|
||||||
|
{
|
||||||
|
float LightIndex[];
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
in VertexData{
|
||||||
|
vec3 Position;
|
||||||
|
vec3 Normal;
|
||||||
|
vec3 Tangent;
|
||||||
|
vec3 BiTangent;
|
||||||
|
vec2 TextureCoordinate;
|
||||||
|
vec4 ExplosionColor;
|
||||||
|
float ExplosionPercentageElapsed;
|
||||||
|
}Input;
|
||||||
|
|
||||||
|
out vec4 sceneColor;
|
||||||
|
out vec4 bloomColor;
|
||||||
|
|
||||||
|
struct LightResult {
|
||||||
|
vec4 Diffuse;
|
||||||
|
vec4 Specular;
|
||||||
|
};
|
||||||
|
|
||||||
|
float CalcAttenuation(float radius, float dist, float falloff) {
|
||||||
|
return 1.0 - smoothstep(radius * falloff, radius, dist);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 CalcSpecular(vec4 lightColor, vec4 viewVec, vec4 lightVec, vec4 normal) {
|
||||||
|
vec4 R = normalize( reflect(-lightVec, normal));
|
||||||
|
float RdotV = max( dot(R, viewVec), 0.0);
|
||||||
|
return lightColor * pow(RdotV, 90.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 CalcDiffuse(vec4 lightColor, vec4 lightVec, vec4 normal) {
|
||||||
|
float power = max( dot(normal, lightVec), 0.0);
|
||||||
|
return lightColor * power;
|
||||||
|
}
|
||||||
|
|
||||||
|
LightResult CalcPointLightSource(vec4 lightPos, float lightRadius, vec4 lightColor, float intensity, vec4 viewVec, vec4 position, vec4 normal, float falloff)
|
||||||
|
{
|
||||||
|
vec4 L = lightPos - position;
|
||||||
|
float dist = length(L);
|
||||||
|
L = normalize(L);
|
||||||
|
|
||||||
|
float attenuation = CalcAttenuation(lightRadius, dist, falloff);
|
||||||
|
|
||||||
|
LightResult result;
|
||||||
|
result.Diffuse = CalcDiffuse(lightColor, L, normal) * attenuation * intensity;
|
||||||
|
result.Specular = CalcSpecular(lightColor, viewVec, L, normal) * attenuation * intensity;
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
LightResult CalcDirectionalLightSource(vec4 direction, vec4 color, float intensity, vec4 viewVec, vec4 vertNormal)
|
||||||
|
{
|
||||||
|
vec4 L = normalize( -vec4(direction.xyz, 0) );
|
||||||
|
|
||||||
|
LightResult result;
|
||||||
|
result.Diffuse = CalcDiffuse(color, L, vertNormal) * intensity;
|
||||||
|
result.Specular = CalcSpecular(color, viewVec, L, vertNormal) * intensity;
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 CalcNormalMappedValue(vec3 normal, vec3 tangent, vec3 bitangent, vec2 textureCoordinate, sampler2D normalMap)
|
||||||
|
{
|
||||||
|
mat3 TBN = mat3(tangent, bitangent, normal);
|
||||||
|
vec3 NormalMap = texture(normalMap, textureCoordinate).xyz * 2.0 - vec3(1.0);
|
||||||
|
return vec4(TBN * normalize(NormalMap), 0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
void main()
|
||||||
|
{
|
||||||
|
float shieldDepthValue = texelFetch(ShieldBuffer, ivec2(gl_FragCoord.xy), 0).r;
|
||||||
|
|
||||||
|
if(shieldDepthValue < gl_FragCoord.z){
|
||||||
|
discard;
|
||||||
|
}
|
||||||
|
|
||||||
|
float ao = texelFetch(AOTexture, ivec2(gl_FragCoord.xy) >> int(SSAOQuality), 0).r;
|
||||||
|
ao = (clamp(1.0 - (1.0 - ao), 0.0, 1.0) + MIN_AMBIENT_LIGHT) / (1.0 + MIN_AMBIENT_LIGHT);
|
||||||
|
vec4 diffuseTexel = texture2D(DiffuseTexture, Input.TextureCoordinate * DiffuseUVRepeat);
|
||||||
|
vec4 glowTexel = texture2D(GlowMapTexture, Input.TextureCoordinate * GlowUVRepeat);
|
||||||
|
vec4 specularTexel = texture2D(SpecularMapTexture, Input.TextureCoordinate * SpecularUVRepeat);
|
||||||
|
vec4 position = V * M * vec4(Input.Position, 1.0);
|
||||||
|
vec4 normal = V * CalcNormalMappedValue(Input.Normal, Input.Tangent, Input.BiTangent, Input.TextureCoordinate * NormalUVRepeat, NormalMapTexture);
|
||||||
|
normal = normalize(normal);
|
||||||
|
//vec4 normal = normalize(V * vec4(Input.Normal, 0.0));
|
||||||
|
vec4 viewVec = normalize(-position);
|
||||||
|
vec3 I = normalize(vec3(M * vec4(Input.Position, 1.0)) - CameraPosition);
|
||||||
|
vec3 R = reflect(-I, Input.Normal);
|
||||||
|
//R = vec3(P * vec4(R, 1.0));
|
||||||
|
vec4 reflectionColor = texture(CubeMap, R);
|
||||||
|
|
||||||
|
vec2 tilePos;
|
||||||
|
tilePos.x = int(gl_FragCoord.x/TILE_SIZE);
|
||||||
|
tilePos.y = int(gl_FragCoord.y/TILE_SIZE);
|
||||||
|
|
||||||
|
LightResult totalLighting;
|
||||||
|
totalLighting.Diffuse = vec4(AmbientColor.rgb * ao, 1.0);
|
||||||
|
int currentTile = int(floor(gl_FragCoord.x/TILE_SIZE) + (floor(gl_FragCoord.y/TILE_SIZE) * int(ScreenDimensions.x/TILE_SIZE)));
|
||||||
|
|
||||||
|
int start = int(LightGrids.Data[currentTile].Start);
|
||||||
|
int amount = int(LightGrids.Data[currentTile].Amount);
|
||||||
|
|
||||||
|
for(int i = start; i < start + amount; i++) {
|
||||||
|
|
||||||
|
int l = int(LightIndex[i]);
|
||||||
|
LightSource light = LightSources.List[l];
|
||||||
|
|
||||||
|
LightResult light_result;
|
||||||
|
//These if statements should be removed.
|
||||||
|
if(light.Type == 1) { // point
|
||||||
|
light_result = CalcPointLightSource(V * light.Position, light.Radius, light.Color, light.Intensity, viewVec, position, normal, light.Falloff);
|
||||||
|
} else if (light.Type == 2) { //Directional
|
||||||
|
light_result = CalcDirectionalLightSource(V * light.Direction, light.Color, light.Intensity, viewVec, normal);
|
||||||
|
}
|
||||||
|
totalLighting.Diffuse += vec4(light_result.Diffuse.rgb * ao, light_result.Diffuse.a);
|
||||||
|
totalLighting.Specular += vec4(light_result.Specular.rgb * ao, light_result.Specular.a);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 color_result = mix((Color * diffuseTexel * DiffuseColor), Input.ExplosionColor, Input.ExplosionPercentageElapsed);
|
||||||
|
color_result = color_result * (totalLighting.Diffuse + (totalLighting.Specular * specularTexel));
|
||||||
|
float specularResult = (specularTexel.r + specularTexel.g + specularTexel.b)/3.0;
|
||||||
|
vec4 reflectionTotal = reflectionColor * (1-specularTexel.a) * color_result.a;
|
||||||
|
color_result = color_result * clamp(1/specularTexel.a, 0, 1) + reflectionTotal;
|
||||||
|
//vec4 color_result = (DiffuseColor + Input.ExplosionColor) * (totalLighting.Diffuse + (totalLighting.Specular * specularTexel)) * diffuseTexel * Color;
|
||||||
|
|
||||||
|
|
||||||
|
float pos = ((P * vec4(Input.Position, 1)).y + 1.0)/2.0;
|
||||||
|
|
||||||
|
if(pos <= FillPercentage) {
|
||||||
|
color_result += FillColor;
|
||||||
|
}
|
||||||
|
sceneColor = vec4(color_result.xyz, clamp(color_result.a, 0, 1));
|
||||||
|
//sceneColor = vec4(reflectionColor.xyz, 1);
|
||||||
|
color_result.xyz += glowTexel.xyz*GlowIntensity;
|
||||||
|
|
||||||
|
bloomColor = vec4(max(color_result.xyz - 1.0, 0.0), clamp(color_result.a, 0, 1));
|
||||||
|
|
||||||
|
//Tiled Debug Code
|
||||||
|
/*
|
||||||
|
if(int(gl_FragCoord.x)%16 == 0 || int(gl_FragCoord.y)%16 == 0 ) {
|
||||||
|
sceneColor += vec4(0.5, 0, 0, 0);
|
||||||
|
} else {
|
||||||
|
sceneColor += vec4(LightGrids.Data[int(tilePos.x + tilePos.y*80)].Amount/LightSources.List.length(), 0, 0, 1);
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -0,0 +1,254 @@
|
|||||||
|
#version 430
|
||||||
|
|
||||||
|
#define MIN_AMBIENT_LIGHT 0.3
|
||||||
|
|
||||||
|
uniform mat4 M;
|
||||||
|
uniform mat4 V;
|
||||||
|
uniform mat4 P;
|
||||||
|
uniform vec2 ScreenDimensions;
|
||||||
|
uniform float FillPercentage;
|
||||||
|
uniform vec4 DiffuseColor;
|
||||||
|
uniform vec4 FillColor;
|
||||||
|
uniform vec4 Color;
|
||||||
|
uniform vec4 AmbientColor;
|
||||||
|
uniform int SSAOQuality;
|
||||||
|
|
||||||
|
//Get bineded at the same time as the textures
|
||||||
|
uniform vec2 DiffuseUVRepeat1;
|
||||||
|
uniform vec2 DiffuseUVRepeat2;
|
||||||
|
uniform vec2 DiffuseUVRepeat3;
|
||||||
|
uniform vec2 NormalUVRepeat1;
|
||||||
|
uniform vec2 NormalUVRepeat2;
|
||||||
|
uniform vec2 NormalUVRepeat3;
|
||||||
|
uniform vec2 SpecularUVRepeat1;
|
||||||
|
uniform vec2 SpecularUVRepeat2;
|
||||||
|
uniform vec2 SpecularUVRepeat3;
|
||||||
|
uniform vec2 GlowUVRepeat1;
|
||||||
|
uniform vec2 GlowUVRepeat2;
|
||||||
|
uniform vec2 GlowUVRepeat3;
|
||||||
|
layout (binding = 0) uniform sampler2D AOTexture;
|
||||||
|
layout (binding = 1) uniform sampler2D SplatMapTexture;
|
||||||
|
layout (binding = 2) uniform sampler2D DiffuseTexture1;
|
||||||
|
layout (binding = 3) uniform sampler2D DiffuseTexture2;
|
||||||
|
layout (binding = 4) uniform sampler2D DiffuseTexture3;
|
||||||
|
layout (binding = 5) uniform sampler2D NormalMapTexture1;
|
||||||
|
layout (binding = 6) uniform sampler2D NormalMapTexture2;
|
||||||
|
layout (binding = 7) uniform sampler2D NormalMapTexture3;
|
||||||
|
layout (binding = 8) uniform sampler2D SpecularMapTexture1;
|
||||||
|
layout (binding = 9) uniform sampler2D SpecularMapTexture2;
|
||||||
|
layout (binding = 10) uniform sampler2D SpecularMapTexture3;
|
||||||
|
layout (binding = 11) uniform sampler2D GlowMapTexture1;
|
||||||
|
layout (binding = 12) uniform sampler2D GlowMapTexture2;
|
||||||
|
layout (binding = 13) uniform sampler2D GlowMapTexture3;
|
||||||
|
layout (binding = 13) uniform sampler2D GlowMapTexture3;
|
||||||
|
layout (binding = 31) uniform samplerCube ShieldBuffer;
|
||||||
|
|
||||||
|
#define TILE_SIZE 16
|
||||||
|
|
||||||
|
struct LightSource {
|
||||||
|
vec4 Position;
|
||||||
|
vec4 Direction;
|
||||||
|
vec4 Color;
|
||||||
|
float Radius;
|
||||||
|
float Intensity;
|
||||||
|
float Falloff;
|
||||||
|
int Type;
|
||||||
|
};
|
||||||
|
|
||||||
|
layout (std430, binding = 1) buffer LightBuffer
|
||||||
|
{
|
||||||
|
LightSource List[];
|
||||||
|
} LightSources;
|
||||||
|
|
||||||
|
struct LightGrid {
|
||||||
|
float Start;
|
||||||
|
float Amount;
|
||||||
|
vec2 Padding;
|
||||||
|
};
|
||||||
|
|
||||||
|
layout (std430, binding = 2) buffer LightGridBuffer
|
||||||
|
{
|
||||||
|
LightGrid Data[];
|
||||||
|
} LightGrids;
|
||||||
|
|
||||||
|
layout (std430, binding = 4) buffer LightIndexBuffer
|
||||||
|
{
|
||||||
|
float LightIndex[];
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
in VertexData{
|
||||||
|
vec3 Position;
|
||||||
|
vec3 Normal;
|
||||||
|
vec3 Tangent;
|
||||||
|
vec3 BiTangent;
|
||||||
|
vec2 TextureCoordinate;
|
||||||
|
vec4 ExplosionColor;
|
||||||
|
float ExplosionPercentageElapsed;
|
||||||
|
}Input;
|
||||||
|
|
||||||
|
out vec4 sceneColor;
|
||||||
|
out vec4 bloomColor;
|
||||||
|
|
||||||
|
struct LightResult {
|
||||||
|
vec4 Diffuse;
|
||||||
|
vec4 Specular;
|
||||||
|
};
|
||||||
|
|
||||||
|
float CalcAttenuation(float radius, float dist, float falloff) {
|
||||||
|
return 1.0 - smoothstep(radius * 0.3, radius, dist);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 CalcSpecular(vec4 lightColor, vec4 viewVec, vec4 lightVec, vec4 normal) {
|
||||||
|
vec4 R = normalize( reflect(-lightVec, normal));
|
||||||
|
float RdotV = max( dot(R, viewVec), 0.0);
|
||||||
|
return lightColor * pow(RdotV, 90.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 CalcDiffuse(vec4 lightColor, vec4 lightVec, vec4 normal) {
|
||||||
|
float power = max( dot(normal, lightVec), 0.0);
|
||||||
|
return lightColor * power;
|
||||||
|
}
|
||||||
|
|
||||||
|
LightResult CalcPointLightSource(vec4 lightPos, float lightRadius, vec4 lightColor, float intensity, vec4 viewVec, vec4 position, vec4 normal, float falloff)
|
||||||
|
{
|
||||||
|
vec4 L = lightPos - position;
|
||||||
|
float dist = length(L);
|
||||||
|
L = normalize(L);
|
||||||
|
|
||||||
|
float attenuation = CalcAttenuation(lightRadius, dist, falloff);
|
||||||
|
|
||||||
|
LightResult result;
|
||||||
|
result.Diffuse = CalcDiffuse(lightColor, L, normal) * attenuation * intensity;
|
||||||
|
result.Specular = CalcSpecular(lightColor, viewVec, L, normal) * attenuation * intensity;
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
LightResult CalcDirectionalLightSource(vec4 direction, vec4 color, float intensity, vec4 viewVec, vec4 vertNormal)
|
||||||
|
{
|
||||||
|
vec4 L = normalize( -vec4(direction.xyz, 0) );
|
||||||
|
|
||||||
|
LightResult result;
|
||||||
|
result.Diffuse = CalcDiffuse(color, L, vertNormal) * intensity;
|
||||||
|
result.Specular = CalcSpecular(color, viewVec, L, vertNormal) * intensity;
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 CalcNormalMappedValue(vec3 normal, vec3 tangent, vec3 bitangent, vec2 textureCoordinate, sampler2D normalMap)
|
||||||
|
{
|
||||||
|
mat3 TBN = mat3(tangent, bitangent, normal);
|
||||||
|
vec3 NormalMap = texture(normalMap, textureCoordinate).xyz * 2.0 - vec3(1.0);
|
||||||
|
return vec4(TBN * normalize(NormalMap), 0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 CalcBlendedTexel(vec4 blendValue, sampler2D R, sampler2D G, sampler2D B,
|
||||||
|
vec2 R_TileValues, vec2 G_TileValues, vec2 B_TileValues){
|
||||||
|
vec4 R_Channel = texture2D(R, Input.TextureCoordinate * R_TileValues);
|
||||||
|
vec4 G_Channel = texture2D(G, Input.TextureCoordinate * G_TileValues);
|
||||||
|
vec4 B_Channel = texture2D(B, Input.TextureCoordinate * B_TileValues);
|
||||||
|
|
||||||
|
float total = blendValue.r + blendValue.g + blendValue.b;
|
||||||
|
float totalDiv = 1.0f / total;
|
||||||
|
blendValue.r = blendValue.r * totalDiv;
|
||||||
|
blendValue.g = blendValue.g * totalDiv;
|
||||||
|
blendValue.b = blendValue.b * totalDiv;
|
||||||
|
|
||||||
|
return blendValue.r * R_Channel
|
||||||
|
+ blendValue.g * G_Channel
|
||||||
|
+ blendValue.b * B_Channel;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 CalcBlendedNormal(vec4 blendValue, sampler2D R, sampler2D G, sampler2D B,
|
||||||
|
vec2 R_TileValues, vec2 G_TileValues, vec2 B_TileValues){
|
||||||
|
mat3 TBN = mat3(Input.Tangent, Input.BiTangent, Input.Normal);
|
||||||
|
vec3 R_Channel = texture(R, Input.TextureCoordinate * R_TileValues).xyz * 2.0 - vec3(1.0);
|
||||||
|
vec3 G_Channel = texture(G, Input.TextureCoordinate * G_TileValues).xyz * 2.0 - vec3(1.0);
|
||||||
|
vec3 B_Channel = texture(B, Input.TextureCoordinate * B_TileValues).xyz * 2.0 - vec3(1.0);
|
||||||
|
|
||||||
|
float total = blendValue.r + blendValue.g + blendValue.b + blendValue.a;
|
||||||
|
float totalDiv = 1 / total;
|
||||||
|
blendValue.r = blendValue.r * totalDiv;
|
||||||
|
blendValue.g = blendValue.g * totalDiv;
|
||||||
|
blendValue.b = blendValue.b * totalDiv;
|
||||||
|
|
||||||
|
vec3 Normal_result = blendValue.r * R_Channel
|
||||||
|
+ blendValue.g * G_Channel
|
||||||
|
+ blendValue.b * B_Channel;
|
||||||
|
|
||||||
|
return vec4(TBN * normalize(Normal_result), 0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
void main()
|
||||||
|
{
|
||||||
|
float ao = texelFetch(AOTexture, ivec2(gl_FragCoord.xy) >> int(SSAOQuality), 0).r;
|
||||||
|
ao = (clamp(1.0 - (1.0 - ao), 0.0, 1.0) + MIN_AMBIENT_LIGHT) / (1.0 + MIN_AMBIENT_LIGHT);
|
||||||
|
|
||||||
|
vec4 splatTexel = texture2D(SplatMapTexture, Input.TextureCoordinate);
|
||||||
|
|
||||||
|
vec4 diffuseTexel = CalcBlendedTexel(splatTexel, DiffuseTexture1, DiffuseTexture2, DiffuseTexture3,
|
||||||
|
DiffuseUVRepeat1, DiffuseUVRepeat2, DiffuseUVRepeat3);
|
||||||
|
vec4 glowTexel = CalcBlendedTexel(splatTexel, GlowMapTexture1, GlowMapTexture2, GlowMapTexture3,
|
||||||
|
GlowUVRepeat1, GlowUVRepeat2, GlowUVRepeat3);
|
||||||
|
vec4 specularTexel = CalcBlendedTexel(splatTexel, SpecularMapTexture1, SpecularMapTexture2, SpecularMapTexture3,
|
||||||
|
SpecularUVRepeat1, SpecularUVRepeat2, SpecularUVRepeat3);
|
||||||
|
vec4 position = V * M * vec4(Input.Position, 1.0);
|
||||||
|
//vec4 normal = V * CalcNormalMappedValue(Input.Normal, Input.Tangent, Input.BiTangent, Input.TextureCoordinate, SplatMapTexture);
|
||||||
|
vec4 normal = V * CalcBlendedNormal(splatTexel, NormalMapTexture1, NormalMapTexture2, NormalMapTexture3,
|
||||||
|
NormalUVRepeat1, NormalUVRepeat2, NormalUVRepeat3);
|
||||||
|
normal = normalize(normal);
|
||||||
|
//vec4 normal = normalize(V * vec4(Input.Normal, 0.0));
|
||||||
|
vec4 viewVec = normalize(-position);
|
||||||
|
|
||||||
|
vec2 tilePos;
|
||||||
|
tilePos.x = int(gl_FragCoord.x/TILE_SIZE);
|
||||||
|
tilePos.y = int(gl_FragCoord.y/TILE_SIZE);
|
||||||
|
|
||||||
|
LightResult totalLighting;
|
||||||
|
totalLighting.Diffuse = vec4(AmbientColor.rgb * ao, 1.0);
|
||||||
|
int currentTile = int(floor(gl_FragCoord.x/TILE_SIZE) + (floor(gl_FragCoord.y/TILE_SIZE) * int(ScreenDimensions.x/TILE_SIZE)));
|
||||||
|
|
||||||
|
int start = int(LightGrids.Data[currentTile].Start);
|
||||||
|
int amount = int(LightGrids.Data[currentTile].Amount);
|
||||||
|
|
||||||
|
for(int i = start; i < start + amount; i++) {
|
||||||
|
|
||||||
|
int l = int(LightIndex[i]);
|
||||||
|
LightSource light = LightSources.List[l];
|
||||||
|
|
||||||
|
LightResult light_result;
|
||||||
|
//These if statements should be removed.
|
||||||
|
if(light.Type == 1) { // point
|
||||||
|
light_result = CalcPointLightSource(V * light.Position, light.Radius, light.Color, light.Intensity, viewVec, position, normal, light.Falloff);
|
||||||
|
} else if (light.Type == 2) { //Directional
|
||||||
|
light_result = CalcDirectionalLightSource(V * light.Direction, light.Color, light.Intensity, viewVec, normal);
|
||||||
|
}
|
||||||
|
totalLighting.Diffuse += vec4(light_result.Diffuse.rgb * ao, light_result.Diffuse.a);
|
||||||
|
totalLighting.Specular += vec4(light_result.Specular.rgb * ao, light_result.Specular.a);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 color_result = mix((Color * diffuseTexel * DiffuseColor), Input.ExplosionColor, Input.ExplosionPercentageElapsed);
|
||||||
|
color_result = color_result * (totalLighting.Diffuse + (totalLighting.Specular * specularTexel));
|
||||||
|
//vec4 color_result = (DiffuseColor + Input.ExplosionColor) * (totalLighting.Diffuse + (totalLighting.Specular * specularTexel)) * diffuseTexel * Color;
|
||||||
|
|
||||||
|
|
||||||
|
float pos = ((P * vec4(Input.Position, 1)).y + 1.0)/2.0;
|
||||||
|
|
||||||
|
if(pos <= FillPercentage) {
|
||||||
|
color_result += FillColor;
|
||||||
|
}
|
||||||
|
sceneColor = vec4(color_result.xyz, clamp(color_result.a, 0, 1));
|
||||||
|
color_result += glowTexel*3;
|
||||||
|
|
||||||
|
bloomColor = vec4(clamp(color_result.xyz - 1.0, 0, 100), 1.0);
|
||||||
|
|
||||||
|
//Tiled Debug Code
|
||||||
|
/*
|
||||||
|
if(int(gl_FragCoord.x)%16 == 0 || int(gl_FragCoord.y)%16 == 0 ) {
|
||||||
|
sceneColor += vec4(0.5, 0, 0, 0);
|
||||||
|
} else {
|
||||||
|
sceneColor += vec4(LightGrids.Data[int(tilePos.x + tilePos.y*80)].Amount/LightSources.List.length(), 0, 0, 1);
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
#version 430
|
||||||
|
|
||||||
|
uniform vec4 Color;
|
||||||
|
uniform vec4 FillColor;
|
||||||
|
uniform float FillPercentage;
|
||||||
|
uniform mat4 M;
|
||||||
|
uniform mat4 V;
|
||||||
|
uniform mat4 P;
|
||||||
|
|
||||||
|
layout (binding = 1) uniform sampler2D DiffuseTexture;
|
||||||
|
layout (binding = 2) uniform sampler2D GlowMapTexture;
|
||||||
|
|
||||||
|
|
||||||
|
in VertexData{
|
||||||
|
vec3 Position;
|
||||||
|
vec3 Normal;
|
||||||
|
vec2 TextureCoordinate;
|
||||||
|
}Input;
|
||||||
|
|
||||||
|
|
||||||
|
out vec4 sceneColor;
|
||||||
|
out vec4 bloomColor;
|
||||||
|
|
||||||
|
void main()
|
||||||
|
{
|
||||||
|
vec4 diffuseTexel = texture2D(DiffuseTexture, Input.TextureCoordinate);
|
||||||
|
vec4 glowTexel = texture2D(GlowMapTexture, Input.TextureCoordinate);
|
||||||
|
|
||||||
|
vec4 color_result = Color * diffuseTexel;
|
||||||
|
|
||||||
|
float pos = ((P * vec4(Input.Position, 1)).y + 1.0)/2.0;
|
||||||
|
if(pos <= FillPercentage) {
|
||||||
|
color_result = FillColor*diffuseTexel.a;
|
||||||
|
}
|
||||||
|
sceneColor = vec4(color_result.xyz, clamp(color_result.a, 0, 1));
|
||||||
|
|
||||||
|
//bloomColor = vec4(clamp((glowTexel.xyz*3) - 1.0, 0, 100), 1.0);
|
||||||
|
bloomColor = vec4(1.0, 1.0, 1.0, 0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -54,7 +54,7 @@ void EditorRenderSystem::Update(double dt)
|
|||||||
EntityWrapper entity(m_World, cModel.EntityID);
|
EntityWrapper entity(m_World, cModel.EntityID);
|
||||||
glm::mat4 modelMatrix = Transform::ModelMatrix(entity.ID, entity.World);
|
glm::mat4 modelMatrix = Transform::ModelMatrix(entity.ID, entity.World);
|
||||||
for (auto matGroup : model->MaterialGroups()) {
|
for (auto matGroup : model->MaterialGroups()) {
|
||||||
std::shared_ptr<ModelJob> modelJob = std::make_shared<ModelJob>(model, scene.Camera, modelMatrix, matGroup, cModel, entity.World, glm::vec4(0), 0.f);
|
std::shared_ptr<ModelJob> modelJob = std::make_shared<ModelJob>(model, scene.Camera, modelMatrix, matGroup, cModel, entity.World, glm::vec4(0), 0.f, false);
|
||||||
if (cModel["Transparent"]) {
|
if (cModel["Transparent"]) {
|
||||||
scene.Jobs.TransparentObjects.push_back(modelJob);
|
scene.Jobs.TransparentObjects.push_back(modelJob);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ void DrawColorCorrectionPass::InitializeShaderPrograms()
|
|||||||
m_ColorCorrectionProgram->Link();
|
m_ColorCorrectionProgram->Link();
|
||||||
}
|
}
|
||||||
|
|
||||||
void DrawColorCorrectionPass::Draw(GLuint sceneTexture, GLuint bloomTexture, GLuint sceneTextureLowRes, GLuint bloomTextureLowRes, GLfloat gamma, GLfloat exposure)
|
void DrawColorCorrectionPass::Draw(GLuint sceneTexture, GLuint bloomTexture, GLfloat gamma, GLfloat exposure)
|
||||||
{
|
{
|
||||||
//glBindFramebuffer(GL_FRAMEBUFFER, 0);
|
//glBindFramebuffer(GL_FRAMEBUFFER, 0);
|
||||||
GLERROR("DrawScreenQuadPass::Draw: Pre");
|
GLERROR("DrawScreenQuadPass::Draw: Pre");
|
||||||
@@ -33,10 +33,6 @@ void DrawColorCorrectionPass::Draw(GLuint sceneTexture, GLuint bloomTexture, GLu
|
|||||||
glBindTexture(GL_TEXTURE_2D, sceneTexture);
|
glBindTexture(GL_TEXTURE_2D, sceneTexture);
|
||||||
glActiveTexture(GL_TEXTURE1);
|
glActiveTexture(GL_TEXTURE1);
|
||||||
glBindTexture(GL_TEXTURE_2D, bloomTexture);
|
glBindTexture(GL_TEXTURE_2D, bloomTexture);
|
||||||
glActiveTexture(GL_TEXTURE2);
|
|
||||||
glBindTexture(GL_TEXTURE_2D, sceneTextureLowRes);
|
|
||||||
glActiveTexture(GL_TEXTURE3);
|
|
||||||
glBindTexture(GL_TEXTURE_2D, bloomTextureLowRes);
|
|
||||||
|
|
||||||
glBindVertexArray(m_ScreenQuad->VAO);
|
glBindVertexArray(m_ScreenQuad->VAO);
|
||||||
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, m_ScreenQuad->ElementBuffer);
|
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, m_ScreenQuad->ElementBuffer);
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -8,13 +8,12 @@ DrawFinalPassState::DrawFinalPassState(GLuint frameBuffer)
|
|||||||
Enable(GL_BLEND);
|
Enable(GL_BLEND);
|
||||||
BlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
BlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
||||||
Enable(GL_DEPTH_TEST);
|
Enable(GL_DEPTH_TEST);
|
||||||
DepthMask(GL_FALSE);
|
DepthMask(GL_TRUE);
|
||||||
DepthFunc(GL_LEQUAL);
|
|
||||||
Enable(GL_CULL_FACE);
|
Enable(GL_CULL_FACE);
|
||||||
Enable(GL_STENCIL_TEST);
|
// Enable(GL_STENCIL_TEST);
|
||||||
StencilFunc(GL_NOTEQUAL, 1, 0xFF);
|
// StencilFunc(GL_NOTEQUAL, 1, 0xFF);
|
||||||
StencilOp(GL_KEEP, GL_KEEP, GL_REPLACE);
|
// StencilOp(GL_KEEP, GL_KEEP, GL_REPLACE);
|
||||||
StencilMask(0xFF);
|
// StencilMask(0xFF);
|
||||||
ClearColor(glm::vec4(0.f, 0.f, 0.f, 0.f));
|
ClearColor(glm::vec4(0.f, 0.f, 0.f, 0.f));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -26,11 +25,9 @@ DrawFinalPassState::~DrawFinalPassState()
|
|||||||
DrawStencilState::DrawStencilState(GLuint frameBuffer)
|
DrawStencilState::DrawStencilState(GLuint frameBuffer)
|
||||||
{
|
{
|
||||||
BindFramebuffer(frameBuffer);
|
BindFramebuffer(frameBuffer);
|
||||||
Enable(GL_STENCIL_TEST);
|
|
||||||
StencilOp(GL_KEEP, GL_KEEP, GL_REPLACE);
|
|
||||||
StencilFunc(GL_ALWAYS, 1, 0xFF);
|
|
||||||
StencilMask(0xFF);
|
|
||||||
Enable(GL_DEPTH_TEST);
|
Enable(GL_DEPTH_TEST);
|
||||||
|
DepthMask(GL_TRUE);
|
||||||
|
Enable(GL_CULL_FACE);
|
||||||
ClearColor(glm::vec4(0.f));
|
ClearColor(glm::vec4(0.f));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -23,11 +23,12 @@ void PickingPass::InitializeTextures()
|
|||||||
glm::vec2(m_Renderer->GetViewportSize().Width, m_Renderer->GetViewportSize().Height), GL_RG8, GL_RG, GL_UNSIGNED_BYTE);
|
glm::vec2(m_Renderer->GetViewportSize().Width, m_Renderer->GetViewportSize().Height), GL_RG8, GL_RG, GL_UNSIGNED_BYTE);
|
||||||
|
|
||||||
CommonFunctions::GenerateTexture(&m_DepthBuffer, GL_CLAMP_TO_BORDER, GL_NEAREST,
|
CommonFunctions::GenerateTexture(&m_DepthBuffer, GL_CLAMP_TO_BORDER, GL_NEAREST,
|
||||||
glm::vec2(m_Renderer->GetViewportSize().Width, m_Renderer->GetViewportSize().Height), GL_DEPTH24_STENCIL8, GL_DEPTH_STENCIL, GL_UNSIGNED_INT_24_8);
|
glm::vec2(m_Renderer->GetViewportSize().Width, m_Renderer->GetViewportSize().Height), GL_DEPTH_COMPONENT32, GL_DEPTH_COMPONENT, GL_UNSIGNED_INT);
|
||||||
}
|
}
|
||||||
|
|
||||||
void PickingPass::InitializeFrameBuffers()
|
void PickingPass::InitializeFrameBuffers()
|
||||||
{
|
{
|
||||||
|
|
||||||
m_PickingBuffer.AddResource(std::shared_ptr<BufferResource>(new Texture2D(&m_DepthBuffer, GL_DEPTH_ATTACHMENT)));
|
m_PickingBuffer.AddResource(std::shared_ptr<BufferResource>(new Texture2D(&m_DepthBuffer, GL_DEPTH_ATTACHMENT)));
|
||||||
m_PickingBuffer.AddResource(std::shared_ptr<BufferResource>(new Texture2D(&m_PickingTexture, GL_COLOR_ATTACHMENT0)));
|
m_PickingBuffer.AddResource(std::shared_ptr<BufferResource>(new Texture2D(&m_PickingTexture, GL_COLOR_ATTACHMENT0)));
|
||||||
m_PickingBuffer.Generate();
|
m_PickingBuffer.Generate();
|
||||||
|
|||||||
@@ -240,6 +240,8 @@ void RenderSystem::fillModels(RenderScene::Queues &Jobs)
|
|||||||
fillColor = (glm::vec4)fillComponent["Color"];
|
fillColor = (glm::vec4)fillComponent["Color"];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool isShielded = m_World->HasComponent(cModel.EntityID, "Shielded") || m_World->HasComponent(cModel.EntityID, "Player");
|
||||||
|
|
||||||
glm::mat4 modelMatrix = Transform::ModelMatrix(cModel.EntityID, m_World);
|
glm::mat4 modelMatrix = Transform::ModelMatrix(cModel.EntityID, m_World);
|
||||||
//Loop through all materialgroups of a model
|
//Loop through all materialgroups of a model
|
||||||
for (auto matGroup : model->MaterialGroups()) {
|
for (auto matGroup : model->MaterialGroups()) {
|
||||||
@@ -255,20 +257,19 @@ void RenderSystem::fillModels(RenderScene::Queues &Jobs)
|
|||||||
cModel,
|
cModel,
|
||||||
m_World,
|
m_World,
|
||||||
fillColor,
|
fillColor,
|
||||||
fillPercentage
|
fillPercentage,
|
||||||
|
isShielded
|
||||||
));
|
));
|
||||||
if (m_World->HasComponent(cModel.EntityID, "Shield")){
|
if (m_World->HasComponent(cModel.EntityID, "Shield")){
|
||||||
explosionEffectJob->CalculateHash();
|
explosionEffectJob->CalculateHash();
|
||||||
Jobs.ShieldObjects.push_back(explosionEffectJob);
|
Jobs.ShieldObjects.push_back(explosionEffectJob);
|
||||||
} else if (m_World->HasComponent(cModel.EntityID, "Shielded")
|
} else if (isShielded) {
|
||||||
|| m_World->HasComponent(cModel.EntityID, "Player")) {
|
|
||||||
|
|
||||||
if (explosionEffectJob->Color.a != 1.f || explosionEffectJob->EndColor.a != 1.f || explosionEffectJob->DiffuseColor.a != 1.f) {
|
if (explosionEffectJob->Color.a != 1.f || explosionEffectJob->EndColor.a != 1.f || explosionEffectJob->DiffuseColor.a != 1.f) {
|
||||||
cModel["Transparent"] = true;
|
cModel["Transparent"] = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cModel["Transparent"]) {
|
if (cModel["Transparent"]) {
|
||||||
Jobs.TransparentShieldedObjects.push_back(explosionEffectJob);
|
Jobs.TransparentObjects.push_back(explosionEffectJob);
|
||||||
} else {
|
} else {
|
||||||
explosionEffectJob->CalculateHash();
|
explosionEffectJob->CalculateHash();
|
||||||
Jobs.OpaqueShieldedObjects.push_back(explosionEffectJob);
|
Jobs.OpaqueShieldedObjects.push_back(explosionEffectJob);
|
||||||
@@ -294,20 +295,20 @@ void RenderSystem::fillModels(RenderScene::Queues &Jobs)
|
|||||||
cModel,
|
cModel,
|
||||||
m_World,
|
m_World,
|
||||||
fillColor,
|
fillColor,
|
||||||
fillPercentage
|
fillPercentage,
|
||||||
|
isShielded
|
||||||
));
|
));
|
||||||
if (m_World->HasComponent(cModel.EntityID, "Shield")) {
|
if (m_World->HasComponent(cModel.EntityID, "Shield")) {
|
||||||
modelJob->CalculateHash();
|
modelJob->CalculateHash();
|
||||||
Jobs.ShieldObjects.push_back(modelJob);
|
Jobs.ShieldObjects.push_back(modelJob);
|
||||||
} else if (m_World->HasComponent(cModel.EntityID, "Shielded")
|
} else if (isShielded) {
|
||||||
|| m_World->HasComponent(cModel.EntityID, "Player")) {
|
|
||||||
|
|
||||||
if (modelJob->Color.a != 1.f || modelJob->DiffuseColor.a != 1.f) {
|
if (modelJob->Color.a != 1.f || modelJob->DiffuseColor.a != 1.f) {
|
||||||
cModel["Transparent"] = true;
|
cModel["Transparent"] = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cModel["Transparent"]) {
|
if (cModel["Transparent"]) {
|
||||||
Jobs.TransparentShieldedObjects.push_back(modelJob);
|
Jobs.TransparentObjects.push_back(modelJob);
|
||||||
} else {
|
} else {
|
||||||
modelJob->CalculateHash();
|
modelJob->CalculateHash();
|
||||||
Jobs.OpaqueShieldedObjects.push_back(modelJob);
|
Jobs.OpaqueShieldedObjects.push_back(modelJob);
|
||||||
|
|||||||
@@ -110,7 +110,7 @@ void Renderer::Draw(RenderFrame& frame)
|
|||||||
{
|
{
|
||||||
GLERROR("PRE");
|
GLERROR("PRE");
|
||||||
glBindFramebuffer(GL_FRAMEBUFFER, 0);
|
glBindFramebuffer(GL_FRAMEBUFFER, 0);
|
||||||
ImGui::Combo("Draw textures", &m_DebugTextureToDraw, "Final\0Scene\0Bloom\0SceneLowRes\0BloomLowRes\0Gaussian\0Picking\0Ambient Occlusion");
|
ImGui::Combo("Draw textures", &m_DebugTextureToDraw, "Final\0Scene\0Bloom\0Gaussian\0Picking\0Ambient Occlusion");
|
||||||
ImGui::Combo("CubeMap", &m_CubeMapTexture, "Nevada(512)\0Sky(1024)");
|
ImGui::Combo("CubeMap", &m_CubeMapTexture, "Nevada(512)\0Sky(1024)");
|
||||||
if(m_CubeMapTexture == 0) {
|
if(m_CubeMapTexture == 0) {
|
||||||
m_CubeMapPass->LoadTextures("Nevada");
|
m_CubeMapPass->LoadTextures("Nevada");
|
||||||
@@ -174,7 +174,7 @@ void Renderer::Draw(RenderFrame& frame)
|
|||||||
|
|
||||||
if (m_DebugTextureToDraw == 0) {
|
if (m_DebugTextureToDraw == 0) {
|
||||||
PerformanceTimer::StartTimer("Renderer-Color Correction Pass");
|
PerformanceTimer::StartTimer("Renderer-Color Correction Pass");
|
||||||
m_DrawColorCorrectionPass->Draw(m_DrawFinalPass->SceneTexture(), m_DrawBloomPass->GaussianTexture(), m_DrawFinalPass->SceneTextureLowRes(), m_DrawFinalPass->BloomTextureLowRes(), frame.Gamma, frame.Exposure);
|
m_DrawColorCorrectionPass->Draw(m_DrawFinalPass->SceneTexture(), m_DrawBloomPass->GaussianTexture(), frame.Gamma, frame.Exposure);
|
||||||
PerformanceTimer::StopTimer("Renderer-Color Correction Pass");
|
PerformanceTimer::StopTimer("Renderer-Color Correction Pass");
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -186,18 +186,12 @@ void Renderer::Draw(RenderFrame& frame)
|
|||||||
m_DrawScreenQuadPass->Draw(m_DrawFinalPass->BloomTexture());
|
m_DrawScreenQuadPass->Draw(m_DrawFinalPass->BloomTexture());
|
||||||
}
|
}
|
||||||
if (m_DebugTextureToDraw == 3) {
|
if (m_DebugTextureToDraw == 3) {
|
||||||
m_DrawScreenQuadPass->Draw(m_DrawFinalPass->SceneTextureLowRes());
|
|
||||||
}
|
|
||||||
if (m_DebugTextureToDraw == 4) {
|
|
||||||
m_DrawScreenQuadPass->Draw(m_DrawFinalPass->BloomTextureLowRes());
|
|
||||||
}
|
|
||||||
if (m_DebugTextureToDraw == 5) {
|
|
||||||
m_DrawScreenQuadPass->Draw(m_DrawBloomPass->GaussianTexture());
|
m_DrawScreenQuadPass->Draw(m_DrawBloomPass->GaussianTexture());
|
||||||
}
|
}
|
||||||
if (m_DebugTextureToDraw == 6) {
|
if (m_DebugTextureToDraw == 4) {
|
||||||
m_DrawScreenQuadPass->Draw(m_PickingPass->PickingTexture());
|
m_DrawScreenQuadPass->Draw(m_PickingPass->PickingTexture());
|
||||||
}
|
}
|
||||||
if (m_DebugTextureToDraw == 7) {
|
if (m_DebugTextureToDraw == 5) {
|
||||||
m_DrawScreenQuadPass->Draw(m_SSAOPass->SSAOTexture());
|
m_DrawScreenQuadPass->Draw(m_SSAOPass->SSAOTexture());
|
||||||
}
|
}
|
||||||
PerformanceTimer::StopTimer("Renderer-Misc Debug Draws");
|
PerformanceTimer::StopTimer("Renderer-Misc Debug Draws");
|
||||||
@@ -250,7 +244,7 @@ void Renderer::InitializeRenderPasses()
|
|||||||
m_LightCullingPass = new LightCullingPass(this);
|
m_LightCullingPass = new LightCullingPass(this);
|
||||||
m_CubeMapPass = new CubeMapPass(this);
|
m_CubeMapPass = new CubeMapPass(this);
|
||||||
m_SSAOPass = new SSAOPass(this, m_Config);
|
m_SSAOPass = new SSAOPass(this, m_Config);
|
||||||
m_DrawFinalPass = new DrawFinalPass(this, m_LightCullingPass, m_CubeMapPass, m_SSAOPass, m_PickingPass->DepthBuffer());
|
m_DrawFinalPass = new DrawFinalPass(this, m_LightCullingPass, m_CubeMapPass, m_SSAOPass);
|
||||||
m_DrawScreenQuadPass = new DrawScreenQuadPass(this);
|
m_DrawScreenQuadPass = new DrawScreenQuadPass(this);
|
||||||
m_DrawBloomPass = new DrawBloomPass(this, m_Config);
|
m_DrawBloomPass = new DrawBloomPass(this, m_Config);
|
||||||
m_DrawColorCorrectionPass = new DrawColorCorrectionPass(this);
|
m_DrawColorCorrectionPass = new DrawColorCorrectionPass(this);
|
||||||
|
|||||||
@@ -25,7 +25,9 @@
|
|||||||
#include "Rendering/AnimationSystem.h"
|
#include "Rendering/AnimationSystem.h"
|
||||||
#include "Network/MultiplayerSnapshotFilter.h"
|
#include "Network/MultiplayerSnapshotFilter.h"
|
||||||
#include "Game/Systems/AmmunitionHUDSystem.h"
|
#include "Game/Systems/AmmunitionHUDSystem.h"
|
||||||
|
#include "Game/Systems/CapturePointArrowHUDSystem.h"
|
||||||
#include "Game/Systems/KillFeedSystem.h"
|
#include "Game/Systems/KillFeedSystem.h"
|
||||||
|
#include "Game/Systems/BoostSystem.h"
|
||||||
#include "GUI/ButtonSystem.h"
|
#include "GUI/ButtonSystem.h"
|
||||||
#include "GUI/MainMenuSystem.h"
|
#include "GUI/MainMenuSystem.h"
|
||||||
|
|
||||||
@@ -131,7 +133,17 @@ Game::Game(int argc, char* argv[])
|
|||||||
m_SystemPipeline->AddSystem<AmmoPickupSystem>(updateOrderLevel);
|
m_SystemPipeline->AddSystem<AmmoPickupSystem>(updateOrderLevel);
|
||||||
m_SystemPipeline->AddSystem<DamageIndicatorSystem>(updateOrderLevel);
|
m_SystemPipeline->AddSystem<DamageIndicatorSystem>(updateOrderLevel);
|
||||||
m_SystemPipeline->AddSystem<AmmunitionHUDSystem>(updateOrderLevel);
|
m_SystemPipeline->AddSystem<AmmunitionHUDSystem>(updateOrderLevel);
|
||||||
|
m_SystemPipeline->AddSystem<CapturePointArrowHUDSystem>(updateOrderLevel);
|
||||||
m_SystemPipeline->AddSystem<KillFeedSystem>(updateOrderLevel);
|
m_SystemPipeline->AddSystem<KillFeedSystem>(updateOrderLevel);
|
||||||
|
m_SystemPipeline->AddSystem<LifetimeSystem>(updateOrderLevel);
|
||||||
|
m_SystemPipeline->AddSystem<CapturePointSystem>(updateOrderLevel);
|
||||||
|
m_SystemPipeline->AddSystem<CapturePointHUDSystem>(updateOrderLevel);
|
||||||
|
m_SystemPipeline->AddSystem<PickupSpawnSystem>(updateOrderLevel);
|
||||||
|
m_SystemPipeline->AddSystem<AmmoPickupSystem>(updateOrderLevel);
|
||||||
|
m_SystemPipeline->AddSystem<DamageIndicatorSystem>(updateOrderLevel);
|
||||||
|
m_SystemPipeline->AddSystem<AmmunitionHUDSystem>(updateOrderLevel);
|
||||||
|
m_SystemPipeline->AddSystem<KillFeedSystem>(updateOrderLevel);
|
||||||
|
m_SystemPipeline->AddSystem<BoostSystem>(updateOrderLevel);
|
||||||
m_SystemPipeline->AddSystem<ButtonSystem>(updateOrderLevel, m_Renderer);
|
m_SystemPipeline->AddSystem<ButtonSystem>(updateOrderLevel, m_Renderer);
|
||||||
m_SystemPipeline->AddSystem<MainMenuSystem>(updateOrderLevel, m_Renderer);
|
m_SystemPipeline->AddSystem<MainMenuSystem>(updateOrderLevel, m_Renderer);
|
||||||
// Populate Octree with collidables
|
// Populate Octree with collidables
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ AmmoPickupSystem::AmmoPickupSystem(SystemParams params)
|
|||||||
{
|
{
|
||||||
if (IsServer) {
|
if (IsServer) {
|
||||||
EVENT_SUBSCRIBE_MEMBER(m_ETriggerTouch, &AmmoPickupSystem::OnTriggerTouch);
|
EVENT_SUBSCRIBE_MEMBER(m_ETriggerTouch, &AmmoPickupSystem::OnTriggerTouch);
|
||||||
|
EVENT_SUBSCRIBE_MEMBER(m_ETriggerLeave, &AmmoPickupSystem::OnTriggerLeave);
|
||||||
}
|
}
|
||||||
if (IsClient) {
|
if (IsClient) {
|
||||||
EVENT_SUBSCRIBE_MEMBER(m_EAmmoPickup, &AmmoPickupSystem::OnAmmoPickup);
|
EVENT_SUBSCRIBE_MEMBER(m_EAmmoPickup, &AmmoPickupSystem::OnAmmoPickup);
|
||||||
@@ -14,43 +15,51 @@ AmmoPickupSystem::AmmoPickupSystem(SystemParams params)
|
|||||||
void AmmoPickupSystem::Update(double dt)
|
void AmmoPickupSystem::Update(double dt)
|
||||||
{
|
{
|
||||||
if (IsServer) {
|
if (IsServer) {
|
||||||
for (auto it = m_ETriggerTouchVector.begin(); it != m_ETriggerTouchVector.end(); ++it) {
|
auto it = m_ETriggerTouchVector.begin();
|
||||||
auto& ammoPickupPosition = *it;
|
while (it != m_ETriggerTouchVector.end()) {
|
||||||
//set the double timer value (value 3)
|
auto& somePickup = *it;
|
||||||
ammoPickupPosition.DecreaseThisRespawnTimer -= dt;
|
somePickup.DecreaseThisRespawnTimer -= dt;
|
||||||
if (ammoPickupPosition.DecreaseThisRespawnTimer < 0.0) {
|
if (somePickup.DecreaseThisRespawnTimer < 0.0) {
|
||||||
//spawn and delete the vector item
|
|
||||||
auto entityFile = ResourceManager::Load<EntityFile>("Schema/Entities/AmmoPickup.xml");
|
auto entityFile = ResourceManager::Load<EntityFile>("Schema/Entities/AmmoPickup.xml");
|
||||||
EntityFileParser parser(entityFile);
|
EntityFileParser parser(entityFile);
|
||||||
EntityID ammoPickupID = parser.MergeEntities(m_World);
|
EntityID ammoPickupID = parser.MergeEntities(m_World);
|
||||||
|
|
||||||
//let the world know a pickup has spawned (graphics effects, etc)
|
//let the world know a pickup has spawned
|
||||||
Events::PickupSpawned ePickupSpawned;
|
Events::PickupSpawned ePickupSpawned;
|
||||||
ePickupSpawned.Pickup = EntityWrapper(m_World, ammoPickupID);
|
ePickupSpawned.Pickup = EntityWrapper(m_World, ammoPickupID);
|
||||||
m_EventBroker->Publish(ePickupSpawned);
|
m_EventBroker->Publish(ePickupSpawned);
|
||||||
|
|
||||||
//set values from the old entity to the new entity
|
//copy values from the old entity to the new entity
|
||||||
auto& newAmmoPickupEntity = EntityWrapper(m_World, ammoPickupID);
|
auto& newAmmoPickupEntity = EntityWrapper(m_World, ammoPickupID);
|
||||||
newAmmoPickupEntity["Transform"]["Position"] = ammoPickupPosition.Pos;
|
newAmmoPickupEntity["Transform"]["Position"] = somePickup.Pos;
|
||||||
newAmmoPickupEntity["AmmoPickup"]["AmmoGain"] = ammoPickupPosition.AmmoGain;
|
newAmmoPickupEntity["AmmoPickup"]["AmmoGain"] = somePickup.AmmoGain;
|
||||||
newAmmoPickupEntity["AmmoPickup"]["RespawnTimer"] = ammoPickupPosition.RespawnTimer;
|
newAmmoPickupEntity["AmmoPickup"]["RespawnTimer"] = somePickup.RespawnTimer;
|
||||||
m_World->SetParent(newAmmoPickupEntity.ID, ammoPickupPosition.parentID);
|
m_World->SetParent(newAmmoPickupEntity.ID, somePickup.parentID);
|
||||||
|
|
||||||
//erase the current element (AmmoPickupPosition)
|
//erase the current element (somePickup)
|
||||||
m_ETriggerTouchVector.erase(it);
|
it = m_ETriggerTouchVector.erase(it);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
it++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//still touching m_PickupAtMaximum?
|
||||||
|
for (auto& it = m_PickupAtMaximum.begin(); it != m_PickupAtMaximum.end(); ++it) {
|
||||||
|
if (!it->player.Valid()) {
|
||||||
|
m_PickupAtMaximum.erase(it);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
if ((int)it->player["AssaultWeapon"]["Ammo"] < (int)it->player["AssaultWeapon"]["MaxAmmo"]) {
|
||||||
|
DoPickup(it->player, it->trigger);
|
||||||
|
m_PickupAtMaximum.erase(it);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool AmmoPickupSystem::OnTriggerTouch(Events::TriggerTouch& e)
|
bool AmmoPickupSystem::OnTriggerTouch(Events::TriggerTouch& e)
|
||||||
{
|
{
|
||||||
/*if (e.Entity != LocalPlayer) {
|
|
||||||
return false;
|
|
||||||
}*/
|
|
||||||
|
|
||||||
if (!e.Entity.Valid()) {
|
if (!e.Entity.Valid()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -61,30 +70,13 @@ bool AmmoPickupSystem::OnTriggerTouch(Events::TriggerTouch& e)
|
|||||||
if (!e.Trigger.HasComponent("AmmoPickup")) {
|
if (!e.Trigger.HasComponent("AmmoPickup")) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
int maxWeaponAmmo = (int)e.Entity["AssaultWeapon"]["MaxAmmo"];
|
|
||||||
int& currentAmmo = (int)e.Entity["AssaultWeapon"]["Ammo"];
|
|
||||||
|
|
||||||
int ammoGiven = 0.01*(double)e.Trigger["AmmoPickup"]["AmmoGain"] * maxWeaponAmmo;
|
//if at maxammo, save the trigger-touch to a vector since standing inside it will not re-trigger the trigger
|
||||||
//cant pick up ammopacks if you are already at MaxAmmo
|
if ((int)e.Entity["AssaultWeapon"]["Ammo"] >= (int)e.Entity["AssaultWeapon"]["MaxAmmo"]) {
|
||||||
if (currentAmmo >= maxWeaponAmmo) {
|
m_PickupAtMaximum.push_back({ e.Entity, e.Trigger });
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
DoPickup(e.Entity, e.Trigger);
|
||||||
//personEntered = e.Entity, thingEntered = e.Trigger
|
|
||||||
Events::AmmoPickup ePlayerAmmoPickup;
|
|
||||||
ePlayerAmmoPickup.AmmoGain = ammoGiven;
|
|
||||||
ePlayerAmmoPickup.Player = e.Entity;
|
|
||||||
m_EventBroker->Publish(ePlayerAmmoPickup);
|
|
||||||
//immediately give the player the ammo
|
|
||||||
//currentAmmo = std::min(currentAmmo + ammoGiven, maxWeaponAmmo);
|
|
||||||
|
|
||||||
//copy position, ammogain, respawntimer (twice since one of the values will be counted down to 0, the other will be set in the new object)
|
|
||||||
//we need to copy all values since each value can be different for each ammoPickup
|
|
||||||
m_ETriggerTouchVector.push_back({ e.Trigger["Transform"]["Position"], e.Trigger["AmmoPickup"]["AmmoGain"],
|
|
||||||
e.Trigger["AmmoPickup"]["RespawnTimer"], e.Trigger["AmmoPickup"]["RespawnTimer"], m_World->GetParent(e.Trigger.ID) });
|
|
||||||
|
|
||||||
//delete the ammopickup
|
|
||||||
m_World->DeleteEntity(e.Trigger.ID);
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -107,3 +99,39 @@ bool AmmoPickupSystem::OnAmmoPickup(Events::AmmoPickup & e)
|
|||||||
currentAmmo = std::min(currentAmmo + e.AmmoGain, maxWeaponAmmo);
|
currentAmmo = std::min(currentAmmo + e.AmmoGain, maxWeaponAmmo);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool AmmoPickupSystem::OnTriggerLeave(Events::TriggerLeave& e) {
|
||||||
|
if (!e.Trigger.HasComponent("AmmoPickup")) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
//triggerleave erases possible m_PickupAtMaximum
|
||||||
|
for (auto& it = m_PickupAtMaximum.begin(); it != m_PickupAtMaximum.end(); ++it) {
|
||||||
|
if (it->trigger.ID == e.Trigger.ID && it->player.ID == e.Entity.ID) {
|
||||||
|
m_PickupAtMaximum.erase(it);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
void AmmoPickupSystem::DoPickup(EntityWrapper &player, EntityWrapper &trigger) {
|
||||||
|
int maxWeaponAmmo = (int)player["AssaultWeapon"]["MaxAmmo"];
|
||||||
|
int& currentAmmo = (int)player["AssaultWeapon"]["Ammo"];
|
||||||
|
int ammoGiven = 0.01*(double)trigger["AmmoPickup"]["AmmoGain"] * maxWeaponAmmo;
|
||||||
|
|
||||||
|
Events::AmmoPickup ePlayerAmmoPickup;
|
||||||
|
ePlayerAmmoPickup.AmmoGain = ammoGiven;
|
||||||
|
ePlayerAmmoPickup.Player = player;
|
||||||
|
m_EventBroker->Publish(ePlayerAmmoPickup);
|
||||||
|
|
||||||
|
//immediately give the player the ammo (on server)
|
||||||
|
currentAmmo = std::min(currentAmmo + ammoGiven, maxWeaponAmmo);
|
||||||
|
|
||||||
|
//copy position, ammogain, respawntimer (twice since one of the values will be counted down to 0, the other will be set in the new object)
|
||||||
|
//we need to copy all values since each value can be different for each ammoPickup
|
||||||
|
m_ETriggerTouchVector.push_back({ (glm::vec3)trigger["Transform"]["Position"], trigger["AmmoPickup"]["AmmoGain"],
|
||||||
|
trigger["AmmoPickup"]["RespawnTimer"], trigger["AmmoPickup"]["RespawnTimer"], m_World->GetParent(trigger.ID) });
|
||||||
|
|
||||||
|
//delete the ammopickup
|
||||||
|
m_World->DeleteEntity(trigger.ID);
|
||||||
|
}
|
||||||
|
|||||||
@@ -0,0 +1,63 @@
|
|||||||
|
#include "Systems/BoostSystem.h"
|
||||||
|
|
||||||
|
BoostSystem::BoostSystem(SystemParams params)
|
||||||
|
: System(params)
|
||||||
|
{
|
||||||
|
EVENT_SUBSCRIBE_MEMBER(m_EPlayerDamage, &BoostSystem::OnPlayerDamage);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool BoostSystem::OnPlayerDamage(Events::PlayerDamage& e)
|
||||||
|
{
|
||||||
|
if (e.Victim.ID == e.Inflictor.ID) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (!e.Victim.Valid() && e.Victim != LocalPlayer && !e.Victim.IsChildOf(LocalPlayer)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (!e.Inflictor.Valid() || !e.Victim.Valid()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
//if its not friendly fire, return
|
||||||
|
if ((int)m_World->GetComponent(e.Inflictor.ID, "Team")["Team"] != (int)m_World->GetComponent(e.Victim.ID, "Team")["Team"]) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
//determine the inflictors class
|
||||||
|
auto className = DetermineClass(e.Inflictor);
|
||||||
|
if (className == "") {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
//get the XML file, example: "Schema/Entities/BoostclassName.xml"
|
||||||
|
std::string classXML = "Schema/Entities/" + className + ".xml";
|
||||||
|
|
||||||
|
//check if player already has a child with the component, if so delete that child
|
||||||
|
auto playerBoostAssaultEntity = e.Victim.FirstChildByName(className);
|
||||||
|
if (playerBoostAssaultEntity.Valid()) {
|
||||||
|
m_World->DeleteEntity(playerBoostAssaultEntity.ID);
|
||||||
|
}
|
||||||
|
//load boost XML file, set it entity parented with the victim player
|
||||||
|
auto entityFile = ResourceManager::Load<EntityFile>(classXML);
|
||||||
|
EntityFileParser parser(entityFile);
|
||||||
|
EntityID boostAssaultEntity = parser.MergeEntities(m_World);
|
||||||
|
m_World->SetName(boostAssaultEntity, className);
|
||||||
|
m_World->SetParent(boostAssaultEntity, e.Victim.ID);
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
std::string BoostSystem::DetermineClass(EntityWrapper inflictorPlayer)
|
||||||
|
{
|
||||||
|
//determine the class based on what component the inflictor-player has
|
||||||
|
if (m_World->HasComponent(inflictorPlayer.ID, "DashAbility")) {
|
||||||
|
return "BoostAssault";
|
||||||
|
}
|
||||||
|
if (m_World->HasComponent(inflictorPlayer.ID, "ShieldAbility")) {
|
||||||
|
return "BoostDefender";
|
||||||
|
}
|
||||||
|
if (m_World->HasComponent(inflictorPlayer.ID, "SprintAbility")) {
|
||||||
|
return "BoostSniper";
|
||||||
|
}
|
||||||
|
return "";
|
||||||
|
}
|
||||||
@@ -0,0 +1,183 @@
|
|||||||
|
#include "Systems/CapturePointArrowHUDSystem.h"
|
||||||
|
|
||||||
|
CapturePointArrowHUDSystem::CapturePointArrowHUDSystem(SystemParams params)
|
||||||
|
: System(params)
|
||||||
|
, ImpureSystem()
|
||||||
|
{
|
||||||
|
EVENT_SUBSCRIBE_MEMBER(m_ECapturedEvent, &CapturePointArrowHUDSystem::OnCapturePointCaptured);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void CapturePointArrowHUDSystem::Update(double dt)
|
||||||
|
{
|
||||||
|
bool loadCheck = true;
|
||||||
|
int redTeamEnum;
|
||||||
|
int blueTeamEnum;
|
||||||
|
int spectatorTeamEnum;
|
||||||
|
|
||||||
|
//Get list for all CapturePointArrowHUDComponents
|
||||||
|
auto arrowHUDs = m_World->GetComponents("CapturePointArrowHUD");
|
||||||
|
auto capturePoints = m_World->GetComponents("CapturePoint");
|
||||||
|
if(arrowHUDs == nullptr) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
for(auto& cArrowHUD : *arrowHUDs) {
|
||||||
|
//Get what team the current arrow corresponds to
|
||||||
|
EntityWrapper arrowEntity = EntityWrapper(m_World, cArrowHUD.EntityID);
|
||||||
|
if (!arrowEntity.Valid()) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if(!arrowEntity.HasComponent("Team")) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
auto cTeam = arrowEntity["Team"];
|
||||||
|
int currentTeam = (int)cTeam["Team"];
|
||||||
|
|
||||||
|
if (loadCheck) {
|
||||||
|
redTeamEnum = (int)cTeam["Team"].Enum("Red");
|
||||||
|
blueTeamEnum = (int)cTeam["Team"].Enum("Blue");
|
||||||
|
spectatorTeamEnum = (int)cTeam["Team"].Enum("Spectator");
|
||||||
|
loadCheck = false;
|
||||||
|
|
||||||
|
|
||||||
|
if (!m_InitialtargetsSet) {
|
||||||
|
std::unordered_map<int, glm::vec3> blueTargets, redTargets;
|
||||||
|
EntityWrapper homeBlue, homeRed;
|
||||||
|
int lastCP = -INFINITY;
|
||||||
|
int firstCP = INFINITY;
|
||||||
|
|
||||||
|
for (auto& cCP : *capturePoints) {
|
||||||
|
auto homePointTeam = (int)cCP["HomePointForTeam"];
|
||||||
|
EntityWrapper capturePointEntity = EntityWrapper(m_World, cCP.EntityID);
|
||||||
|
int capturePointID = (int)capturePointEntity["CapturePoint"]["CapturePointNumber"];
|
||||||
|
|
||||||
|
if(capturePointID < firstCP) {
|
||||||
|
firstCP = capturePointID;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(capturePointID > lastCP) {
|
||||||
|
lastCP = capturePointID;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!capturePointEntity.HasComponent("Team")) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
int currentOwner = (int)capturePointEntity["Team"]["Team"];
|
||||||
|
|
||||||
|
if(currentOwner != redTeamEnum) {
|
||||||
|
//This capturePoint is not owned by the red team and is therefor an eligible target for red team
|
||||||
|
glm::vec3 targetPos = Transform::AbsolutePosition(capturePointEntity);
|
||||||
|
redTargets.insert(std::pair<int, glm::vec3>(capturePointID, targetPos));
|
||||||
|
}
|
||||||
|
if(currentOwner != blueTeamEnum) {
|
||||||
|
//This capturePoint is not owned by the blue team and is therefor an eligible target for blue team
|
||||||
|
glm::vec3 targetPos = Transform::AbsolutePosition(capturePointEntity);
|
||||||
|
blueTargets.insert(std::pair<int, glm::vec3>(capturePointID, targetPos));
|
||||||
|
}
|
||||||
|
|
||||||
|
if(homePointTeam == blueTeamEnum) {
|
||||||
|
//CP is the home point for blue team.
|
||||||
|
homeBlue = capturePointEntity;
|
||||||
|
} else if (homePointTeam == redTeamEnum) {
|
||||||
|
//CP is the home point for red team.
|
||||||
|
homeRed = capturePointEntity;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(!homeRed.Valid() || !homeBlue.Valid()) {
|
||||||
|
//One or both teams have no home point, cant continue
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
std::unordered_map<int, glm::vec3>::const_iterator got;
|
||||||
|
//Find next target for red team.
|
||||||
|
if((int)homeRed["CapturePoint"]["CapturePointNumber"] == lastCP) {
|
||||||
|
//Red home base is the last capture point, count back from lastCP and find next target
|
||||||
|
for (int i = lastCP; i >= firstCP; i--) {
|
||||||
|
got = redTargets.find(i);
|
||||||
|
if(got == redTargets.end()) {
|
||||||
|
continue;
|
||||||
|
} else {
|
||||||
|
m_RedTeamCurrentTarget = got->second;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else if ((int)homeRed["CapturePoint"]["CapturePointNumber"] == firstCP) {
|
||||||
|
//Red home is the first capture point, count forward from firstCP and find next target.
|
||||||
|
for (int i = firstCP; i <= lastCP; i++) {
|
||||||
|
got = redTargets.find(i);
|
||||||
|
if(got == redTargets.end()) {
|
||||||
|
//Target was not found, try the next one after that.
|
||||||
|
continue;
|
||||||
|
} else {
|
||||||
|
m_RedTeamCurrentTarget = got->second;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//Find next target for blue team
|
||||||
|
if ((int)homeBlue["CapturePoint"]["CapturePointNumber"] == lastCP) {
|
||||||
|
//Red home base is the last capture point, count back from lastCP and find next target
|
||||||
|
for (int i = lastCP; i >= firstCP; i--) {
|
||||||
|
got = blueTargets.find(i);
|
||||||
|
if (got == blueTargets.end()) {
|
||||||
|
continue;
|
||||||
|
} else {
|
||||||
|
m_BlueTeamCurrentTarget = got->second;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else if ((int)homeBlue["CapturePoint"]["CapturePointNumber"] == firstCP) {
|
||||||
|
//Red home is the first capture point, count forward from firstCP and find next target.
|
||||||
|
for (int i = firstCP; i <= lastCP; i++) {
|
||||||
|
got = blueTargets.find(i);
|
||||||
|
if (got == blueTargets.end()) {
|
||||||
|
//Target was not found, try the next one after that.
|
||||||
|
continue;
|
||||||
|
} else {
|
||||||
|
m_BlueTeamCurrentTarget = got->second;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//if red team, get red team next point, otherwise blue team next point.
|
||||||
|
//Untill this is awailable we will just use the hardcoded value in the component.
|
||||||
|
//This will also give us a position, so we wont need to loop through all capturePoints.
|
||||||
|
glm::vec3 pos;
|
||||||
|
if(currentTeam == redTeamEnum) {
|
||||||
|
pos = m_RedTeamCurrentTarget;
|
||||||
|
} else if (currentTeam == blueTeamEnum) {
|
||||||
|
pos = m_BlueTeamCurrentTarget;
|
||||||
|
}
|
||||||
|
|
||||||
|
glm::vec3& arrowOri = arrowEntity["Transform"]["Orientation"];
|
||||||
|
glm::vec3 lookVector = glm::normalize(Transform::AbsolutePosition(arrowEntity) - pos); //Maybe should be player instead
|
||||||
|
float pitch = std::asin(-lookVector.y);
|
||||||
|
float yaw = std::atan2(lookVector.x, lookVector.z);
|
||||||
|
arrowOri.x = pitch;
|
||||||
|
arrowOri.y = yaw;
|
||||||
|
arrowOri.z = 0.f;
|
||||||
|
EntityWrapper parent = arrowEntity.Parent();
|
||||||
|
if (parent.Valid()) {
|
||||||
|
arrowOri -= Transform::AbsoluteOrientationEuler(parent);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
bool CapturePointArrowHUDSystem::OnCapturePointCaptured(Events::Captured& e)
|
||||||
|
{
|
||||||
|
if(!e.BlueTeamNextCapturePoint.Valid() || !e.RedTeamNextCapturePoint.Valid()) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
m_RedTeamCurrentTarget = Transform::AbsolutePosition(e.RedTeamNextCapturePoint);
|
||||||
|
m_BlueTeamCurrentTarget = Transform::AbsolutePosition(e.BlueTeamNextCapturePoint);
|
||||||
|
|
||||||
|
m_InitialtargetsSet = true;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
@@ -103,9 +103,8 @@ void CapturePointSystem::UpdateComponent(EntityWrapper& capturePointEntity, Comp
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (m_RecentlyCapturedNeedNextCapturePointNow) {
|
if (m_RecentlyCapturedNeedNextCapturePointNow) {
|
||||||
m_CapturedEvent.NextCapturePoint = m_CapturedEvent.TeamNumberThatCapturedCapturePoint == blueTeam ?
|
m_CapturedEvent.BlueTeamNextCapturePoint = m_CapturePointNumberToEntityMap[nextPossibleCapturePoint["Blue"]];
|
||||||
m_CapturePointNumberToEntityMap[nextPossibleCapturePoint["Blue"]] :
|
m_CapturedEvent.RedTeamNextCapturePoint = m_CapturePointNumberToEntityMap[nextPossibleCapturePoint["Red"]];
|
||||||
m_CapturePointNumberToEntityMap[nextPossibleCapturePoint["Red"]];
|
|
||||||
m_EventBroker->Publish(m_CapturedEvent);
|
m_EventBroker->Publish(m_CapturedEvent);
|
||||||
m_RecentlyCapturedNeedNextCapturePointNow = false;
|
m_RecentlyCapturedNeedNextCapturePointNow = false;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -30,6 +30,11 @@ bool HealthSystem::OnPlayerDamaged(Events::PlayerDamage& e)
|
|||||||
|
|
||||||
ComponentWrapper cHealth = e.Victim["Health"];
|
ComponentWrapper cHealth = e.Victim["Health"];
|
||||||
double& health = cHealth["Health"];
|
double& health = cHealth["Health"];
|
||||||
|
//if player has the boost from a defender, subtract the damage taken by StrengthOfEffect amount
|
||||||
|
auto playerBoostDefenderEntity = e.Victim.FirstChildByName("BoostDefender");
|
||||||
|
if (playerBoostDefenderEntity.Valid()) {
|
||||||
|
e.Damage -= (double)playerBoostDefenderEntity["BoostDefender"]["StrengthOfEffect"];
|
||||||
|
}
|
||||||
health -= e.Damage;
|
health -= e.Damage;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
@@ -5,18 +5,19 @@ PickupSpawnSystem::PickupSpawnSystem(SystemParams params)
|
|||||||
{
|
{
|
||||||
if (IsServer) {
|
if (IsServer) {
|
||||||
EVENT_SUBSCRIBE_MEMBER(m_ETriggerTouch, &PickupSpawnSystem::OnTriggerTouch);
|
EVENT_SUBSCRIBE_MEMBER(m_ETriggerTouch, &PickupSpawnSystem::OnTriggerTouch);
|
||||||
|
EVENT_SUBSCRIBE_MEMBER(m_ETriggerLeave, &PickupSpawnSystem::OnTriggerLeave);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void PickupSpawnSystem::Update(double dt)
|
void PickupSpawnSystem::Update(double dt)
|
||||||
{
|
{
|
||||||
if (IsServer) {
|
if (IsServer) {
|
||||||
for (auto it = m_ETriggerTouchVector.begin(); it != m_ETriggerTouchVector.end(); ++it) {
|
auto it = m_ETriggerTouchVector.begin();
|
||||||
auto& healthPickupPosition = *it;
|
while (it != m_ETriggerTouchVector.end()) {
|
||||||
//set the double timer value (value 3)
|
auto& somePickup = *it;
|
||||||
healthPickupPosition.DecreaseThisRespawnTimer -= dt;
|
somePickup.DecreaseThisRespawnTimer -= dt;
|
||||||
if (healthPickupPosition.DecreaseThisRespawnTimer < 0) {
|
if (somePickup.DecreaseThisRespawnTimer < 0.0) {
|
||||||
//spawn and delete the vector item
|
//spawn the new healthPickup
|
||||||
auto entityFile = ResourceManager::Load<EntityFile>("Schema/Entities/HealthPickup.xml");
|
auto entityFile = ResourceManager::Load<EntityFile>("Schema/Entities/HealthPickup.xml");
|
||||||
EntityFileParser parser(entityFile);
|
EntityFileParser parser(entityFile);
|
||||||
EntityID healthPickupID = parser.MergeEntities(m_World);
|
EntityID healthPickupID = parser.MergeEntities(m_World);
|
||||||
@@ -26,45 +27,76 @@ void PickupSpawnSystem::Update(double dt)
|
|||||||
ePickupSpawned.Pickup = EntityWrapper(m_World, healthPickupID);
|
ePickupSpawned.Pickup = EntityWrapper(m_World, healthPickupID);
|
||||||
m_EventBroker->Publish(ePickupSpawned);
|
m_EventBroker->Publish(ePickupSpawned);
|
||||||
|
|
||||||
//set values from the old entity to the new entity
|
//copy values from the old entity to the new entity
|
||||||
auto& newHealthPickupEntity = EntityWrapper(m_World, healthPickupID);
|
auto& newHealthPickupEntity = EntityWrapper(m_World, healthPickupID);
|
||||||
newHealthPickupEntity["Transform"]["Position"] = healthPickupPosition.Pos;
|
newHealthPickupEntity["Transform"]["Position"] = somePickup.Pos;
|
||||||
newHealthPickupEntity["HealthPickup"]["HealthGain"] = healthPickupPosition.HealthGain;
|
newHealthPickupEntity["HealthPickup"]["HealthGain"] = somePickup.HealthGain;
|
||||||
newHealthPickupEntity["HealthPickup"]["RespawnTimer"] = healthPickupPosition.RespawnTimer;
|
newHealthPickupEntity["HealthPickup"]["RespawnTimer"] = somePickup.RespawnTimer;
|
||||||
m_World->SetParent(newHealthPickupEntity.ID, healthPickupPosition.parentID);
|
m_World->SetParent(newHealthPickupEntity.ID, somePickup.parentID);
|
||||||
|
|
||||||
//erase the current element (healthPickupPosition)
|
//erase the current element (somePickup)
|
||||||
m_ETriggerTouchVector.erase(it);
|
it = m_ETriggerTouchVector.erase(it);
|
||||||
|
} else {
|
||||||
|
it++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//still touching PickupAtMaximum?
|
||||||
|
for (auto& it = m_PickupAtMaximum.begin(); it != m_PickupAtMaximum.end(); ++it) {
|
||||||
|
if (!it->player.Valid()) {
|
||||||
|
m_PickupAtMaximum.erase(it);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
if ((double)it->player["Health"]["Health"] < (double)it->player["Health"]["MaxHealth"]) {
|
||||||
|
DoPickup(it->player, it->trigger);
|
||||||
|
m_PickupAtMaximum.erase(it);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool PickupSpawnSystem::OnTriggerTouch(Events::TriggerTouch& e)
|
bool PickupSpawnSystem::OnTriggerTouch(Events::TriggerTouch& e)
|
||||||
{
|
{
|
||||||
if (!e.Trigger.HasComponent("HealthPickup")) {
|
if (!e.Trigger.HasComponent("HealthPickup")) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
double healthGiven = 0.01*(double)e.Trigger["HealthPickup"]["HealthGain"] * (double)e.Entity["Health"]["MaxHealth"];
|
//if at maxhealth, save the trigger-touch to a vector since standing inside it will not re-trigger the trigger
|
||||||
//cant pick up healthpacks if you are already at MaxHealth
|
|
||||||
if ((double)e.Entity["Health"]["Health"] >= (double)e.Entity["Health"]["MaxHealth"]) {
|
if ((double)e.Entity["Health"]["Health"] >= (double)e.Entity["Health"]["MaxHealth"]) {
|
||||||
|
m_PickupAtMaximum.push_back({ e.Entity, e.Trigger });
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
//personEntered = e.Entity, thingEntered = e.Trigger
|
DoPickup(e.Entity, e.Trigger);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
bool PickupSpawnSystem::OnTriggerLeave(Events::TriggerLeave& e)
|
||||||
|
{
|
||||||
|
if (!e.Trigger.HasComponent("HealthPickup")) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
//triggerleave erases possible m_PickupAtMaximum
|
||||||
|
for (auto& it = m_PickupAtMaximum.begin(); it != m_PickupAtMaximum.end(); ++it) {
|
||||||
|
if (it->trigger.ID == e.Trigger.ID && it->player.ID == e.Entity.ID) {
|
||||||
|
m_PickupAtMaximum.erase(it);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
void PickupSpawnSystem::DoPickup(EntityWrapper &player, EntityWrapper &trigger)
|
||||||
|
{
|
||||||
|
double healthGiven = 0.01*(double)trigger["HealthPickup"]["HealthGain"] * (double)player["Health"]["MaxHealth"];
|
||||||
|
|
||||||
|
//only the server will increase the players hp and set it in the next delta
|
||||||
Events::PlayerHealthPickup ePlayerHealthPickup;
|
Events::PlayerHealthPickup ePlayerHealthPickup;
|
||||||
ePlayerHealthPickup.HealthAmount = healthGiven;
|
ePlayerHealthPickup.HealthAmount = healthGiven;
|
||||||
ePlayerHealthPickup.Player = e.Entity;
|
ePlayerHealthPickup.Player = player;
|
||||||
m_EventBroker->Publish(ePlayerHealthPickup);
|
m_EventBroker->Publish(ePlayerHealthPickup);
|
||||||
|
|
||||||
//copy position, healthgain, respawntimer (twice since one of the values will be counted down to 0, the other will be set in the new object)
|
//copy position, healthgain, respawntimer (twice since one of the values will be counted down to 0, the other will be set in the new object)
|
||||||
//we need to copy all values since each value can be different for each healthPickup
|
//we need to copy all values since each value can be different for each healthPickup
|
||||||
m_ETriggerTouchVector.push_back({ (glm::vec3)e.Trigger["Transform"]["Position"], e.Trigger["HealthPickup"]["HealthGain"],
|
m_ETriggerTouchVector.push_back({ (glm::vec3)trigger["Transform"]["Position"], trigger["HealthPickup"]["HealthGain"],
|
||||||
e.Trigger["HealthPickup"]["RespawnTimer"], e.Trigger["HealthPickup"]["RespawnTimer"], m_World->GetParent(e.Trigger.ID) });
|
trigger["HealthPickup"]["RespawnTimer"], trigger["HealthPickup"]["RespawnTimer"], m_World->GetParent(trigger.ID) });
|
||||||
|
|
||||||
//delete the healthpickup
|
//delete the healthpickup
|
||||||
m_World->DeleteEntity(e.Trigger.ID);
|
m_World->DeleteEntity(trigger.ID);
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -62,6 +62,12 @@ void PlayerMovementSystem::updateMovementControllers(double dt)
|
|||||||
float playerMovementSpeed = player["Player"]["MovementSpeed"];
|
float playerMovementSpeed = player["Player"]["MovementSpeed"];
|
||||||
float playerCrouchSpeed = player["Player"]["CrouchSpeed"];
|
float playerCrouchSpeed = player["Player"]["CrouchSpeed"];
|
||||||
glm::vec3& wishDirection = player["Player"]["CurrentWishDirection"];
|
glm::vec3& wishDirection = player["Player"]["CurrentWishDirection"];
|
||||||
|
auto playerBoostAssaultEntity = player.FirstChildByName("BoostAssault");
|
||||||
|
if (playerBoostAssaultEntity.Valid()) {
|
||||||
|
playerMovementSpeed *= (double)playerBoostAssaultEntity["BoostAssault"]["StrengthOfEffect"];
|
||||||
|
playerCrouchSpeed *= (double)playerBoostAssaultEntity["BoostAssault"]["StrengthOfEffect"];
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
if (player.HasComponent("Physics")) {
|
if (player.HasComponent("Physics")) {
|
||||||
ComponentWrapper cPhysics = player["Physics"];
|
ComponentWrapper cPhysics = player["Physics"];
|
||||||
@@ -113,6 +119,10 @@ void PlayerMovementSystem::updateMovementControllers(double dt)
|
|||||||
//if doubleTapped do Assault Dash - but only boost maximum 50.0f
|
//if doubleTapped do Assault Dash - but only boost maximum 50.0f
|
||||||
float doubleTapDashBoost = controller->AssaultDashDoubleTapped() ? 40.0f : 1.0f;
|
float doubleTapDashBoost = controller->AssaultDashDoubleTapped() ? 40.0f : 1.0f;
|
||||||
accelerationSpeed = glm::min(doubleTapDashBoost*glm::min(accelerationSpeed, addSpeed), 50.0f);
|
accelerationSpeed = glm::min(doubleTapDashBoost*glm::min(accelerationSpeed, addSpeed), 50.0f);
|
||||||
|
//if player has Boost from an Assault class, accelerate the player faster
|
||||||
|
if (playerBoostAssaultEntity.Valid()) {
|
||||||
|
accelerationSpeed *= (double)playerBoostAssaultEntity["BoostAssault"]["StrengthOfEffect"];
|
||||||
|
}
|
||||||
velocity += accelerationSpeed * wishDirection;
|
velocity += accelerationSpeed * wishDirection;
|
||||||
ImGui::Text("velocity: (%f, %f, %f) |%f|", velocity.x, velocity.y, velocity.z, glm::length(velocity));
|
ImGui::Text("velocity: (%f, %f, %f) |%f|", velocity.x, velocity.y, velocity.z, glm::length(velocity));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -366,9 +366,10 @@ bool AssaultWeaponBehaviour::shoot(double damage)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check for friendly fire
|
|
||||||
|
// If friendly fire - reduce damage to 0 (needed to make Boosts, Ammosharing work)
|
||||||
if ((ComponentInfo::EnumType)victim["Team"]["Team"] == (ComponentInfo::EnumType)m_Player["Team"]["Team"]) {
|
if ((ComponentInfo::EnumType)victim["Team"]["Team"] == (ComponentInfo::EnumType)m_Player["Team"]["Team"]) {
|
||||||
return false;
|
damage = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Deal damage!
|
// Deal damage!
|
||||||
|
|||||||
Reference in New Issue
Block a user