diff options
author | Clyne Sullivan <tullivan99@gmail.com> | 2016-06-02 07:46:42 -0400 |
---|---|---|
committer | Clyne Sullivan <tullivan99@gmail.com> | 2016-06-02 07:46:42 -0400 |
commit | aa9f53090bc0bd3421bf84930a9dc6b2223033f9 (patch) | |
tree | bf52436dc5a88cc94ca939f83652901c56c6fe2e | |
parent | 2e6369f4dbe2b49a3cb8bec3bacd6559c9733a55 (diff) |
windows builddd
-rw-r--r-- | brice.dat | 5 | ||||
-rw-r--r-- | main.cpp | 10 | ||||
-rw-r--r-- | src/entities.cpp | 4 | ||||
-rw-r--r-- | src/ui.cpp | 2 | ||||
-rw-r--r-- | src/ui_action.cpp | 2 | ||||
-rw-r--r-- | src/world.cpp | 20 | ||||
-rwxr-xr-x | win32/main.exe | bin | 6027539 -> 6226815 bytes |
7 files changed, 20 insertions, 23 deletions
@@ -1,5 +0,0 @@ -2 -canJump -1 -canSprint -1 @@ -295,8 +295,10 @@ int main(int argc, char *argv[]){ } }).detach(); - while (gameRunning) + while (gameRunning) { render(); + ui::handleEvents(); + } // put away the brice for later game::briceSave(); @@ -327,7 +329,7 @@ void mainLoop(void){ return; } else { // handle keypresses - currentWorld could change here - ui::handleEvents(); + //ui::handleEvents(); if (game::time::tickHasPassed()) logic(); @@ -359,8 +361,8 @@ void render() { floor(offset.x+SCREEN_WIDTH/2), //right floor(offset.y-SCREEN_HEIGHT/2), //bottom floor(offset.y+SCREEN_HEIGHT/2), //top - 10.0f, //near - -10.0f); //far + 10.0, //near + -10.0); //far glm::mat4 view = glm::lookAt(glm::vec3(0,0,0.0f), //pos glm::vec3(0,0,-10.0f), //looking at diff --git a/src/entities.cpp b/src/entities.cpp index 2d9de76..f59b462 100644 --- a/src/entities.cpp +++ b/src/entities.cpp @@ -133,10 +133,10 @@ void Entity::die(void) alive = false; health = 0; - if (xmle) { + /*if (xmle) { xmle->SetAttribute("alive", false); currentXMLDoc.SaveFile(currentXML.c_str(), false); - } + }*/ } bool Entity::isAlive(void) const @@ -1152,7 +1152,7 @@ EXIT: toggleBlackFast(); player->canMove = true; }; - + while(SDL_PollEvent(&e)) { switch(e.type) { diff --git a/src/ui_action.cpp b/src/ui_action.cpp index ebdc705..9029907 100644 --- a/src/ui_action.cpp +++ b/src/ui_action.cpp @@ -124,7 +124,7 @@ void actionAttack(void) ui::toggleWhiteFast(); } } else { - ui::dialogBox(player->name, "", false, "%s doesn't appear to be in the mood for fighting...", m->name); + ui::dialogBox(player->name, "", false, "%s doesn't appear to be in the mood for fighting...", m->name.c_str()); } ACTION_EPILOUGE; diff --git a/src/world.cpp b/src/world.cpp index 5ab20ed..698db7c 100644 --- a/src/world.cpp +++ b/src/world.cpp @@ -712,12 +712,12 @@ void World::draw(Player *p) glEnableVertexAttribArray(worldShader_attribute_coord); glEnableVertexAttribArray(worldShader_attribute_tex); - uint ps = particles.size(); + uint ps = 0;particles.size(); uint pss = ps * 6 * 5; - uint pc = 0; + //uint pc = 0; std::vector<GLfloat> partVec(pss); - GLfloat *pIndex = &partVec[0]; + /*GLfloat *pIndex = &partVec[0]; for (const auto &p : particles) { pc += 30; @@ -727,7 +727,7 @@ void World::draw(Player *p) break; } p.draw(pIndex); - } + }*/ glVertexAttribPointer(worldShader_attribute_coord, 3, GL_FLOAT, GL_FALSE, 5 * sizeof(GLfloat), &partVec[0]); glVertexAttribPointer(worldShader_attribute_tex, 2, GL_FLOAT, GL_FALSE, 5 * sizeof(GLfloat), &partVec[3]); @@ -2193,15 +2193,15 @@ loadWorldFromXMLNoSave(std::string path) { vil = vil->NextSiblingElement(); } - std::ifstream dat ((_currentXML + ".dat").data()); - if (dat.good()) { - dat.close(); - tmp->load(); - } - if (!loadedLeft && !loadedRight) { currentXML = _currentXML; currentXMLRaw = _currentXMLRaw; + + std::ifstream dat ((_currentXML + ".dat").data()); + if (dat.good()) { + dat.close(); + tmp->load(); + } } else { delete _currentXMLDoc; } diff --git a/win32/main.exe b/win32/main.exe Binary files differindex f77663e..1e00343 100755 --- a/win32/main.exe +++ b/win32/main.exe |