From 0030be2a1b7ff98c375dea0b955ae32656e21feb Mon Sep 17 00:00:00 2001 From: Miriam Ruiz Date: Sun, 7 Dec 2008 03:09:48 +0100 Subject: [PATCH] Fixed includes and bugs so that it compiles --- command_line.cxx | 2 ++ config.hxx | 1 + lisp_reader.cxx | 1 + unix_system.cxx | 1 + vector.cxx | 9 --------- world.cxx | 1 + 6 files changed, 6 insertions(+), 9 deletions(-) diff --git a/command_line.cxx b/command_line.cxx index 3224e59..43ce19b 100644 --- a/command_line.cxx +++ b/command_line.cxx @@ -19,7 +19,9 @@ #include #include +#include #include +#include #include "settings.hxx" #include "command_line.hxx" diff --git a/config.hxx b/config.hxx index d8c9b7e..3e0e151 100644 --- a/config.hxx +++ b/config.hxx @@ -21,6 +21,7 @@ #define CONFIG_HH #include +#include class Config { diff --git a/lisp_reader.cxx b/lisp_reader.cxx index 78ff609..421619a 100644 --- a/lisp_reader.cxx +++ b/lisp_reader.cxx @@ -19,6 +19,7 @@ #include "construo_error.hxx" #include "lisp_reader.hxx" +#include LispReader::LispReader (lisp_object_t* l) : lst (l) diff --git a/unix_system.cxx b/unix_system.cxx index 9a189ab..9bc4146 100644 --- a/unix_system.cxx +++ b/unix_system.cxx @@ -18,6 +18,7 @@ // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include +#include #include #include #include diff --git a/vector.cxx b/vector.cxx index eee35f5..9a7967c 100644 --- a/vector.cxx +++ b/vector.cxx @@ -63,11 +63,7 @@ float CL_Vector::dot(const CL_Vector& v) const float CL_Vector::angle(const CL_Vector& v) const { - #ifdef WIN32 return (float)acos(dot(v)/(norm()*v.norm())); - #else - return std::acos(dot(v)/(norm()*v.norm())); - #endif } CL_Vector CL_Vector::cross(const CL_Vector& v) const @@ -83,13 +79,8 @@ CL_Vector CL_Vector::rotate(float angle, const CL_Vector& a) const { CL_Vector tmp = CL_Vector(); - #ifdef WIN32 float s = (float)sin(angle); float c = (float)cos(angle); - #else - float s = std::sin(angle); - float c = std::cos(angle); - #endif tmp.x = x*(a.x*a.x*(1-c)+c) + y*(a.x*a.y*(1-c)-a.z*s) + z*(a.x*a.z*(1-c)+a.y*s); tmp.y = x*(a.y*a.x*(1-c)+a.z*s) + y*(a.y*a.y*(1-c)+c) + z*(a.y*a.z*(1-c)-a.x*s); diff --git a/world.cxx b/world.cxx index 1be5204..5b4e298 100644 --- a/world.cxx +++ b/world.cxx @@ -34,6 +34,7 @@ #include "rect.hxx" #include "rect_collider.hxx" #include "string_utils.hxx" +#include World* World::current_world = 0; -- 2.11.4.GIT