Shader linking i guess
This commit is contained in:
@@ -5,7 +5,8 @@
|
||||
|
||||
CMOBAPlayer::CMOBAPlayer()
|
||||
{
|
||||
m_hCuboid = g_pPhysics->CreateBall({1});
|
||||
m_hCuboid = g_pPhysics->CreateCube({1,1,1});
|
||||
|
||||
}
|
||||
|
||||
CMOBAPlayer::~CMOBAPlayer()
|
||||
@@ -16,25 +17,16 @@ CMOBAPlayer::~CMOBAPlayer()
|
||||
void CMOBAPlayer::Spawn()
|
||||
{
|
||||
CBaseEntity::Spawn();
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
<<<<<<< HEAD
|
||||
>>>>>>> a2652ed (merges)
|
||||
SetPhysics(k_EPhysics_Static);
|
||||
SetModel("game/core/models/sphere.fmdl");
|
||||
SetScale(1);
|
||||
SetAbsOrigin({0,-14.5, 0});
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
=======
|
||||
SetModel("game/core/models/sphere.fmdl");
|
||||
SetScale(1);
|
||||
SetAbsOrigin({0,-11.5, 0});
|
||||
>>>>>>> c251089 (different stuff in physics)
|
||||
>>>>>>> a2652ed (merges)
|
||||
SetThink(Think);
|
||||
};
|
||||
|
||||
bool CMOBAPlayer::CheckMask( HCollider hCollider )
|
||||
{
|
||||
return true;
|
||||
};
|
||||
|
||||
void CMOBAPlayer::Think( float fDelta )
|
||||
{
|
||||
BaseClass::Think(fDelta);
|
||||
@@ -47,18 +39,11 @@ void CMOBAPlayer::Think( float fDelta )
|
||||
|
||||
vPosition.x += m_vMovementVector.x*fDelta*5;
|
||||
vPosition.z += m_vMovementVector.z*fDelta*5;
|
||||
<<<<<<< HEAD
|
||||
SetAbsOrigin(vPosition);
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
=======
|
||||
CastResult_t result = g_pPhysicsWorld->ShapeCast(m_hCuboid, {0,0,0,1}, vPosition, {vPosition.x, vPosition.y, -100});
|
||||
CastResult_t result = g_pPhysicsWorld->ShapeCast(m_hCuboid, {0,0,0,1}, vPosition, {vPosition.x, vPosition.y, -100}, CheckMask);
|
||||
if (result.m_bIsHit)
|
||||
SetAbsOrigin(result.m_vCollisionPoint);
|
||||
else
|
||||
SetAbsOrigin(vPosition);
|
||||
>>>>>>> c251089 (different stuff in physics)
|
||||
>>>>>>> a2652ed (merges)
|
||||
};
|
||||
|
||||
LINK_ENTITY_TO_CLASS(player, CMOBAPlayer)
|
||||
|
||||
Reference in New Issue
Block a user