mirror of
https://github.com/TombEngine/TombEngine.git
synced 2025-04-28 15:57:59 +03:00
Update level.cpp
This commit is contained in:
parent
02a21ac33c
commit
fca7839dc3
1 changed files with 8 additions and 6 deletions
|
@ -491,6 +491,7 @@ void LoadObjects()
|
||||||
|
|
||||||
void LoadCameras()
|
void LoadCameras()
|
||||||
{
|
{
|
||||||
|
// Load cameras.
|
||||||
int cameraCount = ReadInt32();
|
int cameraCount = ReadInt32();
|
||||||
TENLog("Cameras: " + std::to_string(cameraCount), LogLevel::Info);
|
TENLog("Cameras: " + std::to_string(cameraCount), LogLevel::Info);
|
||||||
|
|
||||||
|
@ -510,11 +511,10 @@ void LoadCameras()
|
||||||
g_GameScriptEntities->AddName(camera.Name, camera);
|
g_GameScriptEntities->AddName(camera.Name, camera);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Load spot cameras.
|
||||||
int spotCameraCount = ReadInt32();
|
int spotCameraCount = ReadInt32();
|
||||||
TENLog("Spot cameras: " + std::to_string(cameraCount), LogLevel::Info);
|
TENLog("Spot cameras: " + std::to_string(cameraCount), LogLevel::Info);
|
||||||
|
|
||||||
ReadBytes(SpotCam, NumberSpotcams * sizeof(SPOTCAM));
|
|
||||||
// Load spot cameras.
|
|
||||||
NumberSpotcams = spotCameraCount;
|
NumberSpotcams = spotCameraCount;
|
||||||
for (int i = 0; i < spotCameraCount; i++)
|
for (int i = 0; i < spotCameraCount; i++)
|
||||||
{
|
{
|
||||||
|
@ -534,11 +534,13 @@ void LoadCameras()
|
||||||
ReadInt16();
|
ReadInt16();
|
||||||
}
|
}
|
||||||
|
|
||||||
int skinkCount = ReadInt32();
|
// TODO: Not in this function.
|
||||||
TENLog("Sinks: " + std::to_string(skinkCount), LogLevel::Info);
|
// Load sinks.
|
||||||
|
int sinkCount = ReadInt32();
|
||||||
|
TENLog("Sinks: " + std::to_string(sinkCount), LogLevel::Info);
|
||||||
|
|
||||||
g_Level.Sinks.reserve(skinkCount);
|
g_Level.Sinks.reserve(sinkCount);
|
||||||
for (int i = 0; i < skinkCount; i++)
|
for (int i = 0; i < sinkCount; i++)
|
||||||
{
|
{
|
||||||
auto& sink = g_Level.Sinks.emplace_back();
|
auto& sink = g_Level.Sinks.emplace_back();
|
||||||
sink.Position.x = ReadInt32();
|
sink.Position.x = ReadInt32();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue