From aa33bc22ec4cd14e200ba9e09c43e884a2101a74 Mon Sep 17 00:00:00 2001 From: Stijn Buys Date: Mon, 22 Oct 2007 17:40:39 +0000 Subject: basis system console --- src/client/Makefile.am | 2 +- src/client/video.cc | 7 +++---- src/client/view.cc | 4 ---- 3 files changed, 4 insertions(+), 9 deletions(-) (limited to 'src/client') diff --git a/src/client/Makefile.am b/src/client/Makefile.am index 37bafcf..a86d8f0 100644 --- a/src/client/Makefile.am +++ b/src/client/Makefile.am @@ -5,7 +5,7 @@ osirion_LDADD = $(top_builddir)/src/game/libgame.la \ $(top_builddir)/src/gl/libosiriongl.la -lSDL osirion_SOURCES = camera.cc camera.h client.cc client.h input.cc input.h \ main.cc shipdrawer.cc shipdrawer.h stardrawer.cc stardrawer.h video.cc video.h \ - view.cc view.h + view.cc view.h console.cc console.h diff --git a/src/client/video.cc b/src/client/video.cc index 1dc596e..a76b4b9 100644 --- a/src/client/video.cc +++ b/src/client/video.cc @@ -8,7 +8,6 @@ #include "gl/osiriongl.h" #include -#include namespace client { @@ -62,13 +61,13 @@ void Video::init() int flags = 0; if( SDL_Init(SDL_INIT_VIDEO) < 0 ) { - std::cerr << "SDL_Init() failed: " << SDL_GetError() << std::endl; + conwarn << "SDL_Init() failed: " << SDL_GetError() << std::endl; return; } const SDL_VideoInfo* sdl_videoinfo = SDL_GetVideoInfo(); if( !sdl_videoinfo) { - std::cerr << "SDL_GetVideoInfo() failed: " << SDL_GetError() << std::endl; + conwarn << "SDL_GetVideoInfo() failed: " << SDL_GetError() << std::endl; return; } @@ -86,7 +85,7 @@ void Video::init() flags = SDL_OPENGL | SDL_FULLSCREEN; if(!SDL_SetVideoMode(width, height, bpp, flags )) { - std::cerr << "SDL_SetVideoMode() failed: " << SDL_GetError() << std::endl; + conwarn << "SDL_SetVideoMode() failed: " << SDL_GetError() << std::endl; return; } diff --git a/src/client/view.cc b/src/client/view.cc index c9a7b8a..ca41831 100644 --- a/src/client/view.cc +++ b/src/client/view.cc @@ -14,8 +14,6 @@ #include -#include - namespace client { @@ -118,13 +116,11 @@ void View::draw_world(float elapsed) // draw the world gl::push(); - //std::cerr << "ship at " << game::ship.location << " translate " << game::ship.location - target->location << std::endl; gl::translate(game::ship.location - target->location); gl::scale(0.2f, 0.2f, 0.2f); shipdrawer->draw(elapsed); gl::pop(); - //std::cerr << "star at " << game::star.location << " translate " << game::star.location - game::ship.location << std::endl; gl::push(); gl::translate(game::star.location - target->location); stardrawer->draw(elapsed); -- cgit v1.2.3