From b06afc53ce5fa36544218b524f963725bf180fc1 Mon Sep 17 00:00:00 2001 From: Clyne Sullivan Date: Wed, 30 Sep 2015 21:02:26 -0400 Subject: holes --- src/main.cpp | 1 + src/world.cpp | 7 +++++++ 2 files changed, 8 insertions(+) (limited to 'src') diff --git a/src/main.cpp b/src/main.cpp index d39bd92..c1b22af 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -100,6 +100,7 @@ int main(int argc, char *argv[]){ test->addLayer(400); test->addLayer(100); test->addPlatform(150,100,100,10); + test->addHole(100,150); currentWorld=test; IndoorWorld *iw=new IndoorWorld(); diff --git a/src/world.cpp b/src/world.cpp index 2a0e471..5ba2e7d 100644 --- a/src/world.cpp +++ b/src/world.cpp @@ -239,6 +239,13 @@ World *World::goInsideStructure(Player *p){ return this; } +void World::addHole(unsigned int start,unsigned int end){ + unsigned int i; + for(i=start;i