Esempio n. 1
0
void TWorld::timerEvent(QTimerEvent *) {
    Time += 1;
    if (Players.size() < 2) {
        return; // rount not started yet
    }
    if (Time % 20 == 0) {
        UpdatePlanetEnergy(); // update energy every second
    }
    ProcessShips();
    CheckRoundEnd();
    SendWorld();
}
void ShaderToonBuilding::AssignExceptMaterial() const
{
	SendWorldViewProjection(_effect_handle_holder->effect_handle());
	SendWorld(_effect_handle_holder->effect_handle());
	SendLightDirection(_effect_handle_holder->effect_handle());
	SendEyePosition(_effect_handle_holder->effect_handle());
	SendAmbientColor(_effect_handle_holder->effect_handle());
	SendDiffuseCubeMap(_effect_handle_holder->effect_handle());
	SendAlbedoTexture(_effect_handle_holder->effect_handle());
	SendDirtyTexture(_effect_handle_holder->effect_handle());
	SendNormalTexture(_effect_handle_holder->effect_handle());
	SendToonTexture(_effect_handle_holder->effect_handle());
	SendTexcoordMove(_effect_handle_holder->effect_handle());
	SendView(_effect_handle_holder->effect_handle());
}