Updated with back-end changes.
This commit is contained in:
@@ -214,7 +214,12 @@ void TestLevel::Setup(lwe::GpuInterface* inf)
|
||||
}
|
||||
*/
|
||||
|
||||
//AddSystem(new lwe::AudioSystem());
|
||||
lwe::AudioSystem *audioSys = new lwe::AudioSystem();
|
||||
lwe::AudioSource src("Song", "sample");
|
||||
src.Play();
|
||||
audioSys->AddSource(src);
|
||||
|
||||
AddSystem(audioSys);
|
||||
AddSystem(new lwe::SkyboxSystem());
|
||||
AddSystem(new lwe::RigidBodySystem(true));
|
||||
AddSystem(new lwe::CameraSystem());
|
||||
@@ -344,13 +349,13 @@ void TestLevel::Setup(lwe::GpuInterface* inf)
|
||||
|
||||
//ent->AddComponent(new lwe::Networked(false, false, lwe::EndpointOwner::SERVICE));
|
||||
|
||||
/*
|
||||
lwe::AudioSource3D* as = new lwe::AudioSource3D("Song", "sample", 20.0f);
|
||||
as->Pause();
|
||||
as->EnableLoop(true);
|
||||
as->EnableAutoDelete(false);
|
||||
//as->EnablePanning(false);
|
||||
//as->EnableAttenuation(false);
|
||||
ent.AddComponent(as);
|
||||
*/
|
||||
|
||||
lwe::Health* entHealth = new lwe::Health(100, 100);
|
||||
ent.AddComponent(entHealth);
|
||||
@@ -511,9 +516,11 @@ void TestLevel::OnUpdate(lwe::RenderWindow* win, ehs::Input* input, const float
|
||||
|
||||
if (cooldown <= 0.0f && mouse->IsDown(ehs::Mouse::LMB)) // Left Mouse Button
|
||||
{
|
||||
/*
|
||||
lwe::AudioSource* gunshot = new lwe::AudioSource("Gunshot_" + ehs::Str_8::FromNum(count), "Gunshot");
|
||||
gunshot->SetVolume(1.0f);
|
||||
ply->AddComponent(gunshot);
|
||||
*/
|
||||
|
||||
lwe::Entity* bullet = CreateEntity("Bullet", "Bullet_" + ehs::Str_8::FromNum(count++));
|
||||
bullet->SetPos(ply->GetPos() + cam->GetTransform().GetForward() * 2.0f);
|
||||
|
Reference in New Issue
Block a user