2112 by PUSH.
This commit is contained in:
parent
481b5a284c
commit
e8a475419f
@ -930,7 +930,11 @@ bool netprot::Deserialize(Chat* chat, char* buf, uint32_t *buflen) {
|
|||||||
|
|
||||||
std::cout << messsize << ": " << &buf[1 + sizeof(uint64_t) * 3] << std::endl;
|
std::cout << messsize << ": " << &buf[1 + sizeof(uint64_t) * 3] << std::endl;
|
||||||
|
|
||||||
strcpy(chat->mess, messsize, &buf[1 + sizeof(uint64_t) * 3]);
|
char* ciboire = &buf[1 + sizeof(uint64_t) * 3];
|
||||||
|
|
||||||
|
std::cout << ciboire << std::endl;
|
||||||
|
|
||||||
|
strcpy(chat->mess, 140, ciboire);
|
||||||
|
|
||||||
//*buflen = messsize + sizeof(uint64_t) * 3 + 1;
|
//*buflen = messsize + sizeof(uint64_t) * 3 + 1;
|
||||||
|
|
||||||
|
@ -1419,7 +1419,7 @@ void Engine::Render(float elapsedTime) {
|
|||||||
if (m_syncs.count(sync.timestamp)) {
|
if (m_syncs.count(sync.timestamp)) {
|
||||||
Sync comp = m_syncs[sync.timestamp];
|
Sync comp = m_syncs[sync.timestamp];
|
||||||
|
|
||||||
std::cout << "HP: " << sync.hp << std::endl;
|
//std::cout << "HP: " << sync.hp << std::endl;
|
||||||
//m_player.InflictDamage(sync.hp - comp.hp);
|
//m_player.InflictDamage(sync.hp - comp.hp);
|
||||||
|
|
||||||
Vector3f diff = sync.position - comp.position;
|
Vector3f diff = sync.position - comp.position;
|
||||||
@ -1436,7 +1436,7 @@ void Engine::Render(float elapsedTime) {
|
|||||||
|
|
||||||
m_syncs.erase(sync.timestamp);
|
m_syncs.erase(sync.timestamp);
|
||||||
}
|
}
|
||||||
else SystemNotification("sync be no good.");
|
//else SystemNotification("sync be no good.");
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case OUTPUT:
|
case OUTPUT:
|
||||||
@ -1473,6 +1473,7 @@ void Engine::Render(float elapsedTime) {
|
|||||||
else if (x == MAX_BULLETS - 1) { // S'il y a pas d'espace dans l'array, prendre la place de la première balle de l'array.
|
else if (x == MAX_BULLETS - 1) { // S'il y a pas d'espace dans l'array, prendre la place de la première balle de l'array.
|
||||||
m_bullets[0]->~Bullet();
|
m_bullets[0]->~Bullet();
|
||||||
m_bullets[0] = bult;
|
m_bullets[0] = bult;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
m_audio.Create3DAudioObj(m_powpow, AUDIO_PATH "pow.wav", bull.pos, bull.dir * 10, false, .5f);
|
m_audio.Create3DAudioObj(m_powpow, AUDIO_PATH "pow.wav", bull.pos, bull.dir * 10, false, .5f);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user