You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
32 lines
710 B
32 lines
710 B
1 year ago
|
#define OLC_PGE_APPLICATION
|
||
|
#include "olcPixelGameEngine.h"
|
||
|
#define OLC_SOUNDWAVE
|
||
|
#include "olcSoundWaveEngine.h"
|
||
|
#include "VirusAttack.h"
|
||
|
|
||
|
VirusAttack::VirusAttack()
|
||
|
{
|
||
|
// Name your application
|
||
|
sAppName = "olcCodeJam 2023 Entry";
|
||
|
}
|
||
|
|
||
|
bool VirusAttack::OnUserCreate(){
|
||
|
// Called once at the start, so create things here
|
||
|
return true;
|
||
|
}
|
||
|
|
||
|
bool VirusAttack::OnUserUpdate(float fElapsedTime){
|
||
|
// Called once per frame, draws random coloured pixels
|
||
|
for (int x = 0; x < ScreenWidth(); x++)
|
||
|
for (int y = 0; y < ScreenHeight(); y++)
|
||
|
Draw(x, y, olc::Pixel(rand() % 256, rand() % 256, rand() % 256));
|
||
|
return true;
|
||
|
}
|
||
|
|
||
|
int main()
|
||
|
{
|
||
|
VirusAttack app;
|
||
|
if (app.Construct(256, 240, 4, 4))
|
||
|
app.Start();
|
||
|
return 0;
|
||
|
}
|