# HG changeset patch
# User smxx
# Date 1269265475 0
# Node ID 8466bd29280f3b818e08ff939f9bcc473cde79f8
# Parent 3acdb4dac6eb83bed521ee2407b3b9d23d03b276
Engine:
* Added animation to AI's thinking bubble
Frontend:
* Updated settings page to use new add/edit/delete buttons for teams and weapon schemes (delete buttons are disabled and invisible for now)
* Updated English and German locales
diff -r 3acdb4dac6eb -r 8466bd29280f QTfrontend/gamecfgwidget.cpp
--- a/QTfrontend/gamecfgwidget.cpp Mon Mar 22 11:52:16 2010 +0000
+++ b/QTfrontend/gamecfgwidget.cpp Mon Mar 22 13:44:35 2010 +0000
@@ -55,7 +55,6 @@
QPixmap pmEdit(":/res/edit.png");
QPushButton * goToSchemePage = new QPushButton(GBoxOptions);
- //goToSchemePage->setText(tr("Edit schemes"));
goToSchemePage->setToolTip(tr("Edit schemes"));
goToSchemePage->setIconSize(pmEdit.size());
goToSchemePage->setIcon(pmEdit);
@@ -71,7 +70,6 @@
connect(WeaponsName, SIGNAL(currentIndexChanged(int)), this, SLOT(ammoChanged(int)));
QPushButton * goToWeaponPage = new QPushButton(GBoxOptions);
- //goToWeaponPage->setText(tr("Edit weapons"));
goToWeaponPage->setToolTip(tr("Edit weapons"));
goToWeaponPage->setIconSize(pmEdit.size());
goToWeaponPage->setIcon(pmEdit);
diff -r 3acdb4dac6eb -r 8466bd29280f QTfrontend/hedgewars.qrc
--- a/QTfrontend/hedgewars.qrc Mon Mar 22 11:52:16 2010 +0000
+++ b/QTfrontend/hedgewars.qrc Mon Mar 22 13:44:35 2010 +0000
@@ -30,7 +30,9 @@
res/NetworkPlay.png
res/Settings.png
res/dropdown.png
+ res/new.png
res/edit.png
+ res/delete.png
res/checked.png
res/unchecked.png
res/graphicsicon.png
diff -r 3acdb4dac6eb -r 8466bd29280f QTfrontend/pages.cpp
--- a/QTfrontend/pages.cpp Mon Mar 22 11:52:16 2010 +0000
+++ b/QTfrontend/pages.cpp Mon Mar 22 13:44:35 2010 +0000
@@ -373,6 +373,11 @@
gbTBLayout->setMargin(0);
gbTBLayout->setSpacing(0);
gbTBLayout->setAlignment(Qt::AlignTop | Qt::AlignLeft);
+
+ QPixmap pmNew(":/res/new.png");
+ QPixmap pmEdit(":/res/edit.png");
+ QPixmap pmDelete(":/res/delete.png");
+
{
teamsBox = new IconedGroupBox(this);
//teamsBox->setContentTopPadding(0);
@@ -381,22 +386,40 @@
teamsBox->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed);
teamsBox->setTitle(QGroupBox::tr("Teams"));
- QVBoxLayout * GBTlayout = new QVBoxLayout(teamsBox);
+ QGridLayout * GBTlayout = new QGridLayout(teamsBox);
CBTeamName = new QComboBox(teamsBox);
- GBTlayout->addWidget(CBTeamName);
+ GBTlayout->addWidget(CBTeamName, 0, 0);
+
+ BtnNewTeam = new QPushButton(teamsBox);
+ BtnNewTeam->setToolTip(tr("New team"));
+ BtnNewTeam->setIconSize(pmNew.size());
+ BtnNewTeam->setIcon(pmNew);
+ BtnNewTeam->setMaximumWidth(pmNew.width() + 6);
+ GBTlayout->addWidget(BtnNewTeam, 0, 1);
- QHBoxLayout * layout1 = new QHBoxLayout;
- GBTlayout->addLayout(layout1);
- BtnNewTeam = addButton(tr("New team"), layout1, 0);
- BtnEditTeam = addButton(tr("Edit team"), layout1, 1);
- layout1->setStretchFactor(BtnNewTeam, 100);
- layout1->setStretchFactor(BtnEditTeam, 100);
+ BtnEditTeam = new QPushButton(teamsBox);
+ BtnEditTeam->setToolTip(tr("Edit team"));
+ BtnEditTeam->setIconSize(pmEdit.size());
+ BtnEditTeam->setIcon(pmEdit);
+ BtnEditTeam->setMaximumWidth(pmEdit.width() + 6);
+ GBTlayout->addWidget(BtnEditTeam, 0, 2);
+
+ BtnDeleteTeam = new QPushButton(teamsBox);
+ BtnDeleteTeam->setToolTip(tr("Delete team"));
+ BtnDeleteTeam->setIconSize(pmDelete.size());
+ BtnDeleteTeam->setIcon(pmDelete);
+ BtnDeleteTeam->setMaximumWidth(pmDelete.width() + 6);
+ BtnDeleteTeam->setEnabled(false);
+ BtnDeleteTeam->setVisible(false); // hide for now
+ GBTlayout->addWidget(BtnDeleteTeam, 0, 3);
gbTBLayout->addWidget(teamsBox, 0, 0);
}
{
+ // TODO: This box should contain controls for all schemes: game modes and weapons
+
IconedGroupBox* groupWeapons = new IconedGroupBox(this);
//groupWeapons->setContentTopPadding(0);
groupWeapons->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
@@ -405,14 +428,35 @@
groupWeapons->setTitle(QGroupBox::tr("Weapons"));
QGridLayout * WeaponsLayout = new QGridLayout(groupWeapons);
- WeaponsButt = addButton(tr("Weapons set"), WeaponsLayout, 1, 0);
- WeaponsName = new QComboBox(this);
- WeaponsLayout->addWidget(WeaponsName, 0, 0, 1, 2);
- WeaponEdit = addButton(tr("Edit"), WeaponsLayout, 1, 1);
+ WeaponsName = new QComboBox(groupWeapons);
+ WeaponsLayout->addWidget(WeaponsName, 0, 0);
+
+ WeaponsButt = new QPushButton(groupWeapons);
+ WeaponsButt->setToolTip(tr("New weapon scheme"));
+ WeaponsButt->setIconSize(pmNew.size());
+ WeaponsButt->setIcon(pmNew);
+ WeaponsButt->setMaximumWidth(pmNew.width() + 6);
+ WeaponsLayout->addWidget(WeaponsButt, 0, 1);
+
+ WeaponEdit = new QPushButton(groupWeapons);
+ WeaponEdit->setToolTip(tr("Edit weapon scheme"));
+ WeaponEdit->setIconSize(pmEdit.size());
+ WeaponEdit->setIcon(pmEdit);
+ WeaponEdit->setMaximumWidth(pmEdit.width() + 6);
+ WeaponsLayout->addWidget(WeaponEdit, 0, 2);
+
+ WeaponDelete = new QPushButton(groupWeapons);
+ WeaponDelete->setToolTip(tr("Delete weapon scheme"));
+ WeaponDelete->setIconSize(pmDelete.size());
+ WeaponDelete->setIcon(pmDelete);
+ WeaponDelete->setMaximumWidth(pmDelete.width() + 6);
+ WeaponDelete->setEnabled(false);
+ WeaponDelete->setVisible(false); // hide for now
+ WeaponsLayout->addWidget(WeaponDelete, 0, 3);
WeaponTooltip = new QCheckBox(this);
WeaponTooltip->setText(QCheckBox::tr("Show ammo menu tooltips"));
- WeaponsLayout->addWidget(WeaponTooltip, 2, 0, 1, 2);
+ WeaponsLayout->addWidget(WeaponTooltip, 1, 0, 1, 3);
gbTBLayout->addWidget(groupWeapons, 1, 0);
}
diff -r 3acdb4dac6eb -r 8466bd29280f QTfrontend/pages.h
--- a/QTfrontend/pages.h Mon Mar 22 11:52:16 2010 +0000
+++ b/QTfrontend/pages.h Mon Mar 22 13:44:35 2010 +0000
@@ -204,6 +204,7 @@
QPushButton *WeaponsButt;
QPushButton *WeaponEdit;
+ QPushButton *WeaponDelete;
QComboBox *WeaponsName;
QCheckBox *WeaponTooltip;
QComboBox *CBLanguage;
@@ -212,6 +213,7 @@
IconedGroupBox *teamsBox;
QPushButton *BtnNewTeam;
QPushButton *BtnEditTeam;
+ QPushButton *BtnDeleteTeam;
QComboBox *CBTeamName;
IconedGroupBox *AGGroupBox;
QComboBox *CBResolution;
diff -r 3acdb4dac6eb -r 8466bd29280f QTfrontend/res/delete.png
Binary file QTfrontend/res/delete.png has changed
diff -r 3acdb4dac6eb -r 8466bd29280f QTfrontend/res/new.png
Binary file QTfrontend/res/new.png has changed
diff -r 3acdb4dac6eb -r 8466bd29280f hedgewars/uGears.pas
--- a/hedgewars/uGears.pas Mon Mar 22 11:52:16 2010 +0000
+++ b/hedgewars/uGears.pas Mon Mar 22 13:44:35 2010 +0000
@@ -1409,7 +1409,7 @@
if (Gear^.State and gstDrowning) = 0 then
if (Gear^.State and gstHHThinking) <> 0 then
- DrawSprite(sprQuestion, hwRound(Gear^.X) - 10 + WorldDx, hwRound(Gear^.Y) - cHHRadius - 34 + WorldDy, 0)
+ DrawSprite(sprQuestion, hwRound(Gear^.X) - 10 + WorldDx, hwRound(Gear^.Y) - cHHRadius - 34 + WorldDy, (RealTicks shr 9) mod 8)
end
end;
diff -r 3acdb4dac6eb -r 8466bd29280f share/hedgewars/Data/Graphics/thinking.png
Binary file share/hedgewars/Data/Graphics/thinking.png has changed
diff -r 3acdb4dac6eb -r 8466bd29280f share/hedgewars/Data/Locale/hedgewars_de.qm
Binary file share/hedgewars/Data/Locale/hedgewars_de.qm has changed
diff -r 3acdb4dac6eb -r 8466bd29280f share/hedgewars/Data/Locale/hedgewars_de.ts
--- a/share/hedgewars/Data/Locale/hedgewars_de.ts Mon Mar 22 11:52:16 2010 +0000
+++ b/share/hedgewars/Data/Locale/hedgewars_de.ts Mon Mar 22 13:44:35 2010 +0000
@@ -330,11 +330,27 @@
- Waffen-Set
+ Waffen-Set
- Bearbeiten
+ Bearbeiten
+
+
+
+ Team löschen
+
+
+
+ Neue Waffenzusammenstellung
+
+
+
+ Waffenzusammenstellung bearbeiten
+
+
+
+ Waffenzusammenstellung löschen
@@ -661,7 +677,7 @@
- Kurzinfos für Waffen anzeigen
+ Kurzinfos für Waffen anzeigen
@@ -694,6 +710,10 @@
(Systemstandard)
+
+
+ Mission
+
QGroupBox
@@ -884,6 +904,10 @@
Spiel neu starten, um Änderungen zu übernehmen
+
+
+ Pulverfässer
+
QLineEdit
diff -r 3acdb4dac6eb -r 8466bd29280f share/hedgewars/Data/Locale/hedgewars_en.qm
Binary file share/hedgewars/Data/Locale/hedgewars_en.qm has changed
diff -r 3acdb4dac6eb -r 8466bd29280f share/hedgewars/Data/Locale/hedgewars_en.ts
--- a/share/hedgewars/Data/Locale/hedgewars_en.ts Mon Mar 22 11:52:16 2010 +0000
+++ b/share/hedgewars/Data/Locale/hedgewars_en.ts Mon Mar 22 13:44:35 2010 +0000
@@ -12,11 +12,11 @@
FreqSpinBox
-
+ Never
-
+
Each turn
Every %1 turns
@@ -45,19 +45,19 @@
HWChatWidget
-
+ %1 *** %2 has been removed from your ignore list
-
+ %1 *** %2 has been added to your ignore list
-
+ %1 *** %2 has been removed from your friends list
-
+ %1 *** %2 has been added to your friends list
@@ -257,14 +257,14 @@
-
+
<p>The best killer is <b>%1</b> with <b>%2</b> kill in a turn.</p>
<p>The best killer is <b>%1</b> with <b>%2</b> kills in a turn.</p>
-
+
<p>A total of <b>%1</b> hedgehog was killed during this round.</p>
<p>A total of <b>%1</b> hedgehogs were killed during this round.</p>
@@ -329,11 +329,27 @@
- Weapons set
+ Weapons set
- Edit
+ Edit
+
+
+
+ Delete team
+
+
+
+ New weapon scheme
+
+
+
+ Edit weapon scheme
+
+
+
+ Delete weapon scheme
@@ -395,48 +411,50 @@
-
+ Room Name:
-
+ This game is in lobby.
+You may join and start playing once the game starts.
-
+ This game is in progress.
+You may join and spectate now but you'll have to wait for the game to end to start playing.
-
+ %1 is the host. He may adjust settings and start the game.
-
+ Random Map
-
+ Games may be played on precreated or randomized maps.
-
+ The Game Scheme defines general options and preferences like Round Time, Sudden Death or Vampirism.
-
+ The Weapon Scheme defines available weapons and their ammunition count.
-
+
There is %1 client connected to this room.
There are %1 clients connected to this room.
-
+
There is %1 team participating in this room.
There are %1 teams participating in this room.
@@ -514,23 +532,23 @@
-
+ Order of play is random instead of in room order.
-
+ Play with a King. If he dies, your side dies.
-
+ Take turns placing your hedgehogs before the start of play.
-
+ Ammo is shared between all teams that share a colour.
-
+ Disable girders when generating random maps.
@@ -595,23 +613,23 @@
-
+ Follow
-
+ Ignore
-
+ Add friend
-
+ Unignore
-
+ Remove friend
@@ -650,23 +668,23 @@
-
+ Reduced quality
-
+ Show ammo menu tooltips
-
+ Enable frontend sounds
-
+ Enable frontend music
-
+ Frontend effects
@@ -685,7 +703,11 @@
-
+ (System default)
+
+
+
+ Mission
@@ -736,11 +758,11 @@
-
+ Team Settings
-
+ Misc
@@ -847,35 +869,39 @@
-
+ % Dud Mines
-
+ Name
-
+ Type
-
+ Grave
-
+ Flag
-
+ Voice
-
+ Locale
-
+ Restart game to apply
+
+
+
+ Explosives
@@ -1018,38 +1044,38 @@
-
+ Random Team
QTableWidget
-
+ Room Name
-
+ C
-
+ T
-
+ Owner
- Map
+ Map
-
+ Rules
- Weapons
+ Weapons
@@ -1064,11 +1090,11 @@
-
+ Ammo in boxes
-
+ Delays
@@ -1134,23 +1160,23 @@
-
+ Random Order
-
+ King
-
+ Place Hedgehogs
-
+ Clan Shares Ammo
-
+ Disable Girders
@@ -1307,97 +1333,97 @@
-
+ long jump
-
+ high jump
binds (categories)
-
+ Basic controls
-
+ Weapon controls
-
+ Camera and cursor controls
- Other
+ Other
binds (descriptions)
-
+ Move your hogs and aim:
-
+ Traverse gaps and obstacles by jumping:
-
+ Fire your selected weapon or trigger an utility item:
-
+ Pick a weapon or a target location under the cursor:
-
+ Switch your currently active hog (if possible):
-
+ Pick a weapon or utility item:
-
+ Set the timer on bombs and timed weapons:
-
+ Move the camera to the active hog:
-
+ Move the cursor or camera without using the mouse:
-
+ Modify the camera's zoom level:
-
+ Talk to your team or all participants:
-
+ Pause, continue or leave your game:
-
+ Modify the game's volume while playing:
-
+ Toggle fullscreen mode:
-
+ Take a screenshot:
-
+ Toggle labels above hedgehogs: