[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Pingus-CVS] r2601 - in trunk: data/levels/volcano src/gui
From: |
jave27 |
Subject: |
[Pingus-CVS] r2601 - in trunk: data/levels/volcano src/gui |
Date: |
Tue, 17 Jan 2006 03:49:52 +0100 |
Author: jave27
Date: 2006-01-17 03:49:26 +0100 (Tue, 17 Jan 2006)
New Revision: 2601
Modified:
trunk/data/levels/volcano/hellmouth18-grumbel.pingus
trunk/src/gui/component.hxx
trunk/src/gui/gui_manager.hxx
Log:
Prepped the GUI Manager and component for keyboard input.
Patching level in volcano to allow pingus to leave the exit (might need
to revert this one)
Modified: trunk/data/levels/volcano/hellmouth18-grumbel.pingus
===================================================================
--- trunk/data/levels/volcano/hellmouth18-grumbel.pingus 2006-01-17
02:29:27 UTC (rev 2600)
+++ trunk/data/levels/volcano/hellmouth18-grumbel.pingus 2006-01-17
02:49:26 UTC (rev 2601)
@@ -1,4 +1,5 @@
-<?xml version="1.0" encoding="UTF-8"?>
+<?xml version="1.0" encoding="ISO-8859-1"?>
+
<pingus-level>
<version>2</version>
<head>
@@ -6,11 +7,12 @@
<description></description>
<author>Ingo Ruhnke <address@hidden></author>
<number-of-pingus>50</number-of-pingus>
-<number-to-save>40 </number-to-save>
+<number-to-save>40</number-to-save>
<time>-1</time>
<difficulty>40</difficulty>
-<playable>0</playable>
+<playable>1</playable>
<comment></comment>
+<music>none</music>
<actions>
<blocker>10</blocker>
<bomber>10</bomber>
@@ -18,526 +20,526 @@
<floater>5</floater>
<miner>10</miner>
</actions>
-<music>none</music>
<levelsize>
<width>1408</width>
<height>800</height>
</levelsize>
</head>
<objects>
-<exit>
-<owner-id>0</owner-id>
+<surface-background>
+<surface>
+<image>textures/happyclouds</image>
+<modifier>ROT0</modifier>
+</surface>
+<color>
+ <red>0</red>
+ <green>0</green>
+ <blue>0</blue>
+ <alpha>0</alpha>
+</color>
+<stretch-x>0</stretch-x>
+<stretch-y>0</stretch-y>
+<keep-aspect>0</keep-aspect>
+<scroll-x>0</scroll-x>
+<scroll-y>0</scroll-y>
+<para-x>0.2</para-x>
+<para-y>0.2</para-y>
<position>
-<x>1197</x>
-<y>507</y>
-<z>-50</z>
+ <x>0</x>
+ <y>0</y>
+ <z>-150</z>
</position>
+</surface-background>
+<surface-background>
<surface>
-<image>exits/stone</image>
+<image>textures/mountain</image>
<modifier>ROT0</modifier>
</surface>
-<owner-id>0</owner-id>
-</exit>
+<color>
+ <red>0</red>
+ <green>0</green>
+ <blue>0</blue>
+ <alpha>0</alpha>
+</color>
+<stretch-x>0</stretch-x>
+<stretch-y>1</stretch-y>
+<keep-aspect>1</keep-aspect>
+<scroll-x>0</scroll-x>
+<scroll-y>0</scroll-y>
+<para-x>0.5</para-x>
+<para-y>0.5</para-y>
+<position>
+ <x>0</x>
+ <y>0</y>
+ <z>-145</z>
+</position>
+</surface-background>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/rock/stone1</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>188</x>
-<y>384</y>
-<z>0</z>
+ <x>186</x>
+ <y>383</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece9</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>174</x>
-<y>411</y>
-<z>0</z>
+ <x>174</x>
+ <y>411</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece9</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>177</x>
-<y>451</y>
-<z>0</z>
+ <x>177</x>
+ <y>451</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece7</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>274</x>
-<y>548</y>
-<z>0</z>
+ <x>274</x>
+ <y>548</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece7</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>194</x>
-<y>512</y>
-<z>0</z>
+ <x>194</x>
+ <y>512</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece7</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>1082</x>
-<y>501</y>
-<z>0</z>
+ <x>1078</x>
+ <y>499</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece7</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>1024</x>
-<y>216</y>
-<z>0</z>
+ <x>1024</x>
+ <y>216</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece7</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>329</x>
-<y>510</y>
-<z>0</z>
+ <x>329</x>
+ <y>510</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece1</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>779</x>
-<y>241</y>
-<z>0</z>
+ <x>779</x>
+ <y>241</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece9</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>961</x>
-<y>243</y>
-<z>0</z>
+ <x>961</x>
+ <y>243</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece9</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>792</x>
-<y>335</y>
-<z>0</z>
+ <x>792</x>
+ <y>335</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece9</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>644</x>
-<y>395</y>
-<z>0</z>
+ <x>644</x>
+ <y>395</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece1</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>466</x>
-<y>388</y>
-<z>0</z>
+ <x>466</x>
+ <y>388</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece5</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>925</x>
-<y>212</y>
-<z>0</z>
+ <x>925</x>
+ <y>212</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>ground</type>
<surface>
<image>groundpieces/ground/misc/bpiece5</image>
<modifier>ROT0</modifier>
</surface>
+<type>ground</type>
<position>
-<x>612</x>
-<y>359</y>
-<z>0</z>
+ <x>612</x>
+ <y>359</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/weed1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>1104</x>
-<y>217</y>
-<z>0</z>
+ <x>1104</x>
+ <y>217</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/weed1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>1018</x>
-<y>254</y>
-<z>0</z>
+ <x>1018</x>
+ <y>254</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/weed1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>823</x>
-<y>363</y>
-<z>0</z>
+ <x>823</x>
+ <y>363</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/weed1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>626</x>
-<y>417</y>
-<z>0</z>
+ <x>626</x>
+ <y>417</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/weed2</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>873</x>
-<y>291</y>
-<z>0</z>
+ <x>873</x>
+ <y>291</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/weed2</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>565</x>
-<y>455</y>
-<z>0</z>
+ <x>565</x>
+ <y>455</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/weed2</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>709</x>
-<y>387</y>
-<z>0</z>
+ <x>709</x>
+ <y>387</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/weed2</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>921</x>
-<y>286</y>
-<z>0</z>
+ <x>921</x>
+ <y>286</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>912</x>
-<y>241</y>
-<z>0</z>
+ <x>912</x>
+ <y>241</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>1078</x>
-<y>500</y>
-<z>0</z>
+ <x>1078</x>
+ <y>500</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>1020</x>
-<y>215</y>
-<z>0</z>
+ <x>1020</x>
+ <y>215</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>196</x>
-<y>514</y>
-<z>0</z>
+ <x>196</x>
+ <y>514</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>190</x>
-<y>438</y>
-<z>0</z>
+ <x>190</x>
+ <y>438</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>1155</x>
-<y>500</y>
-<z>0</z>
+ <x>1155</x>
+ <y>500</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>1097</x>
-<y>215</y>
-<z>0</z>
+ <x>1097</x>
+ <y>215</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>331</x>
-<y>512</y>
-<z>0</z>
+ <x>331</x>
+ <y>512</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>268</x>
-<y>514</y>
-<z>0</z>
+ <x>268</x>
+ <y>514</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>1227</x>
-<y>500</y>
-<z>0</z>
+ <x>1227</x>
+ <y>500</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>1169</x>
-<y>215</y>
-<z>0</z>
+ <x>1169</x>
+ <y>215</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>411</x>
-<y>520</y>
-<z>0</z>
+ <x>411</x>
+ <y>520</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>403</x>
-<y>512</y>
-<z>0</z>
+ <x>403</x>
+ <y>512</y>
+ <z>0</z>
</position>
</groundpiece>
<groundpiece>
-<type>transparent</type>
<surface>
<image>groundpieces/transparent/misc/moos1</image>
<modifier>ROT0</modifier>
</surface>
+<type>transparent</type>
<position>
-<x>703</x>
-<y>360</y>
-<z>0</z>
+ <x>703</x>
+ <y>360</y>
+ <z>0</z>
</position>
</groundpiece>
<entrance>
- <position>
-<x>331</x>
-<y>412</y>
-<z>0</z>
+<type>generic</type>
+<owner-id>0</owner-id>
+<direction>misc</direction>
+<release-rate>50</release-rate>
+<position>
+ <x>331</x>
+ <y>412</y>
+ <z>0</z>
</position>
- <type>generic</type>
- <direction>misc</direction>
- <release-rate>50</release-rate>
- <owner-id>0</owner-id>
</entrance>
-<surface-background>
+<exit>
<surface>
-<image>textures/happyclouds</image>
+<image>exits/stone</image>
<modifier>ROT0</modifier>
</surface>
-<color>
- <red>0</red>
- <green>0</green>
- <blue>0</blue>
- <alpha>0</alpha>
- </color>
-<scroll-x>0</scroll-x>
-<scroll-y>0</scroll-y>
-<para-x>0.2</para-x>
-<para-y>0.2</para-y>
-<stretch-x>0</stretch-x>
-<stretch-y>0</stretch-y>
+<owner-id>0</owner-id>
<position>
-<x>0</x>
-<y>0</y>
-<z>-150</z>
+ <x>1197</x>
+ <y>500</y>
+ <z>0</z>
</position>
-</surface-background>
-<surface-background>
-<surface>
-<image>textures/mountain</image>
-<modifier>ROT0</modifier>
-</surface>
-<color>
- <red>0</red>
- <green>0</green>
- <blue>0</blue>
- <alpha>0</alpha>
- </color>
-<scroll-x>0</scroll-x>
-<scroll-y>0</scroll-y>
-<para-x>0.5</para-x>
-<para-y>0.5</para-y>
-<stretch-x>0</stretch-x>
-<stretch-y>1</stretch-y>
-<position>
-<x>0</x>
-<y>0</y>
-<z>-145</z>
-</position>
-</surface-background>
+</exit>
</objects>
</pingus-level>
Modified: trunk/src/gui/component.hxx
===================================================================
--- trunk/src/gui/component.hxx 2006-01-17 02:29:27 UTC (rev 2600)
+++ trunk/src/gui/component.hxx 2006-01-17 02:49:26 UTC (rev 2601)
@@ -70,6 +70,10 @@
/** Emitted when the pointer moved, x and y are the new pointer
coordinates */
virtual void on_pointer_move (int x, int y) { UNUSED_ARG(x); UNUSED_ARG(y); }
+
+ /** Emitted whenever a keyboard character is pressed. Only certain
+ components should implement this */
+ void key_pressed(const char c) { UNUSED_ARG(c); }
// status functions for use in the update() function
/** return true if currently pressed */
Modified: trunk/src/gui/gui_manager.hxx
===================================================================
--- trunk/src/gui/gui_manager.hxx 2006-01-17 02:29:27 UTC (rev 2600)
+++ trunk/src/gui/gui_manager.hxx 2006-01-17 02:49:26 UTC (rev 2601)
@@ -61,6 +61,8 @@
void process_input (const GameDelta& delta);
void process_pointer_event (const Input::PointerEvent& event);
void process_button_event (unsigned int time_stamp, const
Input::ButtonEvent& event);
+ void key_pressed(const char c);
+
public:
GUIManager ();
virtual ~GUIManager () {}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Pingus-CVS] r2601 - in trunk: data/levels/volcano src/gui,
jave27 <=