This commit is contained in:
Claudel-D-Roy 2023-12-13 13:17:29 -05:00
parent a6b6ac870a
commit 8fbb92ec5b

View File

@ -124,17 +124,15 @@ void RemotePlayer::Render(TextureAtlas& atlas, Shader& shader, Transformation tr
bool isLeft = side.y > 0; bool isLeft = side.y > 0;
time += elapsedTime; time += elapsedTime;
if (time >= 200) if (time >= 100)
{ {
time -= 200; time -= 100;
if (!current.states.shooting) if (!current.states.shooting)
Shooting = false; Shooting = false;
else else
Shooting = !Shooting; Shooting = !Shooting;
} }
if (angle >= 0.75) //Face - side positif if (angle >= 0.75) //Face - side positif
{ {
if(current.states.shooting){ if(current.states.shooting){
@ -142,6 +140,8 @@ void RemotePlayer::Render(TextureAtlas& atlas, Shader& shader, Transformation tr
index = 17; index = 17;
else else
index = 9; index = 9;
std::cout << "face" << std::endl;
} }
else if (current.states.jumpshot) { else if (current.states.jumpshot) {
if (Shooting) if (Shooting)
@ -162,6 +162,8 @@ void RemotePlayer::Render(TextureAtlas& atlas, Shader& shader, Transformation tr
index = 18; index = 18;
else else
index = 10; index = 10;
std::cout << "Frontleft" << std::endl;
} }
else if (current.states.jumpshot) { else if (current.states.jumpshot) {
if (Shooting) if (Shooting)
@ -182,6 +184,9 @@ void RemotePlayer::Render(TextureAtlas& atlas, Shader& shader, Transformation tr
index = 20; index = 20;
else else
index = 12; index = 12;
std::cout << "ProfileLeft" << std::endl;
} }
else if (current.states.jumpshot ) { else if (current.states.jumpshot ) {
if (Shooting) if (Shooting)
@ -202,6 +207,8 @@ void RemotePlayer::Render(TextureAtlas& atlas, Shader& shader, Transformation tr
index = 22; index = 22;
else else
index = 14; index = 14;
std::cout << "BackLeft" << std::endl;
} }
else if (current.states.jumpshot) { else if (current.states.jumpshot) {
if (Shooting) if (Shooting)
@ -221,6 +228,8 @@ void RemotePlayer::Render(TextureAtlas& atlas, Shader& shader, Transformation tr
index = 24; index = 24;
else else
index = 16; index = 16;
std::cout << "Dos" << std::endl;
} }
else if (current.states.jumpshot) { else if (current.states.jumpshot) {
if (Shooting) if (Shooting)
@ -241,6 +250,8 @@ void RemotePlayer::Render(TextureAtlas& atlas, Shader& shader, Transformation tr
index = 19; index = 19;
else else
index = 11; index = 11;
std::cout << "FrontRight" << std::endl;
} }
else if (current.states.jumpshot) { else if (current.states.jumpshot) {
if (Shooting) if (Shooting)
@ -261,6 +272,8 @@ void RemotePlayer::Render(TextureAtlas& atlas, Shader& shader, Transformation tr
index = 21; index = 21;
else else
index = 13; index = 13;
std::cout << "ProfileRight" << std::endl;
} }
else if (current.states.jumpshot) { else if (current.states.jumpshot) {
if (Shooting) if (Shooting)
@ -281,6 +294,10 @@ void RemotePlayer::Render(TextureAtlas& atlas, Shader& shader, Transformation tr
index = 23; index = 23;
else else
index = 15; index = 15;
std::cout << "BackRight" << std::endl;
} }
else if (current.states.jumpshot) { else if (current.states.jumpshot) {
if (Shooting) if (Shooting)