[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Pingus-CVS] r2609 - trunk/src/worldobjs
From: |
jave27 |
Subject: |
[Pingus-CVS] r2609 - trunk/src/worldobjs |
Date: |
Thu, 19 Jan 2006 01:57:49 +0100 |
Author: jave27
Date: 2006-01-19 01:57:13 +0100 (Thu, 19 Jan 2006)
New Revision: 2609
Modified:
trunk/src/worldobjs/spike.cxx
trunk/src/worldobjs/surface_background.cxx
Log:
Z issue was the surface_background - it wasn't taking account of the
pos.z when it tiled the screen.
Updated spike get_pos() calls.
Modified: trunk/src/worldobjs/spike.cxx
===================================================================
--- trunk/src/worldobjs/spike.cxx 2006-01-19 00:38:15 UTC (rev 2608)
+++ trunk/src/worldobjs/spike.cxx 2006-01-19 00:57:13 UTC (rev 2609)
@@ -68,16 +68,16 @@
Spike::catch_pingu (Pingu* pingu)
{
if (!killing) {
- if (pingu->get_x () > pos.x + 16 - 5 && pingu->get_x () < pos.x
+ 16 + 5
- && pingu->get_y () > pos.y && pingu->get_y ()
< pos.y + 32)
+ if ( pingu->get_pos().x > pos.x + 16 - 5 && pingu->get_pos().x
< pos.x + 16 + 5
+ && pingu->get_pos().y > pos.y &&
pingu->get_pos().y < pos.y + 32)
{
surface.restart();
killing = true;
}
} else {
if (surface.get_current_frame() == 3
- && pingu->get_x () > pos.x +16 - 12 && pingu->get_x ()
< pos.x + 16 + 12
- && pingu->get_y () > pos.y && pingu->get_y ()
< pos.y + 32)
+ && pingu->get_pos().x > pos.x +16 - 12 &&
pingu->get_pos().x < pos.x + 16 + 12
+ && pingu->get_pos().y > pos.y &&
pingu->get_pos().y < pos.y + 32)
{
pingu->set_status(PS_DEAD);
}
Modified: trunk/src/worldobjs/surface_background.cxx
===================================================================
--- trunk/src/worldobjs/surface_background.cxx 2006-01-19 00:38:15 UTC (rev
2608)
+++ trunk/src/worldobjs/surface_background.cxx 2006-01-19 00:57:13 UTC (rev
2609)
@@ -34,7 +34,6 @@
SurfaceBackground::SurfaceBackground(const FileReader& reader)
: para_x(0.5),
para_y(0.5),
- pos(Vector(0, 0, -150)),
scroll_x(0.0),
scroll_y(0.0),
color(CL_Colorf(0,0,0,0)),
@@ -184,7 +183,7 @@
x += bg_surface.get_width())
{
gc.color().draw(bg_surface,
Vector(static_cast<float>(x),
-
static_cast<float>(y)));
+
static_cast<float>(y), pos.z));
}
}
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Pingus-CVS] r2609 - trunk/src/worldobjs,
jave27 <=