|
From: <spo...@us...> - 2007-06-12 17:12:22
|
Revision: 552
http://svn.sourceforge.net/opengate/?rev=552&view=rev
Author: spom_spom
Date: 2007-06-12 10:12:12 -0700 (Tue, 12 Jun 2007)
Log Message:
-----------
Add very basic ship configuratoin dialog. Its just quite ugly.
Modified Paths:
--------------
branches/ogsector/configure.ac
branches/ogsector/data/gui/layouts/dialogs/MarketDialog.layout
branches/ogsector/data/gui/layouts/dialogs/MarketItemShortDialog.layout
branches/ogsector/data/gui/layouts/dialogs/ShipConfigDialog.layout
branches/ogsector/data/gui/schemes/opengate/opengate.imageset
branches/ogsector/data/gui/schemes/opengate/opengate.png
branches/ogsector/src/Avatar.cpp
branches/ogsector/src/Avatar.h
branches/ogsector/src/BaseDialog.cpp
branches/ogsector/src/BaseDialog.h
branches/ogsector/src/DeviceManager.h
branches/ogsector/src/DockedState.cpp
branches/ogsector/src/DockedState.h
branches/ogsector/src/Entity.cpp
branches/ogsector/src/Entity.h
branches/ogsector/src/EntityManager.cpp
branches/ogsector/src/EntityManager.h
branches/ogsector/src/GameStateManager.cpp
branches/ogsector/src/Makefile.am
branches/ogsector/src/Makefile.in
branches/ogsector/src/MarketDialog.cpp
branches/ogsector/src/MarketDialog.h
branches/ogsector/src/Sector.cpp
branches/ogsector/src/SectorObjects.cpp
branches/ogsector/src/SectorObjects.h
branches/ogsector/src/ShipConfigDialog.cpp
branches/ogsector/src/ShipConfigDialog.h
branches/ogsector/src/UnDockedState.cpp
branches/ogsector/src/Vessel.h
Added Paths:
-----------
branches/ogsector/data/gui/layouts/dialogs/ShipConfigEquipmentButton.layout
branches/ogsector/src/Vessel.cpp
Modified: branches/ogsector/configure.ac
===================================================================
--- branches/ogsector/configure.ac 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/configure.ac 2007-06-12 17:12:12 UTC (rev 552)
@@ -51,7 +51,7 @@
AC_SUBST(AM_CXXFLAGS, "$AM_CXXFLAGS $freealut_CFLAGS")
AC_SUBST(AM_LDFLAGS, "$AM_LDFLAGS $freealut_LIBS")
-AC_SUBST([CXXFLAGS], ["${CXXFLAGS} -I$OGSECTOR_EXTERNALS_PATH/include"])
+AC_SUBST([CXXFLAGS], ["${CXXFLAGS} -Wall -I$OGSECTOR_EXTERNALS_PATH/include"])
AC_SUBST([CXXFLAGS], ["${CXXFLAGS} -I$OGSECTOR_EXTERNALS_PATH/ogreopcode/include"])
AC_SUBST([CXXFLAGS], ["${CXXFLAGS} -I$OGSECTOR_EXTERNALS_PATH/ogreopcode/opcode132"])
AC_SUBST([LDFLAGS], ["${LDFLAGS} -L$OGSECTOR_EXTERNALS_PATH/lib/ -lOpcode -lOgreOpcode"])
Modified: branches/ogsector/data/gui/layouts/dialogs/MarketDialog.layout
===================================================================
--- branches/ogsector/data/gui/layouts/dialogs/MarketDialog.layout 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/data/gui/layouts/dialogs/MarketDialog.layout 2007-06-12 17:12:12 UTC (rev 552)
@@ -51,8 +51,8 @@
<Property Name="FrameEnabled" Value="False" />
</Window>
<Window Type="opengate/StaticGreenImage" Name="MarketItemDetailedView/TextFrame">
- <Property Name="UnifiedPosition" Value="{{0.0, 330},{0.5, -120}}" />
- <Property Name="UnifiedSize" Value="{{0.0, 250},{0.0, 240}}" />
+ <Property Name="UnifiedPosition" Value="{{0.0, 330},{0.5, -145}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 250},{0.0, 290}}" />
<Property Name="BackgroundEnabled" Value="False" />
<Property Name="FrameEnabled" Value="False" />
<Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/TextFrame/Name">
@@ -82,8 +82,47 @@
<Property Name="UnifiedSize" Value="{{1.0, -100},{1.0, 0}}" />
</Window>
</Window>
+ <Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/EquipmentSpecs">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 100}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{1.0, -80}}" />
+ <Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/EquipmentSpecs1a">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 20}}" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/EquipmentSpecs1b">
+ <Property Name="UnifiedPosition" Value="{{0.0, 100},{0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 50},{0.0, 20}}" />
+ </Window>
+
+ <Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/EquipmentSpecs2a">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 20}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 20}}" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/EquipmentSpecs2b">
+ <Property Name="UnifiedPosition" Value="{{0.0, 100},{0.0, 20}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 50},{0.0, 20}}" />
+ </Window>
+
+ <Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/EquipmentSpecs3a">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 40}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 20}}" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/EquipmentSpecs3b">
+ <Property Name="UnifiedPosition" Value="{{0.0, 100},{0.0, 40}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 50},{0.0, 20}}" />
+ </Window>
+
+ <Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/EquipmentSpecs4a">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 60}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 20}}" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/EquipmentSpecs4b">
+ <Property Name="UnifiedPosition" Value="{{0.0, 100},{0.0, 60}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 50},{0.0, 20}}" />
+ </Window>
+ </Window>
<Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/TextFrame/Amount">
- <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 70}}" />
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{1.0, -60}}" />
<Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
<Property Name="Text" Value="Amount available:" />
<Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/TextFrame/Amount/Text">
@@ -92,7 +131,7 @@
</Window>
</Window>
<Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/TextFrame/Price">
- <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 100}}" />
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{1.0, -40}}" />
<Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
<Property Name="Text" Value="Cost with tax:" />
<Window Type="opengate/StaticLabel" Name="MarketItemDetailedView/TextFrame/Price/Text">
Modified: branches/ogsector/data/gui/layouts/dialogs/MarketItemShortDialog.layout
===================================================================
--- branches/ogsector/data/gui/layouts/dialogs/MarketItemShortDialog.layout 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/data/gui/layouts/dialogs/MarketItemShortDialog.layout 2007-06-12 17:12:12 UTC (rev 552)
@@ -17,7 +17,7 @@
<Property Name="UnifiedSize" Value="{{0.0, 12},{0.0, 12}}" />
<Property Name="BackgroundEnabled" Value="False" />
<Property Name="FrameEnabled" Value="false" />
- <Property Name="Image" Value="set:opengate image:IconCommoditiesNeutral" />
+ <Property Name="Image" Value="set:opengate image:IconCommodity0" />
<Property Name="MousePassThroughEnabled" Value="true" />
</Window>
<Window Type="opengate/StaticGreenImage" Name="MarketShortItemSizeIcon">
Modified: branches/ogsector/data/gui/layouts/dialogs/ShipConfigDialog.layout
===================================================================
--- branches/ogsector/data/gui/layouts/dialogs/ShipConfigDialog.layout 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/data/gui/layouts/dialogs/ShipConfigDialog.layout 2007-06-12 17:12:12 UTC (rev 552)
@@ -1,75 +1,340 @@
<?xml version="1.0" ?>
<GUILayout>
- <Window Type="opengate/FrameWindow" Name="ShipConfigDialog">
- <Property Name="UnifiedPosition" Value="{{0.15,0},{0.15,0}}" />
- <Property Name="UnifiedSize" Value="{{0.7,0},{0.7,0}}" />
- <Property Name="SizingEnabled" Value="false" />
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfigDialog">
+ <!-- <Property Name="MousePassThroughEnabled" Value="True" /> -->
+ <Property Name="UnifiedPosition" Value="{{0.0,100},{0.0,115}}" />
+ <Property Name="UnifiedSize" Value="{{1.0,-167},{1.0,-217}}" />
+<!-- *** -->
+<!-- *** Left part ship selection *** -->
+<!-- *** -->
+ <Window Type="opengate/StaticGreenImage" Name="ShipSelection">
+ <Property Name="UnifiedPosition" Value="{{0.0, 10},{0.0, 10}}" />
+ <Property Name="UnifiedSize" Value="{{0.5, -50},{1.0, -20}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+<!-- *** Start frame *** -->
+ <Window Type="opengate/StaticGreenImage" Name="ShipSelection/TopLeft">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 31},{0.0, 31}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenTopLeft"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipSelection/Top">
+ <Property Name="UnifiedPosition" Value="{{0.0, 31},{ 0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -31},{ 0.0, 31}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenTop"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipSelection/Right">
+ <Property Name="UnifiedPosition" Value="{{1.0, -1},{ 0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 1},{ 1.0, 0}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenVertLine"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipSelection/Bottom">
+ <Property Name="UnifiedPosition" Value="{{0.0, 31},{ 1.0, -31}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -32},{ 0.0, 31}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenBottom"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipSelection/BottomLeft">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{ 1.0, -31}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 31},{ 0.0, 31}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenBottomLeft"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipSelection/Left">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{ 0.0, 31}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 31},{ 1.0, -62}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenLeft"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipSelection/Background">
+ <Property Name="UnifiedPosition" Value="{{0.0, 31},{ 0.0, 31}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -32},{ 1.0, -62}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenBackdrop"/>
+ </Window>
+<!-- *** End frame *** -->
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfigDialog/ShipView">
+ <Property Name="UnifiedPosition" Value="{{0.0, 31},{0.0, 31}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 200},{0.0, 150}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ </Window>
+ <Window Type="opengate/EmptyButton" Name="ShipConfigDialog/PrevShip">
+ <Property Name="UnifiedPosition" Value="{{0.0, 31},{0.0, 190}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 56},{0.0, 14}}" />
+ <Property Name="NormalImage" Value="set:opengate image:ScrollThumbLeftNormal" />
+ <Property Name="HoverImage" Value="set:opengate image:ScrollThumbLeftHover" />
+ <Property Name="PushedImage" Value="set:opengate image:ScrollThumbLeftPushed" />
+ </Window>
+ <Window Type="opengate/EmptyButton" Name="ShipConfigDialog/NextShip">
+ <Property Name="UnifiedPosition" Value="{{0.0, 175},{0.0, 190}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 56},{0.0, 14}}" />
+ <Property Name="NormalImage" Value="set:opengate image:ScrollThumbRightNormal" />
+ <Property Name="HoverImage" Value="set:opengate image:ScrollThumbRightHover" />
+ <Property Name="PushedImage" Value="set:opengate image:ScrollThumbRightPushed" />
+ </Window>
+ <Window Type="opengate/Button" Name="ShipConfigDialog/SelectOctavius">
+ <Property Name="UnifiedPosition" Value="{{0.0, 260},{0.0, 10}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 24}}" />
+ <Property Name="Text" Value="Octavius" />
+ <Property Name="Disabled" Value="true" />
+ </Window>
+ <Window Type="opengate/Button" Name="ShipConfigDialog/SelectQuanter">
+ <Property Name="UnifiedPosition" Value="{{0.0, 260},{0.0, 36}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 24}}" />
+ <Property Name="Text" Value="Quantar" />
+ <Property Name="Disabled" Value="true" />
+ </Window>
+ <Window Type="opengate/Button" Name="ShipConfigDialog/SelectTauseti">
+ <Property Name="UnifiedPosition" Value="{{0.0, 260},{0.0, 62}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 24}}" />
+ <Property Name="Text" Value="Tauseti" />
+ <Property Name="Disabled" Value="true" />
+ </Window>
+ <Window Type="opengate/Button" Name="ShipConfigDialog/SelectSquadrok">
+ <Property Name="UnifiedPosition" Value="{{0.0, 260},{0.0, 88}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 24}}" />
+ <Property Name="Text" Value="Squadrok" />
+ <Property Name="Disabled" Value="true" />
+ </Window>
+ <Window Type="opengate/Button" Name="ShipConfigDialog/SelectAll">
+ <Property Name="UnifiedPosition" Value="{{0.0, 260},{0.0, 120}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 24}}" />
+ <Property Name="Text" Value="All" />
+ <Property Name="Disabled" Value="true" />
+ </Window>
+ <Window Type="opengate/Button" Name="ShipConfigDialog/SelectShip">
+ <Property Name="UnifiedPosition" Value="{{0.0, 260},{0.0, 154}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 24}}" />
+ <Property Name="Text" Value="Select" />
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfigDialog/MiddleLine">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{ 0.0, 220}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{ 0.0, 1}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenHorizLine"/>
+ </Window>
+<!-- *** -->
+<!-- *** Ship selection bottom part *** -->
+<!-- *** -->
+ <Window Type="opengate/EmptyButton" Name="ShipConfigDialog/SelectGun">
+ <Property Name="UnifiedPosition" Value="{{0.0, 10},{0.0, 300}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 24}}" />
+ <Property Name="Font" Value="BlueHighway-16" />
+ <Property Name="Text" Value="Guns" />
+ <Property Name="Disabled" Value="True" />
+<!-- <Property Name="HorizontalAlignment" Value="Left" /> -->
+ </Window>
+ <Window Type="opengate/EmptyButton" Name="ShipConfigDialog/SelectMissile">
+ <Property Name="UnifiedPosition" Value="{{0.0, 10},{0.0, 330}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 24}}" />
+ <Property Name="Font" Value="BlueHighway-16" />
+ <Property Name="Text" Value="Missiles" />
+ <Property Name="Disabled" Value="True" />
+ </Window>
+ <Window Type="opengate/EmptyButton" Name="ShipConfigDialog/SelectEquipment">
+ <Property Name="UnifiedPosition" Value="{{0.0, 10},{0.0, 360}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 24}}" />
+ <Property Name="Font" Value="BlueHighway-16" />
+ <Property Name="Text" Value="Equipment" />
+ </Window>
+ <Window Type="opengate/EmptyButton" Name="ShipConfigDialog/SelectMODx">
+ <Property Name="UnifiedPosition" Value="{{0.0, 10},{0.0, 390}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 100},{0.0, 24}}" />
+ <Property Name="Font" Value="BlueHighway-16" />
+ <Property Name="Text" Value="MODx" />
+ <Property Name="Disabled" Value="True" />
+ </Window>
-<!-- <Property Name="HorizontalAlignment" Value="Centre" /> -->
-<!-- <Property Name="VerticalAlignment" Value="Centre" /> -->
- <Property Name="Alpha" Value="0.7" />
- <Property Name="Text" Value="Ship Configurator" />
- <Window Type="opengate/FrameWindow" Name="ShipConfigDialog/ShipStats">
- <Property Name="UnifiedPosition" Value="{{0.7,0},{0.0,22}}" />
- <Property Name="UnifiedSize" Value="{{0.3,0},{1.0,-22}}" />
- <Property Name="SizingEnabled" Value="false" />
- <Property Name="TitlebarEnabled" Value="false" />
- <Property Name="CloseButtonEnabled" Value="false" />
- <Property Name="Alpha" Value="0.7" />
</Window>
- <Window Type="opengate/Button" Name="ShipConfigDialog/SelectOctavius">
- <Property Name="UnifiedPosition" Value="{{0.55,0.0},{0.3,0}}" />
- <Property Name="UnifiedSize" Value="{{0.0,100},{0.0,24}}" />
- <Property Name="Text" Value="Octavius" />
- <Property Name="Disabled" Value="true" />
+<!-- *** -->
+<!-- *** Right part ship configuration *** -->
+<!-- *** -->
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration">
+ <Property Name="UnifiedPosition" Value="{{0.5, -30},{0.0, 10}}" />
+ <Property Name="UnifiedSize" Value="{{0.5, 19},{1.0, -20}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+<!-- *** Start frame *** -->
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/Top">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{ 0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -31},{ 0.0, 31}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenTop"/>
+ <Property Name="RiseOnClick" Value="False" />
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/TopRight">
+ <Property Name="UnifiedPosition" Value="{{1.0, -31},{0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 31},{0.0, 31}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenTopRight"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/Right">
+ <Property Name="UnifiedPosition" Value="{{1.0, -31},{ 0.0, 31}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 31},{ 1.0, -62}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenRight"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/BottomRight">
+ <Property Name="UnifiedPosition" Value="{{1.0, -31},{ 1.0, -31}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 31},{ 0.0, 31}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenBottomRight"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/Bottom">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{1.0, -31}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -31},{0.0, 31}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenBottom"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/Left">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 1},{1.0, 0}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenVertLine"/>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/Background">
+ <Property Name="UnifiedPosition" Value="{{0.0, 1},{0.0, 31}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -32},{1.0, -62}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="Image" Value="set:opengate image:StaticGreenBackdrop"/>
+ </Window>
+<!-- *** End frame *** -->
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/EquipmentWindow">
+ <Property Name="UnifiedPosition" Value="{{0.0, 15},{0.0, 5}}" />
+ <Property Name="UnifiedSize" Value="{{0.6, 0},{1.0, -5}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="MousePassThroughEnabled" Value="True" />
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/PowerGrid">
+ <Property Name="UnifiedPosition" Value="{{0.6, 15},{0.0, 10}}" />
+ <Property Name="UnifiedSize" Value="{{0.4, -25},{1.0, -20}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="True" />
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/PowerGrid/Icons">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 31}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -50},{1.0, -62}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/PowerGrid/Icons/Engine">
+ <Property Name="UnifiedPosition" Value="{{0.0, 30},{0.0, 37}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -30},{0.0, 40}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Window Type="opengate/EmptyButton" Name="ShipConfiguration/PowerGrid/Icons/Engine/Decrease">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.5, -10}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 8},{0.0, 20}}" />
+ <Property Name="NormalImage" Value="set:opengate image:ShipConfigEquipmentPrevItemNormal" />
+ <Property Name="HoverImage" Value="set:opengate image:ShipConfigEquipmentPrevItemHover" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Icons/Engine/TrustPercent">
+ <Property Name="UnifiedPosition" Value="{{0.0, 12},{0.0, 5}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -40},{0.0, 15}}" />
+ <Property Name="Text" Value="100%" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Icons/Engine/Speed">
+ <Property Name="UnifiedPosition" Value="{{0.0, 12},{0.0, 20}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -40},{0.0, 15}}" />
+ <Property Name="Text" Value="V000" />
+ </Window>
+ <Window Type="opengate/EmptyButton" Name="ShipConfiguration/PowerGrid/Icons/Engine/Increase">
+ <Property Name="UnifiedPosition" Value="{{1.0, -25},{0.5, -10}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 8},{0.0, 20}}" />
+ <Property Name="NormalImage" Value="set:opengate image:ShipConfigEquipmentNextItemNormal" />
+ <Property Name="HoverImage" Value="set:opengate image:ShipConfigEquipmentNextItemHover" />
+ </Window>
+ </Window>
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfiguration/PowerGrid/Values">
+ <Property Name="UnifiedPosition" Value="{{1.0, -50},{0.0, 31}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 50},{1.0, -62}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Values/PowerPlantOut">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 10}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
+ <Property Name="Text" Value="0" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Values/EngineIn">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 50}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
+ <Property Name="Text" Value="0" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Values/EngineOut">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 70}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
+ <Property Name="Text" Value="0" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Values/RadarIn">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 110}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
+ <Property Name="Text" Value="0" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Values/RadarOut">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 130}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
+ <Property Name="Text" Value="0" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Values/EcmIn">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 170}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
+ <Property Name="Text" Value="0" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Values/EcmOut">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 190}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
+ <Property Name="Text" Value="0" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Values/ShieldIn">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 230}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
+ <Property Name="Text" Value="0" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Values/ShieldOut">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 250}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
+ <Property Name="Text" Value="0" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfiguration/PowerGrid/Values/Remain">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{1.0, -30}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, 0},{0.0, 20}}" />
+ <Property Name="Text" Value="0" />
+ </Window>
+ </Window>
+ </Window>
</Window>
- <Window Type="opengate/Button" Name="ShipConfigDialog/SelectQuanter">
- <Property Name="UnifiedPosition" Value="{{0.55,0.0},{0.3,+26}}" />
- <Property Name="UnifiedSize" Value="{{0.0,100},{0.0,24}}" />
- <Property Name="Text" Value="Quantar" />
- <Property Name="Disabled" Value="true" />
- </Window>
- <Window Type="opengate/Button" Name="ShipConfigDialog/SelectTauseti">
- <Property Name="UnifiedPosition" Value="{{0.55,0.0},{0.3,+52}}" />
- <Property Name="UnifiedSize" Value="{{0.0,100},{0.0,24}}" />
- <Property Name="Text" Value="Tauseti" />
- <Property Name="Disabled" Value="true" />
</Window>
- <Window Type="opengate/Button" Name="ShipConfigDialog/SelectSquadrok">
- <Property Name="UnifiedPosition" Value="{{0.55,0.0},{0.3,+78}}" />
- <Property Name="UnifiedSize" Value="{{0.0,100},{0.0,24}}" />
- <Property Name="Text" Value="Squadrok" />
- <Property Name="Disabled" Value="true" />
- </Window>
- <Window Type="opengate/Button" Name="ShipConfigDialog/SelectAll">
- <Property Name="UnifiedPosition" Value="{{0.55,0.0},{0.3,+110}}" />
- <Property Name="UnifiedSize" Value="{{0.0,100},{0.0,24}}" />
- <Property Name="Text" Value="All" />
- <Property Name="Disabled" Value="true" />
- </Window>
- <Window Type="opengate/StaticImage" Name="ShipConfigDialog/ShipView">
- <Property Name="UnifiedPosition" Value="{{0.1,0},{0.3,0}}" />
- <Property Name="UnifiedSize" Value="{{0.4,0},{ 0.4,0}}" />
- <Property Name="Alpha" Value="1.0" />
- </Window>
- <Window Type="opengate/EmptyButton" Name="ShipConfigDialog/PrevShip">
- <Property Name="UnifiedPosition" Value="{{0.1,0},{0.7,+10}}" />
- <Property Name="UnifiedSize" Value="{{0.0,56},{ 0.0,14}}" />
- <Property Name="NormalImage" Value="set:opengate image:ScrollThumbLeftNormal" />
- <Property Name="HoverImage" Value="set:opengate image:ScrollThumbLeftHover" />
- <Property Name="PushedImage" Value="set:opengate image:ScrollThumbLeftPushed" />
- </Window>
- <Window Type="opengate/EmptyButton" Name="ShipConfigDialog/NextShip">
- <Property Name="UnifiedPosition" Value="{{0.5,-56},{0.7,+10}}" />
- <Property Name="UnifiedSize" Value="{{0.0,56},{ 0.0,14}}" />
- <Property Name="NormalImage" Value="set:opengate image:ScrollThumbRightNormal" />
- <Property Name="HoverImage" Value="set:opengate image:ScrollThumbRightHover" />
- <Property Name="PushedImage" Value="set:opengate image:ScrollThumbRightPushed" />
- </Window>
- <Window Type="opengate/Button" Name="ShipConfigDialog/SelectShip">
- <Property Name="UnifiedPosition" Value="{{0.0,+10},{1,-34}}" />
- <Property Name="UnifiedSize" Value="{{0.0,100},{0.0,24}}" />
- <Property Name="Text" Value="Select" />
- </Window>
- </Window>
</GUILayout>
Added: branches/ogsector/data/gui/layouts/dialogs/ShipConfigEquipmentButton.layout
===================================================================
--- branches/ogsector/data/gui/layouts/dialogs/ShipConfigEquipmentButton.layout (rev 0)
+++ branches/ogsector/data/gui/layouts/dialogs/ShipConfigEquipmentButton.layout 2007-06-12 17:12:12 UTC (rev 552)
@@ -0,0 +1,97 @@
+<?xml version="1.0" ?>
+<GUILayout>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfigEquipmentItem">
+ <Property Name="UnifiedPosition" Value="{{0.0, 10},{0.0, 10}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 131},{0.0, 120}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Window Type="opengate/EmptyButton" Name="ShipConfigEquipmentButton">
+ <Property Name="UnifiedPosition" Value="{{0.0, 9},{0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 121},{0.0, 106}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="NormalImage" Value="set:opengate image:ShipConfigEquipmentItemWindowNormal" />
+ <Property Name="HoverImage" Value="set:opengate image:ShipConfigEquipmentItemWindowHover" />
+ <Property Name="PushedImage" Value="set:opengate image:ShipConfigEquipmentItemWindowHover" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfigEquipmentButton/Image">
+ <Property Name="UnifiedPosition" Value="{{0.5, -38},{0.0, 7}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 76},{0.0, 76}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="MousePassThroughEnabled" Value="True" />
+ </Window>
+ <Window Type="opengate/StaticGreenImage" Name="ShipConfigEquipmentButton/CategoryIcon">
+ <Property Name="UnifiedPosition" Value="{{1.0, -15},{0.0, 3}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 12},{0.0, 12}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="MousePassThroughEnabled" Value="True" />
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfigEquipmentButton/Name">
+ <Property Name="UnifiedPosition" Value="{{0.0, 2},{1.0, -13}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -4},{0.0, 12}}" />
+ <Property Name="Text" Value="Label" />
+ <Property Name="Font" Value="BlueHighway-10" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="MousePassThroughEnabled" Value="True" />
+ </Window>
+ <Window Type="opengate/EmptyButton" Name="ShipConfigEquipmentButton/PrevItem">
+ <Property Name="UnifiedPosition" Value="{{0.0, 4},{0.5, -10}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 11},{0.0, 21}}" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="NormalImage" Value="set:opengate image:ShipConfigEquipmentPrevItemNormal" />
+ <Property Name="HoverImage" Value="set:opengate image:ShipConfigEquipmentPrevItemHover" />
+ </Window>
+ <Window Type="opengate/EmptyButton" Name="ShipConfigEquipmentButton/NextItem">
+ <Property Name="UnifiedPosition" Value="{{1.0, -15},{0.5, -10}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 11},{0.0, 21}}" />
+ <Property Name="Font" Value="BlueHighway-10" />
+ <Property Name="RiseOnClick" Value="False" />
+ <Property Name="NormalImage" Value="set:opengate image:ShipConfigEquipmentNextItemNormal" />
+ <Property Name="HoverImage" Value="set:opengate image:ShipConfigEquipmentNextItemHover" />
+ </Window>
+ </Window>
+ <Window Type="opengate/EmptyButton" Name="ShipConfigEquipmentItem/Load">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 28},{0.0, 21}}" />
+ <Property Name="NormalImage" Value="set:opengate image:ShipConfigEquipmentLoadBlue" />
+ <Property Name="HoverImage" Value="set:opengate image:ShipConfigEquipmentLoadGreen" />
+ <Property Name="PushedImage" Value="set:opengate image:ShipConfigEquipmentLoadRed" />
+ <Window Type="opengate/StaticImage" Name="ShipConfigEquipmentItem/Load/Arrow">
+ <Property Name="UnifiedPosition" Value="{{0.5, -6},{0.5, -7}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 14},{0.0, 12}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="Image" Value="set:opengate image:ShipConfigEquipmentLeftArrow" />
+ <Property Name="AlwaysOnTop" Value="True" />
+ <Property Name="MousePassThroughEnabled" Value="True" />
+ </Window>
+ </Window>
+ <Window Type="opengate/EmptyButton" Name="ShipConfigEquipmentItem/UnLoad">
+ <Property Name="UnifiedPosition" Value="{{0.0, 0},{0.0, 0}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 28},{0.0, 21}}" />
+ <Property Name="NormalImage" Value="set:opengate image:ShipConfigEquipmentLoadRed" />
+ <Property Name="HoverImage" Value="set:opengate image:ShipConfigEquipmentLoadGreen" />
+ <Property Name="PushedImage" Value="set:opengate image:ShipConfigEquipmentLoadBlue" />
+ <Property Name="AlwaysOnTop" Value="True" />
+ <Property Name="Visible" Value="False" />
+ <Window Type="opengate/StaticImage" Name="ShipConfigEquipmentItem/UnLoad/Arrow">
+ <Property Name="UnifiedPosition" Value="{{0.5, -6},{0.5, -7}}" />
+ <Property Name="UnifiedSize" Value="{{0.0, 14},{0.0, 12}}" />
+ <Property Name="BackgroundEnabled" Value="False" />
+ <Property Name="FrameEnabled" Value="False" />
+ <Property Name="Image" Value="set:opengate image:ShipConfigEquipmentRightArrow" />
+ <Property Name="MousePassThroughEnabled" Value="True" />
+ </Window>
+ </Window>
+ <Window Type="opengate/StaticLabel" Name="ShipConfigEquipmentButton/Label">
+ <Property Name="UnifiedPosition" Value="{{0.0, 40},{1.0, -14}}" />
+ <Property Name="UnifiedSize" Value="{{1.0, -40},{0.0, 12}}" />
+ <Property Name="Text" Value="Label" />
+ <Property Name="Font" Value="BlueHighway-10" />
+ </Window>
+ </Window>
+</GUILayout>
Modified: branches/ogsector/data/gui/schemes/opengate/opengate.imageset
===================================================================
--- branches/ogsector/data/gui/schemes/opengate/opengate.imageset 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/data/gui/schemes/opengate/opengate.imageset 2007-06-12 17:12:12 UTC (rev 552)
@@ -135,7 +135,6 @@
<Image Name="IconMODx2" XPos="286" YPos="304" Width="15" Height="15" />
<Image Name="IconMODx3" XPos="286" YPos="320" Width="15" Height="15" />
<Image Name="IconMODx4" XPos="286" YPos="336" Width="15" Height="15" />
-
<Image Name="IconStorageNormal" XPos="410" YPos="256" Width="15" Height="15" />
<Image Name="IconStorageHover" XPos="426" YPos="256" Width="15" Height="15" />
@@ -201,8 +200,20 @@
<Image Name="MarketSellAllHover" XPos="454" YPos="193" Width="22" Height="17" />
<Image Name="MarketSellAllPushed" XPos="477" YPos="193" Width="22" Height="17" />
+ <Image Name="ShipConfigEquipmentItemWindowNormal" XPos="1" YPos="405" Width="121" Height="106" />
+ <Image Name="ShipConfigEquipmentItemWindowHover" XPos="123" YPos="405" Width="121" Height="106" />
+ <Image Name="ShipConfigEquipmentLoadBlue" XPos="245" YPos="405" Width="28" Height="21" />
+ <Image Name="ShipConfigEquipmentLoadGreen" XPos="245" YPos="426" Width="28" Height="21" />
+ <Image Name="ShipConfigEquipmentLoadRed" XPos="245" YPos="447" Width="28" Height="21" />
+ <Image Name="ShipConfigEquipmentRightArrow" XPos="245" YPos="468" Width="14" Height="12" />
+ <Image Name="ShipConfigEquipmentLeftArrow" XPos="245" YPos="481" Width="14" Height="12" />
+ <Image Name="ShipConfigEquipmentPrevItemNormal" XPos="274" YPos="405" Width="11" Height="21" />
+ <Image Name="ShipConfigEquipmentPrevItemHover" XPos="274" YPos="427" Width="11" Height="21" />
+ <Image Name="ShipConfigEquipmentNextItemNormal" XPos="286" YPos="405" Width="11" Height="21" />
+ <Image Name="ShipConfigEquipmentNextItemHover" XPos="286" YPos="427" Width="11" Height="21" />
+
<Image Name="AltProgressLeft" XPos="10" YPos="10" Width="10" Height="10" />
<Image Name="AltProgressMiddle" XPos="20" YPos="10" Width="10" Height="10" />
<Image Name="AltProgressRight" XPos="30" YPos="10" Width="10" Height="10" />
Modified: branches/ogsector/data/gui/schemes/opengate/opengate.png
===================================================================
(Binary files differ)
Modified: branches/ogsector/src/Avatar.cpp
===================================================================
--- branches/ogsector/src/Avatar.cpp 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/src/Avatar.cpp 2007-06-12 17:12:12 UTC (rev 552)
@@ -24,7 +24,6 @@
namespace OpenGate{
Avatar::Avatar( const std::string & name, int ID ): name_( name ), id_( ID ) {
- setVessel( *VesselManager::getSingleton().vessel( "apteryx" ) );
cargoHold_ = 0;
}
@@ -33,9 +32,6 @@
void Avatar::setVessel( Vessel & vessel ){
vessel_ = & vessel;
- std::cout << "setVessel " << vessel_->name() << " " << vessel_->allEquipmentMaximumSize()
- << " " << vessel_->cargoSize() << std::endl;
-
maxCargoHold_ = vessel_->allEquipmentMaximumSize() + vessel_->cargoSize();
}
@@ -84,5 +80,55 @@
}
}
}
+
+bool Avatar::loadItem( Entity * item ){
+
+ std::vector < Entity * > items; items.push_back( item );
+
+ switch( item->entityType() ){
+ case POWERPLANT:
+ if ( vessel_->setPowerPlant( dynamic_cast< PowerPlant *>(item) ) ){ delCargoToFloor( items ); return true; }
+ break;
+ case ENGINE:
+ if ( vessel_->setEngine( dynamic_cast< Engine * >(item) ) ){ delCargoToFloor( items ); return true; }
+ break;
+ case RADAR:
+ if ( vessel_->setRadar( dynamic_cast< Radar * >(item) ) ){ delCargoToFloor( items ); return true; }
+ break;
+ case ECM:
+ if ( vessel_->setEcm( dynamic_cast< Ecm * >(item) ) ){ delCargoToFloor( items ); return true; }
+ break;
+ case SHIELD:
+ if ( vessel_->setShield( dynamic_cast< Shield * >(item) ) ){ delCargoToFloor( items ); return true; }
+ break;
+ case CAPACITOR:
+ if ( vessel_->setCapacitor( dynamic_cast< Capacitor * >(item) ) ){ delCargoToFloor( items ); return true; }
+ break;
+ }
+ return false;
+}
+
+bool Avatar::unLoadItem( Entity * item ){
+
+ switch( item->entityType() ){
+ case POWERPLANT: vessel_->setPowerPlant( NULL );
+ break;
+ case ENGINE: vessel_->setEngine( NULL );
+ break;
+ case RADAR: vessel_->setRadar( NULL );
+ break;
+ case ECM: vessel_->setEcm( NULL );
+ break;
+ case SHIELD: vessel_->setShield( NULL );
+ break;
+ case CAPACITOR: vessel_->setCapacitor( NULL );
+ break;
+ }
+
+ std::vector < Entity * > items; items.push_back( item );
+ addCargoToFloor( items );
+ return true;
+}
+
} // namespace OpenGate{
Modified: branches/ogsector/src/Avatar.h
===================================================================
--- branches/ogsector/src/Avatar.h 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/src/Avatar.h 2007-06-12 17:12:12 UTC (rev 552)
@@ -44,7 +44,7 @@
int userID() const { return id_; }
void setVessel( Vessel & vessel );
- Vessel & vessel() { return *vessel_; }
+ Vessel * vessel() { return vessel_; }
void addCargoToFloor( const std::vector < Entity * > & item );
void delCargoToFloor( const std::vector < Entity * > & item );
@@ -54,6 +54,9 @@
std::list< std::deque < Entity * > > * floorCargo() { return & floorCargo_; }
+ bool loadItem( Entity * item );
+ bool unLoadItem( Entity * item );
+
protected:
std::string name_;
int id_;
Modified: branches/ogsector/src/BaseDialog.cpp
===================================================================
--- branches/ogsector/src/BaseDialog.cpp 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/src/BaseDialog.cpp 2007-06-12 17:12:12 UTC (rev 552)
@@ -21,10 +21,33 @@
#include "BaseDialog.h"
#include "DeviceManager.h"
+#include <OgreRenderWindow.h>
+
#include <CEGUIWindowManager.h>
namespace OpenGate{
+void renameClonedWindows( const CEGUI::Window * parent, const CEGUI::String & namePrefix) {
+ // std::cout << parent->getName() << ": " << parent->getChildCount() << std::endl;
+
+ for ( int i = 0; i < parent->getChildCount(); i ++ ){
+ // std::cout << i << "accessing: "<< parent->getName() << std::endl;
+ CEGUI::Window * child = parent->getChildAtIdx( i );
+ child->rename( namePrefix + child->getName() );
+ renameClonedWindows( child, namePrefix );
+ }
+}
+
+float windowHeight( const CEGUI::Window * child ){
+ if ( child->getParent() ) return child->getHeight().asAbsolute( windowHeight( child->getParent() ) );
+ return child->getHeight().asAbsolute( DeviceManager::getSingleton().renderWindow->getHeight() );
+}
+
+float windowWidth( const CEGUI::Window * child ){
+ if ( child->getParent() ) return child->getWidth().asAbsolute( windowWidth( child->getParent() ) );
+ return child->getWidth().asAbsolute( DeviceManager::getSingleton().renderWindow->getWidth() );
+}
+
BaseDialog::BaseDialog( const std::string & layout )
: rootWindow_( CEGUI::WindowManager::getSingleton().loadWindowLayout( layout ) ),
devices_( DeviceManager::getSingletonPtr() ), visible_( false ) {
Modified: branches/ogsector/src/BaseDialog.h
===================================================================
--- branches/ogsector/src/BaseDialog.h 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/src/BaseDialog.h 2007-06-12 17:12:12 UTC (rev 552)
@@ -32,6 +32,10 @@
namespace OpenGate{
+void renameClonedWindows( const CEGUI::Window * parent, const CEGUI::String & namePrefix );
+float windowHeight( const CEGUI::Window * child );
+float windowWidth( const CEGUI::Window * child );
+
/*!
* \brief This is a base class for dialogs
*
Modified: branches/ogsector/src/DeviceManager.h
===================================================================
--- branches/ogsector/src/DeviceManager.h 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/src/DeviceManager.h 2007-06-12 17:12:12 UTC (rev 552)
@@ -30,7 +30,7 @@
namespace OpenGate{
-enum EntityType{ENTITY,VESSEL,COMMODITY,POWERPLANT,ENGINE,RADAR,ECM,CAPACITOR,SHIELD,GUN,MISSILE,MODX};
+enum EntityType{NONE,ENTITY,VESSEL,COMMODITY,POWERPLANT,ENGINE,RADAR,ECM,CAPACITOR,SHIELD,GUN,MISSILE,MODX};
/*!
* \brief This is a storage to handle current status of several things
@@ -86,7 +86,11 @@
case ENGINE: return "Engine";
case SHIELD: return "Shield";
case RADAR: return "Radar";
- default: return "unknown";
+ case ECM: return "ECM";
+ case GUN: return "GUN";
+ case MISSILE: return "MISSILE";
+ case MODX: return "MODx";
+ default: return "unknown";
}
return "unknown";
}
Modified: branches/ogsector/src/DockedState.cpp
===================================================================
--- branches/ogsector/src/DockedState.cpp 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/src/DockedState.cpp 2007-06-12 17:12:12 UTC (rev 552)
@@ -20,6 +20,8 @@
#include "DockedState.h"
#include "Console.h"
+#include "Avatar.h"
+#include "Vessel.h"
#include <OgreCEGUITexture.h>
#include <CEGUI/elements/CEGUIPushButton.h>
@@ -198,6 +200,31 @@
CEGUI::Window::EventSized, CEGUI::Event::Subscriber(&Console::handleResize, devices_->console ) ) ;
}
+bool DockedState::handleLaunch( const CEGUI::EventArgs & e ){
+ if ( !devices_->avatar->vessel()->powerPlant() ) {
+ log_->warn( "You have to equip a power plant first." );
+ return true;
+ }
+ if ( !devices_->avatar->vessel()->engine() ) {
+ log_->warn( "You have to equip an engine first." );
+ return true;
+ }
+
+ parent_->start( parent_->findByName( "UnDockedState" ) );
+ return true;
+}
+
+bool DockedState::handleShipConfigButton( const CEGUI::EventArgs & e ){
+ if ( shipConfigDialog_ ) shipConfigDialog_->setVisible( !shipConfigDialog_->isVisible() );
+ if ( marketDialog_ ) marketDialog_->hide();
+ return true;
+}
+bool DockedState::handleMarketButton( const CEGUI::EventArgs & e ){
+ if ( marketDialog_ ) marketDialog_->setVisible( !marketDialog_->isVisible() );
+ if ( shipConfigDialog_ ) shipConfigDialog_->hide();
+ return true;
+}
+
bool DockedState::switchConfigDialog( ){
devices_->gameStateRoot->switchConfigDialog( );
return true;
Modified: branches/ogsector/src/DockedState.h
===================================================================
--- branches/ogsector/src/DockedState.h 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/src/DockedState.h 2007-06-12 17:12:12 UTC (rev 552)
@@ -80,19 +80,10 @@
virtual ~DockedState(){}
inline bool handleQuit( const CEGUI::EventArgs & e ){ shutdown(); return true; }
- inline bool handleLaunch( const CEGUI::EventArgs & e ){
- parent_->start( parent_->findByName( "UnDockedState" ) );
- return true;
- }
- inline bool handleShipConfigButton( const CEGUI::EventArgs & e ){
- if ( shipConfigDialog_ ) shipConfigDialog_->setVisible( !shipConfigDialog_->isVisible() );
- return true;
- }
- inline bool handleMarketButton( const CEGUI::EventArgs & e ){
- if ( marketDialog_ ) marketDialog_->setVisible( !marketDialog_->isVisible() );
- return true;
- }
-
+ bool handleLaunch( const CEGUI::EventArgs & e );
+ bool handleShipConfigButton( const CEGUI::EventArgs & e );
+ bool handleMarketButton( const CEGUI::EventArgs & e );
+
inline bool handleMaximiseConsole( const CEGUI::EventArgs & e ){ return maximiseConsole(); }
inline bool handleMinimiseConsole( const CEGUI::EventArgs & e ){ return minimiseConsole(); }
inline bool handleConfigBackButton( const CEGUI::EventArgs & e ){ return switchConfigDialog(); }
Modified: branches/ogsector/src/Entity.cpp
===================================================================
--- branches/ogsector/src/Entity.cpp 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/src/Entity.cpp 2007-06-12 17:12:12 UTC (rev 552)
@@ -39,6 +39,7 @@
size_ = 1;
rtti_ = ENTITY;
factionID_ = 1;
+ imageInitialised_ = false;
setFactionName_( DeviceManager::getSingleton().factionName( factionID_ ) );
}
@@ -47,18 +48,17 @@
setFactionName_( DeviceManager::getSingleton().factionName( factionID_ ) );
}
-void Entity::setImageName( const std::string & imageFileName ) {
- imageFileName_ = imageFileName;
-
+void Entity::loadImages_( ) {
+ imageInitialised_ = true;
bool haveSmall = true;
- haveSmall = initialiseImage( imageFileName + "_76x76.png", imageFileName + "Small" );
+ haveSmall = initialiseImage( imageFileName_ + "_76x76.png", imageFileName_ + "Small" );
if ( haveSmall ){
ceguiSmallImageName_ = ceguiImageName_;
}
- if ( !initialiseImage( imageFileName + "_290x290.png", imageFileName ) ){
+ if ( !initialiseImage( imageFileName_ + "_290x290.png", imageFileName_ ) ){
//**fallback
- initialiseImage( imageFileName + ".png", imageFileName, true );
+ initialiseImage( imageFileName_ + ".png", imageFileName_, true );
}
if ( !haveSmall ) ceguiSmallImageName_ = ceguiImageName_;
Modified: branches/ogsector/src/Entity.h
===================================================================
--- branches/ogsector/src/Entity.h 2007-06-12 03:50:11 UTC (rev 551)
+++ branches/ogsector/src/Entity.h 2007-06-12 17:12:12 UTC (rev 552)
@@ -77,11 +77,10 @@
inline void setDescription( const std::string & description ){ description_ = description; }
inline std::string description( ) const { return description_; }
- void setImageName( const std::string & imageFileName );
-
+ inline void setImageName( const std::string & imageFileName ) { imageFileName_ = imageFileName; }
inline std::string imageName() const { return imageFileName_; }
- inline std::string ceguiImageName() const { return ceguiImageName_; }
- inline std::string ceguiSmallImageName() const { return ceguiSmallImageName_; }
+ inline std::string ceguiImageName() { if ( !imageInitialised_ ) loadImages_(); return ceguiImageName_; }
+ inline std::string ceguiSmallImageName() { if ( !imageInitialised_ ) loadImages_(); return ceguiSmallImageName_; }
bool initialiseImage( const std::string & imageName, const std::string & targetName, bool verbose = false );
@@ -95,6 +94,7 @@
protected:
inline void setFactionName_( const std::string & name ) { factionName_ = name; }
+ void loadImages_( );
std::string name_;
std::string className_;
@@ -107,6 +107,7 @@
std::string imageFileName_;
std::string ceguiSmallImageName_;
std::string ceguiImageName_;
+ bool imageInitialised_;
/*! The places where this part of equipment is built */
std::set < std::string > productionCenters_;
@@ -192,31 +193,29 @@
};
/*!
- * \brief This class stores the basical information of a Shield
+ * \brief This class stores the basical information of an engine
*
* This class, like all other equipment classes, is filled by loading the
- * information from an XML file. It defines the details for a shield, which
+ * information from an XML file. It defines the details for an engine, which
* is a component that is plugged into the ship.
* \author Christoph Brill <eg...@us...>
*/
-class Shield : public Equipment {
+class Engine : public Equipment {
public:
- Shield() : Equipment(){
- rtti_ = SHIELD;
+
+ Engine() : Equipment() {
+ rtti_ = ENGINE;
+ maxThrust_ = 0.0;
}
- void setMaximumDeflection( double deflection ){ setMaximumDeflection_ = deflection; }
- double maximumDeflection( ) const { return setMaximumDeflection_; }
+ inline void setMaxThrust( double maxThrust ) { maxThrust_ = maxThrust; }
+ inline double maxThrust( ) { return maxThrust_; }
- void setRegenerationRate( double regenRate ){ regenerationRate_ = regenRate; }
- double regenerationRate( ) const { return regenerationRate_; }
+ double powerConsumption( ) const { return ( maxThrust_ / 1000 ) / efficiency_; }
- double powerConsumption( ) const { return regenerationRate_ / efficiency_; }
-
-protected:
- double regenerationRate_;
- double setMaximumDeflection_;
-
+private:
+ /*! Stores the maximum thrust of this engine */
+ double maxThrust_;
};
/*!
@@ -232,87 +231,90 @@
Radar() : Equipment(){
rtti_ = RADAR;
}
- void setMaximumRange( double range ){ range_ = range; }
- double maximumRange() const{ return range_; }
+ void setMaxRange( double range ){ range_ = range; }
+ double maxRange() const{ return range_; }
protected:
double range_;
};
/*!
- * \brief This class stores the basical information of a capactitor
+ * \brief This class stores the basical information of an Ecm (Evasion and Counter Measures)
*
* This class, like all other equipment classes, is filled by loading the
- * information from an XML file. It...
[truncated message content] |