]> www.infradead.org Git - users/mchehab/andors-trail.git/commitdiff
Fixed lots of Android lint warnings.
authoroskar.wiksten <oskar.wiksten@08aca716-68be-ccc6-4d58-36f5abd142ac>
Sat, 24 Mar 2012 11:28:14 +0000 (11:28 +0000)
committeroskar.wiksten <oskar.wiksten@08aca716-68be-ccc6-4d58-36f5abd142ac>
Sat, 24 Mar 2012 11:28:14 +0000 (11:28 +0000)
New graphics for red damage animation.
Added better script triggers to Mikhail's conversation while doing the bread and rats quests.
Start outline of new minor quest for v0.6.11 (sisterfight).
Re-spawn monsters that were not unique in v0.6.10 (issue 301).

git-svn-id: https://andors-trail.googlecode.com/svn/trunk@225 08aca716-68be-ccc6-4d58-36f5abd142ac

56 files changed:
AndorsTrail/.classpath
AndorsTrail/lint.xml
AndorsTrail/res/drawable/effect_blood4.png [new file with mode: 0644]
AndorsTrail/res/layout/actorconditioninfo.xml
AndorsTrail/res/layout/bulkselection.xml
AndorsTrail/res/layout/combatview.xml
AndorsTrail/res/layout/conversation_statement.xml
AndorsTrail/res/layout/heroinfo_skill_list.xml
AndorsTrail/res/layout/heroinfo_stats.xml
AndorsTrail/res/layout/heroinfo_statsicons.xml
AndorsTrail/res/layout/iteminfo.xml
AndorsTrail/res/layout/levelup.xml
AndorsTrail/res/layout/loadsave.xml
AndorsTrail/res/layout/monsterencounter.xml
AndorsTrail/res/layout/monsterinfo.xml
AndorsTrail/res/layout/rangebar.xml
AndorsTrail/res/layout/shop.xml
AndorsTrail/res/layout/shopitemview.xml
AndorsTrail/res/layout/skill_info_view.xml
AndorsTrail/res/layout/skill_listentry_view.xml
AndorsTrail/res/values-fr/content_conversationlist.xml
AndorsTrail/res/values-it/content_conversationlist.xml
AndorsTrail/res/values-it/strings.xml
AndorsTrail/res/values-ru/content_conversationlist.xml
AndorsTrail/res/values/content_conversationlist.xml
AndorsTrail/res/values/content_droplist.xml
AndorsTrail/res/values/content_itemlist.xml
AndorsTrail/res/values/content_questlist.xml
AndorsTrail/res/values/loadresources_debug.xml
AndorsTrail/res/values/ui_theme.xml
AndorsTrail/src/com/gpl/rpg/AndorsTrail/VisualEffectCollection.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/ActorConditionInfoActivity.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/BulkSelectionInterface.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/ConversationActivity.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/DebugInterface.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/HeroinfoActivity_Stats.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/ItemInfoActivity.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/LevelUpActivity.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/LoadSaveActivity.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/MonsterEncounterActivity.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/MonsterInfoActivity.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/activity/SkillInfoActivity.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/controller/CombatController.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/controller/SkillController.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/model/CombatTraits.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/model/ability/SkillCollection.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/model/actor/Player.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/model/map/PredefinedMap.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/model/quest/Quest.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/resource/DynamicTileLoader.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/resource/ResourceLoader.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/resource/parsers/MonsterTypeParser.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/resource/tiles/TileCache.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/resource/tiles/TileManager.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/util/ConstRange.java
AndorsTrail/src/com/gpl/rpg/AndorsTrail/view/SkillListAdapter.java

index 6c635c01d50ff53eac279f3c78174168e37a7517..6aed2ebfbe289baffd92e6cfea420f2c88d90989 100644 (file)
@@ -3,5 +3,6 @@
        <classpathentry kind="src" path="src"/>
        <classpathentry kind="src" path="gen"/>
        <classpathentry kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
+       <classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/>
        <classpathentry kind="output" path="bin/classes"/>
 </classpath>
index 8a7b1fac8f8c12e925e56776f225730c4712f92a..c9b98be42b943c583150bc3720a3cb4859e5e63c 100644 (file)
@@ -1,4 +1,8 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <lint>
-    <issue id="MissingTranslation" severity="warning" />
+    <issue id="MissingTranslation" severity="ignore" />
+    <issue id="StringFormatMatches" severity="ignore" />
+    <issue id="TypographyDashes" severity="ignore" />
+    <issue id="TypographyEllipsis" severity="ignore" />
+    <issue id="TypographyOther" severity="ignore" />
 </lint>
\ No newline at end of file
diff --git a/AndorsTrail/res/drawable/effect_blood4.png b/AndorsTrail/res/drawable/effect_blood4.png
new file mode 100644 (file)
index 0000000..c209039
Binary files /dev/null and b/AndorsTrail/res/drawable/effect_blood4.png differ
index 4db03771b24c541f76a0afe81eaf5b9936d59261..e32c6b6fd0dba89e7e2bb356d5d4348516c5f0f5 100644 (file)
                        android:orientation="vertical"
                        android:padding="@dimen/dialog_margin"
                        >
-                       <LinearLayout
+                       <TextView
+                               android:id="@+id/actorconditioninfo_title"
                                android:layout_width="match_parent"
                                android:layout_height="wrap_content"
-                               android:orientation="horizontal"
-                               android:gravity="center_vertical"
-                               >
-                               <ImageView 
-                                       android:id="@+id/actorconditioninfo_image"
-                                       android:layout_width="wrap_content"
-                                       android:layout_height="wrap_content"
-                                       android:src="@drawable/equip_weapon" 
-                                       android:paddingRight="@dimen/dialog_iconpadding_right"
-                                       android:paddingBottom="@dimen/dialog_iconpadding_bottom"
-                                       />
-                               <TextView
-                                       android:id="@+id/actorconditioninfo_title"
-                                       android:layout_width="match_parent"
-                                       android:layout_height="wrap_content"
-                                       android:text="Actor condition" 
-                                       android:textSize="@dimen/titletext"
-                                       />
-                       </LinearLayout>
+                               android:text="@string/actorinfo_currentconditions" 
+                               style="@style/titleWithIcon"
+                               android:drawableLeft="@drawable/equip_weapon"
+                               />
                        
                        <TextView 
                                android:text="@string/actorconditioninfo_category" 
index d6b70f95adbde342ead584b5c27a46ceefc0b4ef..fa8fa4fee3d7e98255af584a083693acf1f804aa 100644 (file)
                        android:padding="@dimen/dialog_margin"
                        >
                        
-                       <LinearLayout 
-                               android:layout_height="wrap_content"
+                       <TextView
+                               android:id="@+id/bulkselection_itemname"
                                android:layout_width="wrap_content"
-                               android:orientation="horizontal"
-                               android:gravity="center_vertical"
+                               android:layout_height="wrap_content"
                                android:layout_gravity="center_horizontal"
-                               >
-                               <ImageView 
-                                       android:id="@+id/bulkselection_itemimage"
-                                       android:layout_width="wrap_content"
-                                       android:layout_height="wrap_content"
-                                       android:src="@drawable/equip_weapon" 
-                                       android:paddingRight="@dimen/dialog_iconpadding_right"
-                                       android:paddingBottom="@dimen/dialog_iconpadding_bottom"
-                               />
-                               <TextView
-                                       android:id="@+id/bulkselection_itemname"
-                                       android:layout_width="wrap_content"
-                                       android:layout_height="wrap_content"
-                                       android:text="Item" 
-                                       android:textSize="@dimen/titletext"
-                                       />      
-                       </LinearLayout>
+                               android:text="@string/inventory_info" 
+                               style="@style/titleWithIcon"
+                               android:drawableLeft="@drawable/equip_weapon"
+                       />      
                        
                        <LinearLayout 
                                android:layout_height="wrap_content" 
index 5086c7b199d31d6faf40ff6c737bb1161096e3f2..92a72a6234b61f5d50172c05bea963010c7a568f 100644 (file)
@@ -16,7 +16,7 @@
                        android:layout_width="wrap_content"
                        android:layout_height="@dimen/smalltext_buttonheight"
                        android:textSize="@dimen/actionbar_text"
-                       android:text="Action"
+                       android:text="@string/combat_attack"
                        />
         
                <TextView android:id="@+id/combatview_status"
@@ -29,7 +29,7 @@
                        android:shadowRadius="1"
                        android:shadowColor="#000"
                        android:paddingBottom="4sp"
-                       android:text="AP"
+                       android:text="@string/status_ap"
                        />
 
                <Button android:id="@+id/combatview_endturn"
@@ -58,7 +58,7 @@
                android:shadowRadius="1"
                android:shadowColor="#000"
                android:paddingBottom="4sp"
-               android:text="Monsteraction"
+               android:text="@string/combat_monsteraction"
                android:gravity="center"
                />
        
@@ -75,6 +75,7 @@
                        android:layout_width="wrap_content"
                        android:layout_height="@dimen/smalltext_buttonheight"
                        android:layout_marginRight="5sp"
+                       android:contentDescription="@string/dialog_monsterencounter_info"
                        />
                
                <com.gpl.rpg.AndorsTrail.view.RangeBar
index 1476643ce9ee15744cb5d7b24c227f9732d46d58..9fc8e426cebc6d2784bc886af22d8c14b9a508a3 100644 (file)
@@ -1,28 +1,17 @@
 <?xml version="1.0" encoding="utf-8"?>
-<LinearLayout
+<TextView
        xmlns:android="http://schemas.android.com/apk/res/android"
+       android:id="@+id/conversation_text"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
-       android:orientation="horizontal"
+       android:text="@string/conversation_next"
+       android:textSize="@dimen/conversation_textsize"
+       android:shadowDx="1"
+       android:shadowDy="1"
+       android:shadowRadius="1"
+       android:shadowColor="#000"
+       android:drawableLeft="@drawable/char_hero"
+       android:drawablePadding="@dimen/dialog_iconpadding_right"
        android:gravity="center_vertical"
        android:paddingBottom="@dimen/conversation_statementpadding"
-       >
-       <ImageView 
-               android:id="@+id/conversation_image"
-               android:layout_width="wrap_content"
-               android:layout_height="wrap_content"
-               android:src="@drawable/char_hero" 
-               android:paddingRight="@dimen/dialog_iconpadding_right"
-               />
-       <TextView
-               android:id="@+id/conversation_text"
-               android:layout_width="match_parent"
-               android:layout_height="wrap_content"
-               android:text="Actor: Text"
-               android:textSize="@dimen/conversation_textsize"
-               android:shadowDx="1"
-               android:shadowDy="1"
-               android:shadowRadius="1"
-               android:shadowColor="#000"
-               />
-</LinearLayout>
+       />
index 2cf297655eae9b91886c006a2300a11605a603b9..0a6a08cbc0a7a4c2658a960c1c632f3d5a816c73 100644 (file)
@@ -7,7 +7,7 @@
        <TextView  
                android:layout_width="match_parent" 
                android:layout_height="wrap_content" 
-               android:text="You have N skill increases left"
+               android:text="@string/skill_number_of_increases_several"
                android:id="@+id/heroinfo_listskills_number_of_increases" 
                android:layout_marginBottom="@dimen/section_margin"
                android:layout_marginTop="@dimen/section_margin"
index 7ec762f4579a614429d8d62b27ac64532387e2cb..990fecc8a9f7d8eac0a0abe5e63c8affb18c3ac4 100644 (file)
 <?xml version="1.0" encoding="utf-8"?>
-<LinearLayout
-       xmlns:android="http://schemas.android.com/apk/res/android"
-       android:layout_width="match_parent"
-       android:layout_height="match_parent"
-       android:orientation="vertical"
-       android:layout_gravity="center_horizontal"
-       android:padding="@dimen/dialog_margin"
-       >
-
-       <ScrollView
-               android:layout_width="match_parent"
-               android:layout_height="wrap_content"
-               android:layout_weight="1"
-               >
-        
-               <LinearLayout
-                       xmlns:android="http://schemas.android.com/apk/res/android"
-                       android:layout_width="match_parent"
-                       android:layout_height="wrap_content"
-                       android:orientation="vertical"
-                       >
-
-                       <LinearLayout 
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               android:orientation="horizontal"
-                               android:gravity="center_vertical">
-               
-                               <ImageView
-                                       android:id="@+id/heroinfo_image"
-                                       android:layout_width="wrap_content"
-                                       android:layout_height="wrap_content" 
-                                       android:src="@drawable/char_hero"
-                                       android:paddingRight="@dimen/dialog_iconpadding_right"
-                                       android:paddingBottom="@dimen/dialog_iconpadding_bottom"
-                                       />
-                               <TextView
-                                       android:id="@+id/heroinfo_title"
-                                       android:layout_width="match_parent"
-                                       android:layout_height="wrap_content"
-                                       android:text="Name"
-                                       android:textSize="@dimen/titletext"
-                                       />
-                       </LinearLayout>
-                       
-                       <TableLayout
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               android:layout_marginBottom="@dimen/section_margin"
-                               >
-                               <TableRow>
-                                       <TextView android:text="@string/heroinfo_level" android:layout_marginRight="10sp" />
-                                       <TextView android:text="1" android:id="@+id/heroinfo_level" />
-                               </TableRow>
-                               <TableRow>
-                                       <TextView android:text="@string/heroinfo_totalexperience" android:layout_marginRight="10sp" />
-                                       <TextView android:text="1" android:id="@+id/heroinfo_totalexperience" />
-                               </TableRow>
-                               <TableRow>
-                                       <TextView android:text="@string/heroinfo_actionpoints" android:layout_marginRight="10sp" />
-                                       <TextView android:text="10/10" android:id="@+id/heroinfo_ap" />
-                               </TableRow>
-                               <TableRow>
-                                       <TextView android:text="@string/actorinfo_movecost" android:layout_marginRight="10sp" />
-                                       <TextView android:text="6" android:id="@+id/heroinfo_movecost" />
-                               </TableRow>
-                       </TableLayout>
-                               
-                       <com.gpl.rpg.AndorsTrail.view.RangeBar
-                               android:id="@+id/heroinfo_healthbar"
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               />
-                       <com.gpl.rpg.AndorsTrail.view.RangeBar
-                               android:id="@+id/heroinfo_expbar"
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               android:layout_marginTop="5sp"
-                               />
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:layout_gravity="center_horizontal"
+    android:orientation="vertical"
+    android:padding="@dimen/dialog_margin" >
 
-                       <TextView
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               android:text="@string/actorinfo_currenttraits"
-                               android:layout_marginTop="@dimen/section_margin"
-                               />
-                       <com.gpl.rpg.AndorsTrail.view.TraitsInfoView
-                               android:id="@+id/heroinfo_currenttraits"
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               />
-                       <com.gpl.rpg.AndorsTrail.view.ItemEffectsView
-                               android:id="@+id/heroinfo_itemeffects"
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               />
-                               
-                       <TextView
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               android:text="@string/actorinfo_currentconditions"
-                               android:id="@+id/heroinfo_currentconditions_title"
-                               android:layout_marginTop="@dimen/section_margin"
-                               />
-                       <com.gpl.rpg.AndorsTrail.view.ActorConditionList
-                               android:id="@+id/heroinfo_currentconditions"
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               />
-                       
-                       <TextView
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               android:text="@string/actorinfo_basetraits"
-                               android:layout_marginTop="@dimen/section_margin"
-                               />
-                       <com.gpl.rpg.AndorsTrail.view.BaseTraitsInfoView
-                               android:id="@+id/heroinfo_basetraits"
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
+    <ScrollView
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_weight="1" >
+
+        <LinearLayout
+            xmlns:android="http://schemas.android.com/apk/res/android"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:orientation="vertical" >
+
+            <TextView
+                android:id="@+id/heroinfo_title"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                style="@style/titleWithIcon"
+                android:drawableLeft="@drawable/char_hero"
+                android:text="Name"
                                />
-                       
-               </LinearLayout>
-       </ScrollView>
-
-       <LinearLayout 
-               android:layout_width="match_parent"
-               android:layout_height="wrap_content"
-               android:orientation="horizontal"
-               android:gravity="center_vertical">
-               <Button
-                       android:id="@+id/heroinfo_levelup"
-                       android:layout_width="match_parent"
+
+            <TableLayout
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginBottom="@dimen/section_margin" >
+
+                <TableRow>
+                    <TextView android:layout_marginRight="10sp" android:text="@string/heroinfo_level" />
+                    <TextView android:id="@+id/heroinfo_level" android:text="1" />
+                </TableRow>
+
+                <TableRow>
+                    <TextView android:layout_marginRight="10sp" android:text="@string/heroinfo_totalexperience" />
+                    <TextView android:id="@+id/heroinfo_totalexperience" android:text="1" />
+                </TableRow>
+
+                <TableRow>
+                    <TextView android:layout_marginRight="10sp" android:text="@string/heroinfo_actionpoints" />
+                    <TextView android:id="@+id/heroinfo_ap" android:text="10/10" />
+                </TableRow>
+
+                <TableRow>
+                    <TextView android:layout_marginRight="10sp" android:text="@string/actorinfo_movecost" />
+                    <TextView android:id="@+id/heroinfo_movecost" android:text="6" />
+                </TableRow>
+            </TableLayout>
+
+            <com.gpl.rpg.AndorsTrail.view.RangeBar
+                android:id="@+id/heroinfo_healthbar"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content" />
+
+            <com.gpl.rpg.AndorsTrail.view.RangeBar
+                android:id="@+id/heroinfo_expbar"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="5sp" />
+
+            <TextView
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="@dimen/section_margin"
+                android:text="@string/actorinfo_currenttraits" />
+
+            <com.gpl.rpg.AndorsTrail.view.TraitsInfoView
+                android:id="@+id/heroinfo_currenttraits"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content" />
+
+            <com.gpl.rpg.AndorsTrail.view.ItemEffectsView
+                android:id="@+id/heroinfo_itemeffects"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content" />
+
+            <TextView
+                android:id="@+id/heroinfo_currentconditions_title"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="@dimen/section_margin"
+                android:text="@string/actorinfo_currentconditions" />
+
+            <com.gpl.rpg.AndorsTrail.view.ActorConditionList
+                android:id="@+id/heroinfo_currentconditions"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content" />
+
+            <TextView
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="@dimen/section_margin"
+                android:text="@string/actorinfo_basetraits" />
+
+            <com.gpl.rpg.AndorsTrail.view.BaseTraitsInfoView
+                android:id="@+id/heroinfo_basetraits"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content" />
+        </LinearLayout>
+    </ScrollView>
+
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:gravity="center_vertical"
+        android:orientation="horizontal" >
+
+        <Button
+            android:id="@+id/heroinfo_levelup"
+            android:layout_width="match_parent"
             android:layout_height="wrap_content"
                android:layout_weight="1"
-               android:text="@string/heroinfo_levelup"
-                       />
-       </LinearLayout>
+            android:text="@string/heroinfo_levelup" />
+    </LinearLayout>
 
-</LinearLayout>
+</LinearLayout>
\ No newline at end of file
index 5fa5f8b2391242614456a98f1016f2c3cf8fe473..4279ae365e1db259dc2ac3206f1af778cbbf305f 100644 (file)
@@ -1,83 +1,35 @@
 <?xml version="1.0" encoding="utf-8"?>
-<LinearLayout
-       xmlns:android="http://schemas.android.com/apk/res/android"
-       android:layout_width="match_parent"
-       android:layout_height="wrap_content"
-       android:orientation="vertical"
-       android:gravity="right"
-       >
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="wrap_content"
+    android:gravity="right"
+    android:orientation="vertical" >
 
-       <LinearLayout
-               android:layout_width="@dimen/boxshape_width"
-               android:layout_height="wrap_content"
-               android:orientation="horizontal"
-               android:gravity="center_vertical"
-               android:background="@drawable/ui_boxshape"
-               android:layout_margin="@dimen/boxshape_margin"
-               android:padding="@dimen/boxshape_margin"
-               
-               >
-               <ImageView 
-                       android:layout_width="wrap_content"
-                       android:layout_height="wrap_content"
-                       android:src="@drawable/ui_icon_coins"
-                       android:layout_marginRight="@dimen/boxshape_margin"
-                       />
-               <TextView 
-                       android:id="@+id/heroinfo_stats_gold"
-                       android:layout_width="wrap_content"
-                       android:layout_height="wrap_content"
-                       android:textSize="@dimen/smalltext"
-                       android:text="Gold: 0"
-                       />
-       </LinearLayout>
+    <TextView
+        android:id="@+id/heroinfo_stats_gold"
+        style="@style/statsBoxStyle"
+        android:layout_width="@dimen/boxshape_width"
+        android:layout_height="wrap_content"
+        android:drawableLeft="@drawable/ui_icon_coins"
+        android:text="@string/shop_yourgold"
+        />
 
-       <LinearLayout
-               android:layout_width="@dimen/boxshape_width"
-               android:layout_height="wrap_content"
-               android:orientation="horizontal"
-               android:gravity="center_vertical"
-               android:background="@drawable/ui_boxshape"
-               android:layout_margin="@dimen/boxshape_margin"
-               android:padding="@dimen/boxshape_margin"
-               >
-               <ImageView 
-                       android:layout_width="wrap_content"
-                       android:layout_height="wrap_content"
-                       android:src="@drawable/equip_weapon"
-                       android:layout_marginRight="@dimen/boxshape_margin"
-                       />
-               <TextView 
-                       android:id="@+id/heroinfo_stats_attack"
-                       android:layout_width="wrap_content"
-                       android:layout_height="wrap_content"
-                       android:textSize="@dimen/smalltext"
-                       android:text="Atk: "
-                       />
-       </LinearLayout>
+    <TextView
+        android:id="@+id/heroinfo_stats_attack"
+        style="@style/statsBoxStyle"
+        android:layout_width="@dimen/boxshape_width"
+        android:layout_height="wrap_content"
+        android:drawableLeft="@drawable/equip_weapon"
+        android:text="@string/actorinfo_attack"
+        />
+
+    <TextView
+        android:id="@+id/heroinfo_stats_defense"
+        style="@style/statsBoxStyle"
+        android:layout_width="@dimen/boxshape_width"
+        android:layout_height="wrap_content"
+        android:drawableLeft="@drawable/equip_shield"
+        android:text="@string/actorinfo_defense"
+               />
 
-       <LinearLayout
-               android:layout_width="@dimen/boxshape_width"
-               android:layout_height="wrap_content"
-               android:orientation="horizontal"
-               android:gravity="center_vertical"
-               android:background="@drawable/ui_boxshape"
-               android:layout_margin="@dimen/boxshape_margin"
-               android:padding="@dimen/boxshape_margin"
-               >
-               <ImageView 
-                       android:layout_width="wrap_content"
-                       android:layout_height="wrap_content"
-                       android:src="@drawable/equip_shield"
-                       android:layout_marginRight="@dimen/boxshape_margin"
-                       />
-               <TextView 
-                       android:id="@+id/heroinfo_stats_defense"
-                       android:layout_width="wrap_content"
-                       android:layout_height="wrap_content"
-                       android:textSize="@dimen/smalltext"
-                       android:text="Def: "
-                       />
-       </LinearLayout>
-       
 </LinearLayout>
\ No newline at end of file
index fb50ef935eae0b8d2c88ad291a93fdac3b063101..cf5ff3982ce1c2382f92939b6c39f3e7a284fcd1 100644 (file)
                        android:orientation="vertical"
                        android:padding="@dimen/dialog_margin"
                        >
-                       <LinearLayout
+                       <TextView
+                               android:id="@+id/iteminfo_title"
                                android:layout_width="match_parent"
                                android:layout_height="wrap_content"
-                               android:orientation="horizontal"
-                               android:gravity="center_vertical"
-                               >
-                               <ImageView 
-                                       android:id="@+id/iteminfo_image"
-                                       android:layout_width="wrap_content"
-                                       android:layout_height="wrap_content"
-                                       android:src="@drawable/equip_weapon" 
-                                       android:paddingRight="@dimen/dialog_iconpadding_right"
-                                       android:paddingBottom="@dimen/dialog_iconpadding_bottom"
-                               />
-                               <TextView
-                                       android:id="@+id/iteminfo_title"
-                                       android:layout_width="match_parent"
-                                       android:layout_height="wrap_content"
-                                       android:text="Item" 
-                                       android:textSize="@dimen/titletext"
-                               />
-                       </LinearLayout>
+                               android:text="@string/inventory_info" 
+                               style="@style/titleWithIcon"
+                               android:drawableLeft="@drawable/equip_weapon"
+                               />
                
                        <TextView 
                                android:id="@+id/iteminfo_displaytype"
index 22d8326932463f90e2f7552b3dcd7969a66c5424..25afe7adef8e63647a068ab97b1b359def97ca6e 100644 (file)
                android:orientation="vertical"
                >
        
-               <LinearLayout
+               <TextView
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
-                       android:orientation="horizontal"
-                       android:gravity="center_vertical"
-                       >
-                       <ImageView 
-                               android:id="@+id/levelup_image"
-                               android:layout_width="wrap_content"
-                               android:layout_height="wrap_content" 
-                               android:src="@drawable/char_hero"
-                               android:paddingRight="@dimen/dialog_iconpadding_right"
-                               android:paddingBottom="@dimen/dialog_iconpadding_bottom"
-                               />
-                       <TextView
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               android:text="@string/levelup_title" 
-                               android:textSize="@dimen/titletext"
-                               />
-               </LinearLayout>
-
+                       android:id="@+id/levelup_title" 
+                       android:text="@string/levelup_title" 
+                       style="@style/titleWithIcon"
+                       android:drawableLeft="@drawable/char_hero"
+                       />
+               
                <TextView 
                        android:id="@+id/levelup_description"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
-                       android:text="Welcome to level N!"
+                       android:text="@string/levelup_description"
                        />
                        
                <Button
                        android:text="@string/levelup_add_blockchance"
                        />
                
-               <LinearLayout
+               <TextView 
+                       android:id="@+id/levelup_adds_new_skillpoint"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
-                       android:orientation="horizontal"
-                       android:gravity="center_vertical"
-                       android:layout_marginBottom="@dimen/section_margin"
-                       android:id="@+id/levelup_adds_new_skillpoint"
-                       >
-                       <ImageView 
-                               android:layout_width="wrap_content"
-                               android:layout_height="wrap_content" 
-                               android:src="@drawable/ui_icon_skill"
-                               android:paddingRight="@dimen/dialog_iconpadding_right"
-                               android:paddingBottom="@dimen/dialog_iconpadding_bottom"
-                               />
-
-                       <TextView 
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               android:text="@string/levelup_adds_new_skillpoint"
-                               />
-               </LinearLayout>
+                       android:text="@string/levelup_adds_new_skillpoint"
+                       style="@style/textWithIcon"
+                       android:drawableLeft="@drawable/ui_icon_skill"
+                       />
 
                <!-- Workaround http://code.google.com/p/andors-trail/issues/detail?id=242 -->
                <ListView android:layout_width="match_parent" android:layout_height="1dp" />  
index e5bda89776e322cbc964c318fe49c30d3ba2d96b..4477a3f7a3c9c662398cb58c32774e4084dcd842 100644 (file)
@@ -1,49 +1,30 @@
 <?xml version="1.0" encoding="utf-8"?>
-<RelativeLayout
+<LinearLayout
        xmlns:android="http://schemas.android.com/apk/res/android"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:padding="@dimen/dialog_margin"
+       android:orientation="vertical"
        >
        
-       <LinearLayout
+       <TextView
+               android:id="@+id/loadsave_title"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
-               android:layout_alignParentTop="true"
-               android:orientation="horizontal"
-               android:gravity="center_vertical"
-               android:id="@+id/loadsave_titlelayout"
-               >
-               <ImageView 
-                       android:id="@+id/loadsave_image"
-                       android:layout_width="wrap_content"
-                       android:layout_height="wrap_content" 
-                       android:paddingRight="@dimen/dialog_iconpadding_right"
-                       android:paddingBottom="@dimen/dialog_iconpadding_bottom"
-                       />
-               <TextView
-                       android:id="@+id/loadsave_title"
-                       android:layout_width="match_parent"
-                       android:layout_height="wrap_content"
-                       android:text="@string/loadsave_title_save" 
-                       android:textSize="@dimen/titletext"
-                       />
-       </LinearLayout>
+               android:text="@string/loadsave_title_save" 
+               style="@style/titleWithIcon"
+               />
 
        <TextView 
                android:id="@+id/loadsave_description"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
-               android:layout_below="@id/loadsave_titlelayout"
-               android:layout_alignParentLeft="true"
                android:text="@string/loadsave_selectslot"
                />
                
        <ScrollView
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
-               android:layout_alignParentLeft="true"
-               android:layout_below="@id/loadsave_description"
                >
                <LinearLayout
                        android:id="@+id/loadsave_slot_list"
@@ -67,4 +48,4 @@
                
        </ScrollView>
 
-</RelativeLayout>
+</LinearLayout>
index 338ad7eb560ec9c12179731d5fe6b2106b8ba749..22430ded071d5f51f96151625bf40af4c7698b2d 100644 (file)
                android:orientation="vertical"
                android:padding="@dimen/dialog_margin"
                >
-               <LinearLayout
+               
+               <TextView
+                       android:id="@+id/monsterencounter_title"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
-                       android:orientation="horizontal"
-                       android:gravity="center_vertical"
-                       >
-                       <ImageView 
-                               android:id="@+id/monsterencounter_image"
-                               android:layout_width="wrap_content"
-                               android:layout_height="wrap_content"
-                               android:src="@drawable/equip_weapon" 
-                               android:paddingRight="@dimen/dialog_iconpadding_right"
-                               android:paddingBottom="@dimen/dialog_iconpadding_bottom"
-                               />
-                       <TextView
-                               android:id="@+id/monsterencounter_title"
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               android:text="Monster" 
-                               android:textSize="@dimen/titletext"
-                               />
-               </LinearLayout>
+                       android:text="@string/dialog_monsterencounter_title" 
+                       style="@style/titleWithIcon"
+                       android:drawableLeft="@drawable/equip_weapon"
+                       />
        
                <TextView 
                        android:id="@+id/monsterencounter_description"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
+                       android:text="@string/dialog_monsterencounter_message" 
                        />
        </LinearLayout>
        
index 5d02a4eb000c336c07d530942a292a6fff454be0..ef76a987cd9daea15bfd26f34e31796ca8cf3002 100644 (file)
                        android:orientation="vertical"
                        android:padding="@dimen/dialog_margin"
                        >
+                       
+                       <TextView
+                               android:id="@+id/monsterinfo_title"
+                               android:layout_width="match_parent"
+                               android:layout_height="wrap_content"
+                               android:text="@string/dialog_monsterencounter_info" 
+                               style="@style/titleWithIcon"
+                               android:drawableLeft="@drawable/char_hero"
+                               />
+                       
                        <LinearLayout
                                android:layout_width="match_parent"
                                android:layout_height="wrap_content"
                                android:orientation="horizontal"
-                               android:gravity="center_vertical"
+                               android:layout_marginBottom="@dimen/section_margin"
                                >
-                               <ImageView 
-                                       android:id="@+id/monsterinfo_image"
+                               <TextView 
+                                   android:text="@string/actorinfo_difficulty" 
+                                   android:layout_marginRight="10sp"
                                        android:layout_width="wrap_content"
                                        android:layout_height="wrap_content"
-                                       android:src="@drawable/char_hero" 
-                                       android:paddingRight="@dimen/dialog_iconpadding_right"
-                                       android:paddingBottom="@dimen/dialog_iconpadding_bottom"
                                        />
-                               <TextView
-                                       android:id="@+id/monsterinfo_title"
-                                       android:layout_width="match_parent"
+                               <TextView 
+                                   android:id="@+id/monsterinfo_difficulty"
+                                   android:text="@string/monster_difficulty_normal" 
+                                       android:layout_width="wrap_content"
                                        android:layout_height="wrap_content"
-                                       android:text="Monster" 
-                                       android:textSize="@dimen/titletext"
-                                       />
+                                   />
                        </LinearLayout>
-                       
-                       <TableLayout
-                               android:layout_width="match_parent"
-                               android:layout_height="wrap_content"
-                               android:layout_marginBottom="@dimen/section_margin"
-                               >
-                               <TableRow>
-                                       <TextView android:text="@string/actorinfo_difficulty" android:layout_marginRight="10sp" />
-                                       <TextView android:id="@+id/monsterinfo_difficulty" />
-                               </TableRow>
-                       </TableLayout>
        
                        <com.gpl.rpg.AndorsTrail.view.RangeBar
                                android:id="@+id/monsterinfo_healthbar"
             android:layout_height="wrap_content"
                android:layout_weight="1"
                android:text="@string/dialog_close"
-                       android:layout_alignParentRight="true"
                        />
        </LinearLayout>
 </LinearLayout>
index f29571c25a0d57e2cce30fcc71e7537ff11cb0a9..6bcbe58b2828b23d969d1e6230d1baf4e92b1e32 100644 (file)
@@ -9,7 +9,6 @@
                android:layout_width="30sp"
                android:layout_height="wrap_content"
                android:textSize="@dimen/statusbar_text"
-               android:text="Desc:"
                android:layout_marginRight="3sp"
                android:shadowDx="1"
                android:shadowDy="1"
@@ -33,7 +32,6 @@
                android:paddingLeft="35sp"
                android:textSize="@dimen/statusbar_text"
                android:layout_centerInParent="true"
-               android:text="value"
                android:textColor="#FFF"
                android:shadowDx="1"
                android:shadowDy="1"
index 8ed0f10edabe329bb40a78b49f746494a0f1d0bd..d71db63f37bc9ecfff61ea83fe829c04df03d5d2 100644 (file)
                                android:id="@+id/shop_tab1"
                                >
                        
-                               <LinearLayout
-                                       android:layout_width="match_parent"
+                               <TextView
+                                       android:layout_width="wrap_content"
                                        android:layout_height="wrap_content"
-                                       android:orientation="horizontal"
-                                       android:gravity="right|center_vertical"
-                                       >
-                               
-                                       <ImageView
-                                               android:layout_width="wrap_content"
-                                               android:layout_height="wrap_content"
-                                               android:src="@drawable/ui_icon_coins"
-                                               android:layout_marginRight="@dimen/boxshape_margin"
-                                               />
-                                               
-                                       <TextView
-                                               android:layout_width="wrap_content"
-                                               android:layout_height="wrap_content"
-                                               android:id="@+id/shop_buy_gc"
-                                               />
-                                               
-                               </LinearLayout>
+                                       android:id="@+id/shop_buy_gc"
+                                       android:drawableLeft="@drawable/ui_icon_coins"
+                                       android:drawablePadding="@dimen/boxshape_margin"
+                                       android:layout_gravity="right"
+                                       android:gravity="center_vertical"
+                                       />
                                
                                <ListView 
                                        android:id="@+id/shop_buy_list"
                                android:id="@+id/shop_tab2"
                                >
                        
-                               <LinearLayout
-                                       android:layout_width="match_parent"
+                               <TextView
+                                       android:layout_width="wrap_content"
                                        android:layout_height="wrap_content"
-                                       android:orientation="horizontal"
-                                       android:gravity="right|center_vertical"
-                                       >
-                               
-                                       <ImageView
-                                               android:layout_width="wrap_content"
-                                               android:layout_height="wrap_content"
-                                               android:src="@drawable/ui_icon_coins"
-                                               android:layout_marginRight="@dimen/boxshape_margin"
-                                               />
-                                               
-                                       <TextView
-                                               android:layout_width="wrap_content"
-                                               android:layout_height="wrap_content"
-                                               android:id="@+id/shop_sell_gc"
-                                               />
-                                               
-                               </LinearLayout>
+                                       android:id="@+id/shop_sell_gc"
+                                       android:drawableLeft="@drawable/ui_icon_coins"
+                                       android:drawablePadding="@dimen/boxshape_margin"
+                                       android:layout_gravity="right"
+                                       android:gravity="center_vertical"
+                                       />
                                
                                <ListView 
                                        android:id="@+id/shop_sell_list"
index 7d00d2c87901bf2110dfa958030798808d5410fb..653143755b20beb726867b1b6abc153804b3656b 100644 (file)
@@ -5,7 +5,6 @@
        android:layout_height="wrap_content"
        >
        <ImageView
-               xmlns:android="http://schemas.android.com/apk/res/android"
                android:id="@+id/shopitem_image"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_centerVertical="true"
                />
        <Button
-               xmlns:android="http://schemas.android.com/apk/res/android"
                android:id="@+id/shopitem_shopbutton"
                android:layout_width="wrap_content"
                android:layout_height="@dimen/smalltext_buttonheight"
                android:layout_alignParentRight="true"
                android:layout_centerVertical="true"
-               android:text="Shop"
+               android:text="@string/shop_buy"
                android:textSize="@dimen/smalltext"
                />
        <Button
-               xmlns:android="http://schemas.android.com/apk/res/android"
                android:id="@+id/shopitem_infobutton"
                android:layout_width="wrap_content"
                android:layout_height="@dimen/smalltext_buttonheight"
@@ -34,7 +31,6 @@
                android:text="@string/shop_infoitem"
                />
        <TextView
-               xmlns:android="http://schemas.android.com/apk/res/android"
                android:id="@+id/shopitem_text"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
index 7dda2ffcd79d22a3f49db94981d9b7de3750fb83..b75f31fcedd7c975984f3e870fcb0346e4ebf609 100644 (file)
                        android:orientation="vertical"
                        android:padding="@dimen/dialog_margin"
                        >
-                       <LinearLayout
+                       <TextView
+                               android:id="@+id/skillinfo_title"
                                android:layout_width="match_parent"
                                android:layout_height="wrap_content"
-                               android:orientation="horizontal"
-                               android:gravity="center_vertical"
-                               >
-                               <ImageView 
-                                       android:id="@+id/skillinfo_image"
-                                       android:layout_width="wrap_content"
-                                       android:layout_height="wrap_content"
-                                       android:src="@drawable/icon" 
-                                       android:paddingRight="@dimen/dialog_iconpadding_right"
-                                       android:paddingBottom="@dimen/dialog_iconpadding_bottom"
-                                       />
-                               <TextView
-                                       android:id="@+id/skillinfo_title"
-                                       android:layout_width="match_parent"
-                                       android:layout_height="wrap_content"
-                                       android:text="Skill" 
-                                       android:textSize="@dimen/titletext"
-                                       />
-                       </LinearLayout>
+                               android:text="@string/heroinfo_skill" 
+                               style="@style/titleWithIcon"
+                               android:drawableLeft="@drawable/ui_icon_skill"
+                               />
                
                        <TextView 
-                               android:text="Current level" 
+                               android:text="@string/skill_current_level" 
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_gravity="right"
@@ -50,7 +36,7 @@
                                />
                        
                        <TextView 
-                               android:text="Long description
+                               android:text="@string/skill_longdescription_weapon_chance
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:id="@+id/skillinfo_longdescription"
@@ -58,7 +44,7 @@
                                />
                        
                        <TextView 
-                               android:text="Next level requires
+                               android:text="@string/skill_prerequisite_other_skill
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:id="@+id/skillinfo_requirement"
index ba6178133a2a4960fbae3556883d500fbdaf54e6..43fa843a7631a5e8dc809561ca20c7a594d98efb 100644 (file)
@@ -11,7 +11,7 @@
         android:layout_marginRight="6dip"
         android:layout_alignParentLeft="true"
         android:layout_centerVertical="true"
-        android:src="@drawable/icon"
+        android:src="@drawable/ui_icon_skill"
                />
 
        <TextView
@@ -20,7 +20,7 @@
                android:layout_height="wrap_content"
                android:layout_toRightOf="@id/skillentry_icon"
         android:layout_alignParentTop="true"
-        android:text="Title"
+        android:text="@string/skill_title_weapon_chance"
                android:textSize="22dp"
                />
 
@@ -30,7 +30,7 @@
                android:layout_height="wrap_content"
                android:layout_toRightOf="@id/skillentry_icon"
         android:layout_below="@id/skillentry_title"
-        android:text="Description"
+        android:text="@string/skill_shortdescription_weapon_chance"
                />
 
 </RelativeLayout>
index a247907c522cf76a057745661c5f53847bbd4411..d9d5fcd485d99be155bb049bd68b64d1905699cd 100644 (file)
@@ -3,7 +3,9 @@
 <resources>
        <string name="conversationlist_mikhail">
 [id|message|rewards[rewardType|rewardID|value|]|replies[text|nextPhraseID|requires_Progress|requires_itemID|requires_Quantity|requires_Type|]|];
-{mikhail_start_select|||{{|mikhail_visited|andor:1||||}{|mikhail_gamestart|||||}}|};
+{mikhail_start_select|||{{|mikhail_start_select2|mikhail_bread:100||||}{|mikhail_bread_continue|mikhail_bread:10||||}{|mikhail_start_select2|||||}}|};
+{mikhail_start_select2|||{{|mikhail_start_select_default|mikhail_rats:100||||}{|mikhail_rats_continue|mikhail_rats:10||||}{|mikhail_start_select_default|||||}}|};
+{mikhail_start_select_default|||{{|mikhail_visited|andor:1||||}{|mikhail_gamestart|||||}}|};
 {mikhail_gamestart|Ah, parfait, tu es réveillé.||{{N|mikhail_visited|||||}}|};
 {mikhail_visited|Je ne trouve nulle part ton frère Andor. Il n\'est pas rentré depuis son départ d\'hier.|{{0|andor|1|}}|{{N|mikhail3|||||}}|};
 {mikhail3|Cela n\'est pas grave, il sera probablement bientôt de retour.||{{N|mikhail_default|||||}}|};
@@ -20,7 +22,7 @@
 {mikhail_rats_start|J\'ai vu quelques rats dans le jardin tout à l\'heure. Pourrais-tu nous débarasser de tous ceux que tu trouves ?|{{0|mikhail_rats|10|}}|{{Je me suis déjà occupé des rats.|mikhail_rats_complete||tail_trainingrat|2|0|}{D\'accord, je vais aller voir au jardin.|mikhail_rats_start2|||||}}|};
 {mikhail_rats_start2|Si les rats te blessent, reviens ici et repose toi dans le lit. Tu pourras ainsi recouvrer toutes tes forces.||{{N|mikhail_rats_start3|||||}}|};
 {mikhail_rats_start3|Au fait n\'oublie pas de faire l\'inventaire de ton équipement. Tu as probablement toujours le vieil anneau que je t\'avais donné. N\'oublie pas de le porter.||{{Très bien, je comprends. Je peux me reposer ici si je suis blessé, et je dois vérifier mon inventaire pour tous les objets utiles que je peux avoir.|mikhail_default|||||}}|};
-{mikhail_rats_continue|As-tu tué les deux rats du jardin ?||{{Oui, je m\'en suis occupé.|mikhail_rats_complete||tail_trainingrat|2|0|}{Non, pas encore.|mikhail_default|||||}}|};
+{mikhail_rats_continue|As-tu tué les deux rats du jardin ?||{{Oui, je m\'en suis occupé.|mikhail_rats_complete||tail_trainingrat|2|0|}{Non, pas encore.|mikhail_rats_start2|||||}}|};
 {mikhail_rats_complete|Ah tu l\'as fait ? Bravo, merci pour ton aide !\n\nSi tu es blessé, reviens à ton lit ici pour te reposer et reprendre des forces.|{{0|mikhail_rats|100|}}|{{N|mikhail_default|||||}}|};
 {mikhail_rats_complete2|Merci de m\'avoir débarassé des rats tout à l\'heure.\n\nSi tu es blessé, reviens à ton lit ici pour te reposer et reprendre des forces.||{{N|mikhail_default|||||}}|};
        </string>
index 66aa7c97d0c4772d0a18e6877589d4f17f7ce648..9868fe30156b4707b68d3ddbf720098dd45a597f 100644 (file)
@@ -3,7 +3,9 @@
 <resources>
        <string name="conversationlist_mikhail">
 [id|message|rewards[rewardType|rewardID|value|]|replies[text|nextPhraseID|requires_Progress|requires_itemID|requires_Quantity|requires_Type|]|];
-{mikhail_start_select|||{{|mikhail_visited|andor:1||||}{|mikhail_gamestart|||||}}|};
+{mikhail_start_select|||{{|mikhail_start_select2|mikhail_bread:100||||}{|mikhail_bread_continue|mikhail_bread:10||||}{|mikhail_start_select2|||||}}|};
+{mikhail_start_select2|||{{|mikhail_start_select_default|mikhail_rats:100||||}{|mikhail_rats_continue|mikhail_rats:10||||}{|mikhail_start_select_default|||||}}|};
+{mikhail_start_select_default|||{{|mikhail_visited|andor:1||||}{|mikhail_gamestart|||||}}|};
 {mikhail_gamestart|Oh, bene, Siete sveglio.||{{N|mikhail_visited|||||}}|};
 {mikhail_visited|Non riesco a trovare tuo fratello da nessuna parte. Da quando ieri è uscito non è più tornato.|{{0|andor|1|}}|{{N|mikhail3|||||}}|};
 {mikhail3|Non preoccuparti, sarà sicuramente di ritorno presto.||{{N|mikhail_default|||||}}|};
@@ -20,7 +22,7 @@
 {mikhail_rats_start|Ho visto di nuovo dei topi fuori, nel giardino. Puoi andare in giardino a controllare? Se puoi uccidi tutti i topi che trovi.|{{0|mikhail_rats|10|}}|{{Fatto|mikhail_rats_complete||tail_trainingrat|2|0|}{Certo|mikhail_rats_start2|||||}}|};
 {mikhail_rats_start2|Se con i topi ti facessi male, puoi tornare qua nel tuo letto. Questo ti fa recuperare le forze.||{{N|mikhail_rats_start3|||||}}|};
 {mikhail_rats_start3|Non dimenticare di controllare nel tuo inventario. Sicuramente hai ancora quel\'anello che ti ho dato. Assicurati di indossarlo.||{{Ok|mikhail_default|||||}}|};
-{mikhail_rats_continue|Hai ucciso quei ratti nel nostro giardino?||{{Si|mikhail_rats_complete||tail_trainingrat|2|0|}{Non ancora|mikhail_default|||||}}|};
+{mikhail_rats_continue|Hai ucciso quei ratti nel nostro giardino?||{{Si|mikhail_rats_complete||tail_trainingrat|2|0|}{Non ancora|mikhail_rats_start2|||||}}|};
 {mikhail_rats_complete|Oh, l\'hai fatto?! Se ti sei ferito, usa il tuo letto per riposare. Questo è un modo per recuperare le forze.|{{0|mikhail_rats|100|}}|{{N|mikhail_default|||||}}|};
 {mikhail_rats_complete2|Grazie per il tuo aiuto con i topi. Se sei ferito, usa il letto per riposare. In questo modo potrai recuperare le forze.||{{N|mikhail_default|||||}}|};
        </string>
index df88d10146f6e419e146e71049defc1286a676a7..c8613db465900b426b2eda4c623ea0dc933f990f 100644 (file)
     <string name="traitsinfo_defense_chance">Possibilità difesa:</string>
     <string name="traitsinfo_defense_damageresist">Resistenza ai danni:</string>
    
-        <string name="key_required">E\' richiesta una chiave specifica per passare.</string>
-
         <string name="iteminfo_category">Categoria: </string>
         <string name="iteminfo_action_use">Usa</string>
         <string name="iteminfo_action_equip">Indossa</string>
index 9177940b5037accfd84bfa9d3b777cbfc88a0a8f..c42c6fc23572b096cf339f6664facf98c176078c 100644 (file)
@@ -3,7 +3,9 @@
 <resources>
        <string name="conversationlist_mikhail">
 [id|message|rewards[rewardType|rewardID|value|]|replies[text|nextPhraseID|requires_Progress|requires_itemID|requires_Quantity|requires_Type|]|];
-{mikhail_start_select|||{{|mikhail_visited|andor:1||||}{|mikhail_gamestart|||||}}|};
+{mikhail_start_select|||{{|mikhail_start_select2|mikhail_bread:100||||}{|mikhail_bread_continue|mikhail_bread:10||||}{|mikhail_start_select2|||||}}|};
+{mikhail_start_select2|||{{|mikhail_start_select_default|mikhail_rats:100||||}{|mikhail_rats_continue|mikhail_rats:10||||}{|mikhail_start_select_default|||||}}|};
+{mikhail_start_select_default|||{{|mikhail_visited|andor:1||||}{|mikhail_gamestart|||||}}|};
 {mikhail_gamestart|Отлично, ты проснулся.||{{N|mikhail_visited|||||}}|};
 {mikhail_visited|Я нигде не могу найти твоего брата. Он не вернулся, с тех пор как ушел вчера.|{{0|andor|1|}}|{{N|mikhail3|||||}}|};
 {mikhail3|Неважно, он, наверное, скоро вернется.||{{N|mikhail_default|||||}}|};
@@ -20,7 +22,7 @@
 {mikhail_rats_start|Я видел несколько крыс в огороде. Не мог бы ты поискать их? Пожалуйста, убей всех крыс, которых увидишь.|{{0|mikhail_rats|10|}}|{{Готово|mikhail_rats_complete||tail_trainingrat|2|0|}{Конечно|mikhail_rats_start2|||||}}|};
 {mikhail_rats_start2|Если пострадаешь от крыс, то возвращайся и отдохни в кровати. Это поможет восстановить силы.||{{N|mikhail_rats_start3|||||}}|};
 {mikhail_rats_start3|Так же не забудь проверить свой инвентарь. У тебя, наверное, еще сохранилось кольцо, которое я тебе подарил. Убедись что надел его.||{{Хорошо|mikhail_default|||||}}|};
-{mikhail_rats_continue|Ты убил крыс в огороде?||{{Да|mikhail_rats_complete||tail_trainingrat|2|0|}{Еще нет|mikhail_default|||||}}|};
+{mikhail_rats_continue|Ты убил крыс в огороде?||{{Да|mikhail_rats_complete||tail_trainingrat|2|0|}{Еще нет|mikhail_rats_start2|||||}}|};
 {mikhail_rats_complete|Вау, Спасибо за твою помощь!\n\nЕсли устал, используй кровать для отдыха. Это поможет восстановить твои силы.|{{0|mikhail_rats|100|}}|{{N|mikhail_default|||||}}|};
 {mikhail_rats_complete2|Спасибо, еще раз, за помощь с крысами.\n\nЕсли устал, используй кровать для отдыха. Это поможет восстановить твои силы.||{{N|mikhail_default|||||}}|};
        </string>
index e98a500054cbc8f96ac5057bfa960e527949520c..e829ef1631f11d1299b2a9ba7c53535933989958 100644 (file)
@@ -3,7 +3,9 @@
 <resources>
        <string name="conversationlist_mikhail">
 [id|message|rewards[rewardType|rewardID|value|]|replies[text|nextPhraseID|requires_Progress|requires_itemID|requires_Quantity|requires_Type|]|];
-{mikhail_start_select|||{{|mikhail_visited|andor:1||||}{|mikhail_gamestart|||||}}|};
+{mikhail_start_select|||{{|mikhail_start_select2|mikhail_bread:100||||}{|mikhail_bread_continue|mikhail_bread:10||||}{|mikhail_start_select2|||||}}|};
+{mikhail_start_select2|||{{|mikhail_start_select_default|mikhail_rats:100||||}{|mikhail_rats_continue|mikhail_rats:10||||}{|mikhail_start_select_default|||||}}|};
+{mikhail_start_select_default|||{{|mikhail_visited|andor:1||||}{|mikhail_gamestart|||||}}|};
 {mikhail_gamestart|Oh good, you are awake.||{{N|mikhail_visited|||||}}|};
 {mikhail_visited|I can\'t seem to find your brother Andor anywhere. He hasn\'t been back since he left yesterday.|{{0|andor|1|}}|{{N|mikhail3|||||}}|};
 {mikhail3|Never mind, he will probably be back soon.||{{N|mikhail_default|||||}}|};
@@ -20,7 +22,7 @@
 {mikhail_rats_start|I saw some rats out back in our garden earlier. Could you please go kill any rats that you see out there.|{{0|mikhail_rats|10|}}|{{I have already dealt with the rats.|mikhail_rats_complete||tail_trainingrat|2|0|}{Ok, I\'ll go check out in our garden.|mikhail_rats_start2|||||}}|};
 {mikhail_rats_start2|If you get hurt by the rats, come back here and rest in your bed. That way you can regain your strength.||{{N|mikhail_rats_start3|||||}}|};
 {mikhail_rats_start3|Also, don\'t forget to check your inventory. You probably still have that old ring I gave you. Make sure you wear it.||{{Ok, I understand. I can rest here if I get hurt, and I should check my inventory for useful items.|mikhail_default|||||}}|};
-{mikhail_rats_continue|Did you kill those two rats in our garden?||{{Yes, I have dealt with the rats now.|mikhail_rats_complete||tail_trainingrat|2|0|}{No, not yet.|mikhail_default|||||}}|};
+{mikhail_rats_continue|Did you kill those two rats in our garden?||{{Yes, I have dealt with the rats now.|mikhail_rats_complete||tail_trainingrat|2|0|}{No, not yet.|mikhail_rats_start2|||||}}|};
 {mikhail_rats_complete|Oh you did? Wow, thanks a lot for your help!\n\nIf you are hurt, use your bed over there to rest and regain your strength.|{{0|mikhail_rats|100|}}|{{N|mikhail_default|||||}}|};
 {mikhail_rats_complete2|Thanks for your help with the rats earlier.\n\nIf you are hurt, use your bed over there to rest and regain your strength.||{{N|mikhail_default|||||}}|};
        </string>
        {Ok, I will leave you to your investigation.|X|||||}
        {How about you allow me to enter town anyway, so that I can trade. I promise to be quick.|remgardb_7|||||}
        }|};
-{remgardb_7|No. As I said, no one excepts us guards are allowed to enter or exit town until our investigation is completed. I suggest you leave now.|||};
+{remgardb_7|No. As I said, no one except us guards are allowed to enter or exit town until our investigation is completed. I suggest you leave now.|||};
 {remgardb_help_1|Hm, yes, that might be a good idea actually. Considering you made it up here, you must have some knowledge of the surroundings.|{{0|remgard|15|}}|{{N|remgardb_help_2|||||}}|};
 {remgardb_help_2|Tell you what. You might be able to help us.||{{N|remgardb_help_2b|||||}}|};
 {remgardb_help_2b|There is an abandoned house some way to the east of here, on a peninsula on the northern shore of lake Laeroth.||{{N|remgardb_help_3|||||}}|};
        {How come these creatures do not attack you?|ulirfendor_10|||||}
        {What have you translated from the shrine so far?|ulirfendor_12|||||}
        }|};
-{ulirfendor_10|I have placed a blessing of the Shadow upon this small island here, so that I may work uninterrupted. Strangely enough, it seems to be very effective on them. They seem to be undead wards of Ah, the Allaceph. I had not seen one for many years until I entered this cave. They are a remnant of the guardians of Kazaul.||{{N|ulirfendor_11|||||}}|};
+{ulirfendor_10|I have placed a blessing of the Shadow upon this small island here, so that I may work uninterrupted. Strangely enough, it seems to be very effective on them.||{{N|ulirfendor_11|||||}}|};
 {ulirfendor_11|They seem to be very cautious about it. So far, not even one has dared to approach me. Even those pesky lizards are keeping their distance.||{
        {What are these creatures?|ulirfendor_8|||||}
        {What have you translated from the shrine so far?|ulirfendor_12|||||}
        {I\'m interested in the Shadow guardian blessing|talion_bless_guard_1|||||}
        {Never mind.|talion_0|||||}
        }|};
-{talion_bless_str_1|The blessing of Shadow strength grants you more strength while attacking, thus increasing the amount of damage you do on each hit. I can give you the blessing for 250 gold.||{
+{talion_bless_str_1|The blessing of Shadow strength grants you more strength while attacking, thus increasing the amount of damage you do on each hit. I can give you the blessing for 300 gold.||{
        {Ok, I\'ll take it for 300 gold.|talion_bless_str_2||gold|300|0|}
        {Never mind, let\'s go back to those other blessings.|talion_bless_1|||||}
        }|};
        {Anything else?|ingus_t3|||||}
        {Thank you, goodbye.|X|||||}
        }|};
-{ingus_t3|Well, there\'s always the Elwille sisters, fighting as always.||{{N|ingus_t2|||||}}|};
+{ingus_t3|Well, there\'s always the Elwille sisters, fighting as always.||{{N|ingus_t4|||||}}|};
 {ingus_t4|Last night, they must have kept the whole town awake, they way they were shouting at each other.||{{What are they fighting about?|ingus_t5|||||}}|};
 {ingus_t5|Oh .. nothing .. everything. I don\'t know. No one really puts much weight in their squabbling.||{{N|ingus_t6|||||}}|};
 {ingus_t6|They live in one of the cabins on the southern shore. *Ingus points to the southwest*.|{{0|sisterfight|10|}}|{
        {Thank you. Goodbye.|X|||||}
        {Thank you. I wanted to ask you, is there a shop in town?|ingus_s1|||||}
        }|};
-{ingus_s1|Shop? Oh yes, of course. There\'s Rothses\' and Arnal\'s shops right there. *Ingus points to the two nearby houses to the west*||{{N|ingus_t6|||||}}|};
+{ingus_s1|Shop? Oh yes, of course. There\'s Rothses\' and Arnal\'s shops right there. *Ingus points to the two nearby houses to the west*||{{N|ingus_s2|||||}}|};
 {ingus_s2|Also, if you have the coin, you can always spend it in the tavern down in town.||{
        {Thank you. What is happening around town?|ingus_2|||||}
        {Thank you, goodbye.|X|||||}
        }|};
        </string>
-
+       
 </resources>
index 554ad5d1c29f8117f2cd0c2985640c988cefe3fe..c6c1753f37520243ee165d989a547561452e5e24 100644 (file)
 {shop_thorin|{{pot_scaradon|30|30|100|}}|};
 {thorin_bone|{{thorin_bone|1|1|100|}}|};
 {lonelyhouse_sp|{{algangror_rat|1|1|100|}}|};
+{irdegh_spawn|{
+       {gold|1|4|70|}
+       {meat|1|1|1|}
+       {gland|1|1|1|}
+}|};
+{irdegh|{
+       {gold|1|4|70|}
+       {meat|1|1|5|}
+       {gland|1|1|1|}
+       {irdegh|1|1|5|}
+}|};
+{irdegh_b|{
+       {gold|1|20|70|}
+       {meat|1|1|5|}
+       {gland|1|1|1|}
+       {irdegh|1|1|5|}
+       {ring_crude_combat|1|1|1|}
+}|};
 </string>
 
 <string name="droplists_v0611_questitems">
index adb2c5f60c4e712fa3a91df6f96f5a757e0c9071..3797037acc3bd966e1956f89b357ebc0e4e5307e 100644 (file)
 {oegyth|items_misc:35|Oegyth crystal|31|1|1|0|||||||||||||||||||||||||||||||||};
 {toszylae_heart|items_misc:6|Demon heart|31|1|1|0|||||||||||||||||||||||||||||||||};
 {potion_rotworm|items_consumables:63|Kazaul rotworm|31|1|1|0|||||||||||||||||||||||||||||||||};
+{lyson_marrow|items_consumables:63|Vial of Lyson marrow extract|31|1|1|0|||||||||||||||||||||||||||||||||};
        </string>
 
 </resources>
index a3f0b11c1d07b85f65413408889e1d21c4612d45..60c58d318ea3b3c4297efbd211dbcae78fc4dda3 100644 (file)
        {50|Talion has cured me of the Kazaul rotworms. I managed to get one of the rotworms into an empty vial, and Talion told me that it would be very valuable. I cannot imagine for what.|3000||}
        {51|Because of my former affliction, Talion has agreed to help me by placing blessings of the Shadow upon me whenever I wish, for a fee.||1|}
        }|};
-{sisterfight|TODO|1|{
+{sisterfight|A difference in opinion|1|{
        {10|I heard a story about two squabbling sisters in Remgard, Elwel and Elwyl. Apparently they have kept people awake at night with the way they are shouting at each other. I should go visit them in their house on the southern shore of the city of Remgard.|||}
+       {20|I have talked to Elwyl, one of the Elwille sisters in Remgard. She is furious at her sister for not agreeing on even the most simple of facts. Apparently, they have had their disagreements with each other for several years.|||}
+       {21|Elwel will not speak to me.|||}
+       {30|One matter that the sisters disagree on currently is the color of a certain potion that the town potion-maker Hjaldar used to make. Elwyl says that the potion of accuracy focus that Hjaldar used to make was a blue potion, but Elwel insists that the potion had a green substance.|||}
+       {31|Elwyl wants me to get a potion of accuracy focus from Hjaldar here in Remgard so that she can finally prove to Elwel that she is wrong.|||}
+       {40|I have talked to Hjaldar in Remgard. Hjaldar no longer makes potions since his supply of Lyson marrow extract has gone dry.|||}
+       {41|Apparently, Hjaldar\'s old friend Mazeg would surely have some Lyson marrow extract to sell. Unfortunately, he does not know where Mazeg currently lives. He only knows that Mazeg traveled far to the west last time they met.|||}
+       {45|I should find Mazeg and get some Lyson marrow extract so that Hjaldar can start making potions again.|||}
+       {50|I have talked to Mazeg in the Blackwater mountain settlement. He is willing to sell me Lyson marrow extract for 600 gold.|||}
+       {51|I have talked to Mazeg in the Blackwater mountain settlement. Since I helped the people of the Blackwater mountain before, he is willing to sell me a vial of Lyson marrow extract for only 400 gold.|||}
+       {55|I have bought some Lyson marrow extract from Mazeg. I should return to Remgard and give it to Hjaldar.|||}
+       {60|Hjaldar thanked me for bringing him the marrow extract.|1500||}
+       {61|Hjaldar can now create potions again, and is willing to trade with me. He even gave me some of the first potions that he made. I should go visit the Elwille sisters here in Remgard again, and show them a potion of accuracy focus.|||}
+       {70|I have shown Elwyl a potion of accuracy focus. Unfortunately, it did not cause their squabbling to diminish. On the contrary, they seem to be even more angry at each other now, since both of them had the color wrong.|900|1|}
        }|};
 </string>
 
index 5eaba9b60a5539fc741d040cd7dfffe01d04d51e..6a08ae7de392fc7099d3c283945605cc05c70fe1 100644 (file)
     </array>
     
        <string name="conversationlist_debug">
-[id|message|progressQuest|rewardDropListID|replies[text|nextPhraseID|requires_Progress|requires_itemID|requires_Quantity|]|];
-{debugshop|Welcome adventurer!|||{{Trade items very very long text|S||||}{Bye|X||||}{Fight|F||||}}|};
-{debugquest|Debug quest start\nTest.|debugquest:10||{{Iron sword*2|debugquest2||dagger0|1|}{Progress+=10|debugquest4||||}{Progress=100|debugquest1|debugquest:100|||}}|};
-{debugquest1|Yes, you have already completed this quest.||debuglist1|{{Next|debugquest3||||}}|};
-{debugquest2|Thank you for the items.|debugquest:100||{{Next|debugquest3||||}}|};
-{debugquest3|Quest is now completed.|||{{Bye|X||||}}|};
-{debugquest4|More info. Quest progress should now be updated to 20.|debugquest:20||{{Back|debugquest||||}}|};
-{debugsign|This should be a signpost.||||};
-{debugrequireskey|This tile requires a questprogress.||||};
+[id|message|rewards[rewardType|rewardID|value|]|replies[text|nextPhraseID|requires_Progress|requires_itemID|requires_Quantity|requires_Type|]|];
+{debugshop|Welcome adventurer!||{{Trade items very very long text|S|||||}{Bye|X|||||}{Fight|F|||||}}|};
+{debugquest|Debug quest start\nTest.|{{0|debugquest|10|}}|{{Iron sword*2|debugquest2||dagger0|1|0|}{Progress+=10|debugquest4|||||}{Progress=100|debugquest1|debugquest:100||||}}|};
+{debugquest1|Yes, you have already completed this quest.|{{1|debuglist1||}}|{{Next|debugquest3|||||}}|};
+{debugquest2|Thank you for the items.|{{0|debugquest|100|}}|{{Next|debugquest3|||||}}|};
+{debugquest3|Quest is now completed.||{{Bye|X|||||}}|};
+{debugquest4|More info. Quest progress should now be updated to 20.|{{0|debugquest|20|}}|{{Back|debugquest|||||}}|};
+{debugsign|This should be a signpost.|||};
+{debugrequireskey|This tile requires a questprogress.|||};
        </string>
 
 
     </array>
     
        <string name="monsterlist_debug">
-[id|iconID|name|tags|size|maxHP|maxAP|moveCost|attackCost|attackChance|criticalChance|criticalMultiplier|attackDamage_Min|attackDamage_Max|blockChance|damageResistance|droplistID|phraseID|hasHitEffect|onHit_boostHP_Min|onHit_boostHP_Max|onHit_boostAP_Min|onHit_boostAP_Max|onHit_conditionsSource[condition|magnitude|duration|chance|]|onHit_conditionsTarget[condition|magnitude|duration|chance|]|];
-{traveller1|monsters_man1:0|Traveller1|debugNPC1||10|10|10|10|50|||1|2|||debugshop1|debugshop||||||||};
-{traveller2|monsters_man1:0|Traveller2|debugNPC2||10|10|10|10|50|||1|2|||debugshop1|debugquest||||||||};
-{black_ant|monsters_insects:0|Ant|insect||10|10|10|10|50|||1|2|||debuglist1|||||||||};
-{small_wasp|monsters_insects:1|Pitiful debug bug with long name|insect||10|10|10|10|50|||1|2|||debuglist1|||||||||};
-{winged_demon|monsters_demon1:0|Winged demon|demon|2x2|10|10|10|10|50|||10|20|||debuglist1|||||||||};
-{troll|monsters_misc:5|Troll|troll||10|10|10|2|50|||1|2|||debuglist1|||||||||};
+[id|iconID|name|tags|size|monsterClass|unique|faction|maxHP|maxAP|moveCost|attackCost|attackChance|criticalChance|criticalMultiplier|attackDamage_Min|attackDamage_Max|blockChance|damageResistance|droplistID|phraseID|hasHitEffect|onHit_boostHP_Min|onHit_boostHP_Max|onHit_boostAP_Min|onHit_boostAP_Max|onHit_conditionsSource[condition|magnitude|duration|chance|]|onHit_conditionsTarget[condition|magnitude|duration|chance|]|];
+{traveller1|monsters_man1:0|Traveller1|debugNPC1||0|1||10|10|10|10|50|||1|2|||debugshop1|debugshop||||||||};
+{traveller2|monsters_man1:0|Traveller2|debugNPC2||0|1||10|10|10|10|50|||1|2|||debugshop1|debugquest||||||||};
+{black_ant|monsters_insects:0|Ant|insect||1|||10|10|10|10|50|||1|2|||debuglist1|||||||||};
+{small_wasp|monsters_insects:1|Pitiful debug bug with long name|insect||1|||10|10|10|10|50|||1|2|||debuglist1|||||||||};
+{winged_demon|monsters_demon1:0|Winged demon|demon|2x2|2|||10|10|10|10|50|||10|20|||debuglist1|||||||||};
+{troll|monsters_misc:5|Troll|troll||5|||10|10|10|2|50|||1|2|||debuglist1|||||||||};
        </string>
 
 
index edf1234883cc8ac6950fdc02e9ee4b7d02ba1161..dde13fef1cdf2eade9b359ac54610b219f4cbf28 100644 (file)
@@ -1,6 +1,25 @@
 <?xml version="1.0" encoding="utf-8"?>
 <resources>
-    <style name="Theme.NoBackground" parent="android:Theme">
-        <item name="android:windowBackground">@null</item>
+       <style name="Theme.NoBackground" parent="android:Theme">
+               <item name="android:windowBackground">@null</item>
+       </style>
+       
+       <style name="textWithIcon" parent="android:Widget.TextView">
+               <item name="android:drawablePadding">@dimen/dialog_iconpadding_right</item>
+               <item name="android:gravity">center_vertical</item>
+       </style>
+       
+       <style name="titleWithIcon" parent="@style/textWithIcon">
+               <item name="android:textSize">@dimen/titletext</item>
+               <item name="android:paddingBottom">@dimen/dialog_iconpadding_bottom</item>
+       </style>
+       
+    <style name="statsBoxStyle" parent="android:Widget.TextView">
+        <item name="android:background">@drawable/ui_boxshape</item>
+        <item name="android:drawablePadding">@dimen/boxshape_margin</item>
+        <item name="android:gravity">center_vertical</item>
+        <item name="android:layout_margin">@dimen/boxshape_margin</item>
+        <item name="android:padding">@dimen/boxshape_margin</item>
+        <item name="android:textSize">@dimen/smalltext</item>
     </style>
 </resources>
\ No newline at end of file
index c07e1488e86a1c7183371ff890e90e375e9c8266..7874fb0d8278549a397707a3d8f0323094202668 100644 (file)
@@ -17,7 +17,7 @@ public final class VisualEffectCollection {
        public final VisualEffect[] effects = new VisualEffect[NUM_EFFECTS];
        
        public void initialize(DynamicTileLoader loader) {
-               effects[EFFECT_BLOOD] = createEffect(loader, R.drawable.effect_blood3, new ConstRange(16, 0), 400, Color.RED);
+               effects[EFFECT_BLOOD] = createEffect(loader, R.drawable.effect_blood4, new ConstRange(14, 0), 400, Color.RED);
                effects[EFFECT_RESTORE_HP] = createEffect(loader, R.drawable.effect_heal2, new ConstRange(16, 0), 400, Color.rgb(150, 150, 255));
                effects[EFFECT_POISON] = createEffect(loader, R.drawable.effect_poison1, new ConstRange(16, 0), 400, Color.GREEN);
        }
index 8534013e5608e4778897568292239b2272eb7b8f..9309319ddc9abfaa008a05f975d993969de74201 100644 (file)
@@ -7,7 +7,6 @@ import android.view.View;
 import android.view.Window;
 import android.view.View.OnClickListener;
 import android.widget.Button;
-import android.widget.ImageView;
 import android.widget.LinearLayout;
 import android.widget.TextView;
 
@@ -33,12 +32,11 @@ public class ActorConditionInfoActivity extends Activity {
         
         setContentView(R.layout.actorconditioninfo);
 
-        ImageView img = (ImageView) findViewById(R.id.actorconditioninfo_image);
-        world.tileManager.setImageViewTile(img, conditionType);
         
         TextView tv = (TextView) findViewById(R.id.actorconditioninfo_title);
         tv.setText(conditionType.name);
-
+        world.tileManager.setImageViewTile(tv, conditionType);
+        
         Button b = (Button) findViewById(R.id.actorconditioninfo_close);
         b.setOnClickListener(new OnClickListener() {
                        @Override
index d390f925807a74e5646fe28ce15e5bc9623786ab..a92156e9f87c55cc6e6563c9e34fa0def937a1fe 100644 (file)
@@ -15,7 +15,6 @@ import android.view.View;
 import android.view.View.OnTouchListener;
 import android.widget.Button;
 import android.widget.EditText;
-import android.widget.ImageView;
 import android.widget.SeekBar;
 import android.widget.TextView;
 
@@ -103,11 +102,10 @@ public class BulkSelectionInterface extends Activity implements TextWatcher {
                final Button selectAllButton = (Button)findViewById(R.id.bulkselection_select_all_button);
 
                // change image and name of the item
-               final ImageView itemImage = (ImageView)findViewById(R.id.bulkselection_itemimage);
-        world.tileManager.setImageViewTileForSingleItemType(itemImage, itemType, getResources());
-        final TextView itemName = (TextView)findViewById(R.id.bulkselection_itemname);
+               final TextView itemName = (TextView)findViewById(R.id.bulkselection_itemname);
         itemName.setText(itemType.name);
-
+        world.tileManager.setImageViewTileForSingleItemType(itemName, itemType, getResources());
+        
         int actionTextResourceID = 0;
                if (interfaceType == BULK_INTERFACE_BUY) {
                pricePerUnit = ItemController.getBuyingPrice(world.model.player, itemType);
index 7a0d6b07bdf92133b816ba8279228a76ed824ca8..5480797d9a08b1c079e188dd1b1ac1436df44105 100644 (file)
@@ -398,18 +398,16 @@ public final class ConversationActivity extends Activity implements OnKeyListene
                                result = View.inflate(getContext(), R.layout.conversation_statement, null);
                        }
                        
-                       final ImageView iv = (ImageView) result.findViewById(R.id.conversation_image);
                        final TextView tv = (TextView) result.findViewById(R.id.conversation_text);
                if (statement.hasActor()) {
-                       if (statement.isPlayerActor) tileManager.setImageViewTileForPlayer(iv, statement.iconID);
-                       else tileManager.setImageViewTileForMonster(iv, statement.iconID);
-                               iv.setVisibility(View.VISIBLE);
+                       if (statement.isPlayerActor) tileManager.setImageViewTileForPlayer(tv, statement.iconID);
+                       else tileManager.setImageViewTileForMonster(tv, statement.iconID);
                                
                        tv.setText(statement.actorName + ": " + statement.text, BufferType.SPANNABLE);
                        Spannable sp = (Spannable) tv.getText();
                        sp.setSpan(new ForegroundColorSpan(statement.color), 0, statement.actorName.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
                } else {
-                       iv.setVisibility(View.GONE);
+                       tv.setCompoundDrawables(null, null, null, null);
                        tv.setText(statement.text);
                    }
                        
index bc831c202f498ba5203a021f5e99521f262c80a1..03ff00baaeb4c5aa654d88f88a987e3ea90ba28c 100644 (file)
@@ -12,6 +12,7 @@ import com.gpl.rpg.AndorsTrail.R;
 import com.gpl.rpg.AndorsTrail.context.ViewContext;
 import com.gpl.rpg.AndorsTrail.context.WorldContext;
 
+@SuppressWarnings("unused")
 public final class DebugInterface {
        private final ViewContext viewContext;
        private final MainActivity mainActivity;
@@ -175,7 +176,7 @@ public final class DebugInterface {
                }
     }
     
-    private void addDebugButton(DebugButton button, int id, RelativeLayout layout) {
+       private void addDebugButton(DebugButton button, int id, RelativeLayout layout) {
        if (!AndorsTrailApplication.DEVELOPMENT_DEBUGBUTTONS) return;
        
        RelativeLayout.LayoutParams lp = new RelativeLayout.LayoutParams(RelativeLayout.LayoutParams.WRAP_CONTENT, res.getDimensionPixelSize(R.dimen.smalltext_buttonheight));
@@ -193,7 +194,7 @@ public final class DebugInterface {
         layout.addView(b);
     }
     
-    private void addDebugButtons(DebugButton[] buttons) {
+       private void addDebugButtons(DebugButton[] buttons) {
        if (!AndorsTrailApplication.DEVELOPMENT_DEBUGBUTTONS) return;
        
        if (buttons == null || buttons.length <= 0) return;
index 84634e2b2fc4f8330d8b3029c23a04fbd979ee2f..72e6a9c11e0ae9200c41e63d5e83dabc7daf8cf5 100644 (file)
@@ -22,7 +22,6 @@ import android.os.Bundle;
 import android.view.View;
 import android.view.View.OnClickListener;
 import android.widget.Button;
-import android.widget.ImageView;
 import android.widget.TextView;
 
 public final class HeroinfoActivity_Stats extends Activity {
@@ -53,10 +52,9 @@ public final class HeroinfoActivity_Stats extends Activity {
         
         setContentView(R.layout.heroinfo_stats);
         
-        ImageView iv = (ImageView) findViewById(R.id.heroinfo_image);
-        world.tileManager.setImageViewTile(iv, player);
-        
-        ((TextView) findViewById(R.id.heroinfo_title)).setText(player.actorTraits.name);
+        TextView tv = (TextView) findViewById(R.id.heroinfo_title);
+        tv.setText(player.actorTraits.name);
+        world.tileManager.setImageViewTile(tv, player);
         heroinfo_ap = (TextView) findViewById(R.id.heroinfo_ap);
         heroinfo_movecost = (TextView) findViewById(R.id.heroinfo_movecost);
         heroinfo_currenttraits = (TraitsInfoView) findViewById(R.id.heroinfo_currenttraits);
index c8b7696b17ea793646db3083b52b4228c94fc8d0..96ab20168bda25fbcaaa6696e0d4fb168a824b56 100644 (file)
@@ -9,7 +9,6 @@ import android.os.Bundle;
 import android.view.View;
 import android.view.View.OnClickListener;
 import android.widget.Button;
-import android.widget.ImageView;
 import android.widget.TextView;
 
 import com.gpl.rpg.AndorsTrail.AndorsTrailApplication;
@@ -48,10 +47,9 @@ public final class ItemInfoActivity extends Activity {
         
         setContentView(R.layout.iteminfo);
 
-        ImageView img = (ImageView) findViewById(R.id.iteminfo_image);
-        world.tileManager.setImageViewTileForSingleItemType(img, itemType, getResources());
         TextView tv = (TextView) findViewById(R.id.iteminfo_title);
         tv.setText(itemType.name);
+        world.tileManager.setImageViewTileForSingleItemType(tv, itemType, getResources());
         tv = (TextView) findViewById(R.id.iteminfo_category);
         tv.setText(getCategoryNameRes(itemType.category));
         
index 5f2093f561dc90f568b6f6af57e2de55cb4a5433..c988a90c16207b6d7cece81c0490fe4b595af068 100644 (file)
@@ -21,8 +21,8 @@ import com.gpl.rpg.AndorsTrail.model.actor.Player;
 public final class LevelUpActivity extends Activity {
        private WorldContext world;
        private Player player;
-       private ImageView levelup_image;
        private TextView levelup_description;
+       private TextView levelup_title;
        private View levelup_adds_new_skillpoint;
        
     /** Called when the activity is first created. */
@@ -38,8 +38,8 @@ public final class LevelUpActivity extends Activity {
         
         setContentView(R.layout.levelup);
        
-       levelup_image = (ImageView) findViewById(R.id.levelup_image);
-        levelup_description = (TextView) findViewById(R.id.levelup_description);
+        levelup_title = (TextView) findViewById(R.id.levelup_title);
+       levelup_description = (TextView) findViewById(R.id.levelup_description);
         levelup_adds_new_skillpoint = findViewById(R.id.levelup_adds_new_skillpoint);
 
         Button b;
@@ -91,7 +91,7 @@ public final class LevelUpActivity extends Activity {
                return;
        }
        
-       world.tileManager.setImageViewTile(levelup_image, player);
+       world.tileManager.setImageViewTile(levelup_title, player);
         levelup_description.setText(res.getString(R.string.levelup_description, player.level+1));
         if (player.nextLevelAddsNewSkillpoint()) {
                levelup_adds_new_skillpoint.setVisibility(View.VISIBLE);
index 2f8114f6a6dee4b616a59e4f4829e216ecc18651..f099185fb3686a1c18572d58e308d92a1152db6e 100644 (file)
@@ -13,7 +13,6 @@ import android.view.View.OnClickListener;
 import android.view.ViewGroup;\r
 import android.view.ViewGroup.LayoutParams;\r
 import android.widget.Button;\r
-import android.widget.ImageView;\r
 import android.widget.TextView;\r
 \r
 import com.gpl.rpg.AndorsTrail.AndorsTrailApplication;\r
@@ -42,13 +41,12 @@ public final class LoadSaveActivity extends Activity implements OnClickListener
                 \r
         setContentView(R.layout.loadsave);\r
        \r
-        ImageView img = (ImageView) findViewById(R.id.loadsave_image);\r
         TextView tv = (TextView) findViewById(R.id.loadsave_title);\r
         if (isLoading) {\r
-               img.setImageResource(android.R.drawable.ic_menu_search);\r
+               tv.setCompoundDrawablesWithIntrinsicBounds(android.R.drawable.ic_menu_search, 0, 0, 0);\r
                tv.setText(R.string.loadsave_title_load);\r
         } else {\r
-               img.setImageResource(android.R.drawable.ic_menu_save);\r
+               tv.setCompoundDrawablesWithIntrinsicBounds(android.R.drawable.ic_menu_save, 0, 0, 0);\r
                tv.setText(R.string.loadsave_title_save);\r
         }\r
         \r
index e033052b1db31d8db74091f78d96fb234a5da142..f97ec8c45aa4fca66678fcd141f10c0891a723b0 100644 (file)
@@ -6,7 +6,6 @@ import android.view.View;
 import android.view.Window;
 import android.view.View.OnClickListener;
 import android.widget.Button;
-import android.widget.ImageView;
 import android.widget.TextView;
 
 import com.gpl.rpg.AndorsTrail.Dialogs;
@@ -39,13 +38,11 @@ public final class MonsterEncounterActivity extends Activity {
 
         TextView tv = (TextView) findViewById(R.id.monsterencounter_title);
         tv.setText(monster.actorTraits.name);
+        world.tileManager.setImageViewTile(tv, monster);
         
         tv = (TextView) findViewById(R.id.monsterencounter_description);
         tv.setText(getString(R.string.dialog_monsterencounter_message, difficulty));
 
-        ImageView iw = (ImageView) findViewById(R.id.monsterencounter_image);
-        world.tileManager.setImageViewTile(iw, monster);
-        
         Button b = (Button) findViewById(R.id.monsterencounter_attack);
         b.setOnClickListener(new OnClickListener() {
                        @Override
index c6030e2a97234522edb31d516485a6eba2585ab0..18fac949c76f392df4257d899ae8235f6d723c43 100644 (file)
@@ -24,7 +24,6 @@ import android.widget.TextView;
 \r
 public final class MonsterInfoActivity extends Activity {\r
        \r
-       private ImageView monsterinfo_image;\r
        private TextView monsterinfo_title;\r
        private TextView monsterinfo_difficulty;\r
        private TraitsInfoView monsterinfo_currenttraits;\r
@@ -45,7 +44,6 @@ public final class MonsterInfoActivity extends Activity {
         \r
         setContentView(R.layout.monsterinfo);\r
 \r
-        monsterinfo_image = (ImageView) findViewById(R.id.monsterinfo_image);\r
         monsterinfo_title = (TextView) findViewById(R.id.monsterinfo_title);\r
         monsterinfo_difficulty = (TextView) findViewById(R.id.monsterinfo_difficulty);\r
         monsterinfo_immune_criticals = (TextView) findViewById(R.id.monsterinfo_immune_criticals);\r
@@ -82,8 +80,8 @@ public final class MonsterInfoActivity extends Activity {
     }\r
 \r
        private void updateTitle(Monster monster) {\r
-               world.tileManager.setImageViewTile(monsterinfo_image, monster);\r
-        monsterinfo_title.setText(monster.actorTraits.name);\r
+               monsterinfo_title.setText(monster.actorTraits.name);\r
+               world.tileManager.setImageViewTile(monsterinfo_title, monster);\r
         monsterinfo_difficulty.setText(getMonsterDifficultyResource(world, monster));\r
        }\r
 \r
index 8f76812e0de25962391a995d93fc99a7aa2be0f0..ac40ac24a3b7e1df9e33e210e6055b103e7d2704 100644 (file)
@@ -20,7 +20,6 @@ import android.view.ViewGroup;
 import android.view.View.OnClickListener;
 import android.view.ViewGroup.LayoutParams;
 import android.widget.Button;
-import android.widget.ImageView;
 import android.widget.TextView;
 
 public final class SkillInfoActivity extends Activity {
@@ -44,9 +43,6 @@ public final class SkillInfoActivity extends Activity {
         final int skillID = intent.getExtras().getInt("skillID");
         SkillInfo skill = world.skills.getSkill(skillID);
         
-        ImageView skillinfo_image = (ImageView) findViewById(R.id.skillinfo_image);
-        SkillController.setSkillIcon(skillinfo_image, skillID, res);
-        
         TextView skillinfo_title = (TextView) findViewById(R.id.skillinfo_title);
         skillinfo_title.setText(getSkillTitleResourceID(skillID));
         
index ab12a0941416e795c9faa35024aa7fc9df3d9dab..1c1e3468c4fdd477432e09e263e3af826acb5958 100644 (file)
@@ -5,6 +5,7 @@ import java.util.HashSet;
 import android.content.res.Resources;
 import android.os.Handler;
 import android.os.Message;
+import android.util.FloatMath;
 import android.view.View;
 
 import com.gpl.rpg.AndorsTrail.AndorsTrailPreferences;
@@ -436,7 +437,7 @@ public final class CombatController implements VisualEffectCompletedCallback {
                
                float averageDamagePerTurn = getAverageDamagePerTurn(attacker, target);
                if (averageDamagePerTurn <= 0) return 100;
-               return (int) Math.ceil(target.actorTraits.maxHP / averageDamagePerTurn);
+               return (int) FloatMath.ceil(target.actorTraits.maxHP / averageDamagePerTurn);
        }
        public static int getMonsterDifficulty(WorldContext world, Monster monster) {
                // returns [0..100) . 100 == easy.
index 04c9940b9bee4f78f993159370b82ce77b5b5aa5..73f3b33929eda5c4ba46ad647778e76a2289f869 100644 (file)
@@ -1,9 +1,5 @@
 package com.gpl.rpg.AndorsTrail.controller;
 
-import android.content.res.Resources;
-import android.widget.ImageView;
-
-import com.gpl.rpg.AndorsTrail.R;
 import com.gpl.rpg.AndorsTrail.model.CombatTraits;
 import com.gpl.rpg.AndorsTrail.model.ability.ActorConditionEffect;
 import com.gpl.rpg.AndorsTrail.model.ability.ActorConditionType;
@@ -82,10 +78,6 @@ public final class SkillController {
                return true;
        }
        
-       public static void setSkillIcon(ImageView iconImageView, int skillID, Resources res) {
-               iconImageView.setImageResource(R.drawable.ui_icon_skill);
-       }
-
        public static int getActorConditionEffectChanceRollBias(ActorConditionEffect effect, Player player) {
                if (effect.chance.isMax()) return 0;
                
index b7e2b7f1c0f202be2bc9b1aac5728deea00a3f4c..f384a28a1aa863add0cd9989ef5dcb8e88837148 100644 (file)
@@ -4,6 +4,8 @@ import java.io.DataInputStream;
 import java.io.DataOutputStream;
 import java.io.IOException;
 
+import android.util.FloatMath;
+
 import com.gpl.rpg.AndorsTrail.util.Range;
 
 public class CombatTraits {
@@ -84,7 +86,7 @@ public class CombatTraits {
                case STAT_COMBAT_ATTACK_COST: return attackCost;
                case STAT_COMBAT_ATTACK_CHANCE: return attackChance;
                case STAT_COMBAT_CRITICAL_CHANCE: return criticalChance;
-               case STAT_COMBAT_CRITICAL_MULTIPLIER: return (int) Math.floor(criticalMultiplier);
+               case STAT_COMBAT_CRITICAL_MULTIPLIER: return (int) FloatMath.floor(criticalMultiplier);
                case STAT_COMBAT_DAMAGE_POTENTIAL_MIN: return damagePotential.current;
                case STAT_COMBAT_DAMAGE_POTENTIAL_MAX: return damagePotential.max;
                case STAT_COMBAT_BLOCK_CHANCE: return blockChance;
index e81e06cce557b4ff7ba43825c382e09ffe892102..2272ef75f581fced1a30421936b43f9ebdc470a5 100644 (file)
@@ -1,7 +1,9 @@
 package com.gpl.rpg.AndorsTrail.model.ability;\r
 \r
+import java.util.ArrayList;\r
 import java.util.Collection;\r
-import java.util.HashMap;\r
+\r
+import android.util.SparseArray;\r
 \r
 import com.gpl.rpg.AndorsTrail.controller.Constants;\r
 import com.gpl.rpg.AndorsTrail.model.CombatTraits;\r
@@ -66,7 +68,7 @@ public final class SkillCollection {
        public static final int MAX_LEVEL_LOWER_EXPLOSS = 100 / PER_SKILLPOINT_INCREASE_EXPLOSS_PERCENT;\r
        public static final int MAX_LEVEL_RESISTANCE = 70 / PER_SKILLPOINT_INCREASE_RESISTANCE_CHANCE_PERCENT;\r
        \r
-       private final HashMap<Integer, SkillInfo> skills = new HashMap<Integer, SkillInfo>();\r
+       private final SparseArray<SkillInfo> skills = new SparseArray<SkillInfo>();\r
        private void initializeSkill(SkillInfo skill) {\r
                skills.put(skill.id, skill);\r
        }\r
@@ -116,6 +118,8 @@ public final class SkillCollection {
        }\r
        \r
        public Collection<SkillInfo> getAllSkills() {\r
-               return skills.values();\r
+               ArrayList<SkillInfo> result = new ArrayList<SkillInfo>(skills.size());\r
+               for(int i = 0; i < skills.size(); ++i) result.add(skills.valueAt(i));\r
+               return result;\r
        }\r
 }\r
index 71ac72866687d6b63e3b827b3a842bb7ca21f2b7..7a8449344b55e95e77d9e49761da9f6cec4cc3f4 100644 (file)
@@ -7,6 +7,9 @@ import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Map.Entry;
 
+import android.util.FloatMath;
+import android.util.SparseIntArray;
+
 import com.gpl.rpg.AndorsTrail.AndorsTrailApplication;
 import com.gpl.rpg.AndorsTrail.context.WorldContext;
 import com.gpl.rpg.AndorsTrail.controller.ActorStatsController;
@@ -33,7 +36,7 @@ public final class Player extends Actor {
        private final HashMap<String, HashSet<Integer> > questProgress = new HashMap<String, HashSet<Integer> >();
        public int useItemCost;
        public int reequipCost;
-       private final HashMap<Integer, Integer> skillLevels = new HashMap<Integer, Integer>();
+       private final SparseIntArray skillLevels = new SparseIntArray();
        public String spawnMap;
        public String spawnPlace;
        public int availableSkillIncreases = 0;
@@ -132,8 +135,7 @@ public final class Player extends Actor {
        }
        
        public int getSkillLevel(int skillID) {
-               if (!skillLevels.containsKey(skillID)) return 0;
-               else return skillLevels.get(skillID);
+               return skillLevels.get(skillID);
        }
        public boolean hasSkill(int skillID) {
                return getSkillLevel(skillID) > 0;
@@ -143,8 +145,7 @@ public final class Player extends Actor {
                        if (!hasAvailableSkillpoints()) return;
                        --availableSkillIncreases;
                }
-               if (!skillLevels.containsKey(skillID)) skillLevels.put(skillID, 1);
-               else skillLevels.put(skillID, skillLevels.get(skillID) + 1);
+               skillLevels.put(skillID, skillLevels.get(skillID) + 1);
                ActorStatsController.recalculatePlayerCombatTraits(this);
        }
        public boolean nextLevelAddsNewSkillpoint() {
@@ -156,7 +157,7 @@ public final class Player extends Actor {
        public static int getExpectedNumberOfSkillpointsForLevel(int level) {
                level -= Constants.FIRST_SKILL_POINT_IS_GIVEN_AT_LEVEL;
                if (level < 0) return 0;
-               return 1 + (int) Math.floor((float) level / Constants.NEW_SKILL_POINT_EVERY_N_LEVELS);
+               return 1 + (int) FloatMath.floor((float) level / Constants.NEW_SKILL_POINT_EVERY_N_LEVELS);
        }
        public boolean hasAvailableSkillpoints() {
                return availableSkillIncreases > 0;
@@ -266,7 +267,7 @@ public final class Player extends Actor {
                
                if (fileversion <= 21) {
                        int assignedSkillpoints = 0;
-                       for (int v : skillLevels.values()) assignedSkillpoints += v;
+                       for (int i = 0; i < skillLevels.size(); ++i) assignedSkillpoints += skillLevels.valueAt(i);
                        this.availableSkillIncreases = getExpectedNumberOfSkillpointsForLevel(this.level) - assignedSkillpoints;
                } else {
                        this.availableSkillIncreases = src.readInt();
@@ -297,9 +298,9 @@ public final class Player extends Actor {
                dest.writeInt(useItemCost);
                dest.writeInt(reequipCost);
                dest.writeInt(skillLevels.size());
-               for (Entry<Integer, Integer> skillLevel: skillLevels.entrySet()) {
-                       dest.writeInt(skillLevel.getKey());
-                       dest.writeInt(skillLevel.getValue());
+               for (int i = 0; i < skillLevels.size(); ++i) {
+                       dest.writeInt(skillLevels.keyAt(i));
+                       dest.writeInt(skillLevels.valueAt(i));
                }
                dest.writeUTF(spawnMap);
                dest.writeUTF(spawnPlace);
index 6f8e3d61e2c6a459647f65ab2f8a4c2a892bb4e0..c5d72ec7f2b47ec4b597da609e1e512927af2079 100644 (file)
@@ -152,23 +152,26 @@ public final class PredefinedMap {
        return true;
        }
        
-       public void spawnAll(WorldContext context) {
+       public void spawnAll(WorldContext world) {
                boolean respawnUniqueMonsters = false;
                if (!visited) respawnUniqueMonsters = true;
                for (MonsterSpawnArea a : spawnAreas) {
-                       while (a.isSpawnable(respawnUniqueMonsters)) {
-                               final boolean wasAbleToSpawn = spawnInArea(a, context, null);
-                               if (!wasAbleToSpawn) break;
-                       }
-                       a.healAllMonsters();
+                       spawnAllInArea(world, a, respawnUniqueMonsters);
+               }
+       }
+       public void spawnAllInArea(WorldContext world, MonsterSpawnArea area, boolean respawnUniqueMonsters) {
+               while (area.isSpawnable(respawnUniqueMonsters)) {
+                       final boolean wasAbleToSpawn = spawnInArea(area, world, null);
+                       if (!wasAbleToSpawn) break;
                }
+               area.healAllMonsters();
        }
-       public boolean maybeSpawn(WorldContext context) {
+       public boolean maybeSpawn(WorldContext world) {
                boolean hasSpawned = false;
                for (MonsterSpawnArea a : spawnAreas) {
                        if (!a.isSpawnable(false)) continue;
                        if (!a.rollShouldSpawn()) continue;
-                       if (spawnInArea(a, context, context.model.player.position)) hasSpawned = true;
+                       if (spawnInArea(a, world, world.model.player.position)) hasSpawned = true;
                }
                return hasSpawned;
        }
@@ -254,9 +257,11 @@ public final class PredefinedMap {
                        this.spawnAreas[i].readFromParcel(src, world, fileversion);
                }
                
-               if (fileversion <= 5) return;
+               if (fileversion < 26) spawnPreV0611UniqueMonsters(world);
                
                groundBags.clear();
+               if (fileversion <= 5) return;
+               
                final int size2 = src.readInt();
                for(int i = 0; i < size2; ++i) {
                        groundBags.add(new Loot(src, world, fileversion));
@@ -275,7 +280,7 @@ public final class PredefinedMap {
                }
                lastVisitTime = src.readLong();
        }
-       
+
        public void writeToParcel(DataOutputStream dest, int flags) throws IOException {
                dest.writeInt(spawnAreas.length);
                for(MonsterSpawnArea a : spawnAreas) {
@@ -288,4 +293,51 @@ public final class PredefinedMap {
                dest.writeBoolean(visited);
                dest.writeLong(lastVisitTime);
        }
+       
+       
+       private void spawnPreV0611UniqueMonsters(WorldContext world) {
+               // These monsters were not marked as unique in v0.6.10, and were therefore
+               // not persisted in the savegame files from older versions.
+               if (name.equals("crossglen")) {
+                       spawnPreV0611UniqueMonster(world, "farmer");
+                       spawnPreV0611UniqueMonster(world, "tired_farmer");
+                       spawnPreV0611UniqueMonster(world, "odair");
+                       spawnPreV0611UniqueMonster(world, "oromir");
+               } else if (name.equals("crossglen_hall")) {
+                       spawnPreV0611UniqueMonster(world, "leonid");
+                       spawnPreV0611UniqueMonster(world, "mara");
+                       spawnPreV0611UniqueMonster(world, "drunk");
+                       spawnPreV0611UniqueMonster(world, "arambold");
+                       spawnPreV0611UniqueMonster(world, "tharal");
+                       spawnPreV0611UniqueMonster(world, "gruil");
+               } else if (name.equals("wild3")) {
+                       spawnPreV0611UniqueMonster(world, "jan");
+               } else if (name.equals("fallhaven_nw")) {
+                       spawnPreV0611UniqueMonster(world, "bearded_citizen");
+                       spawnPreV0611UniqueMonster(world, "old_citizen");
+                       spawnPreV0611UniqueMonster(world, "tired_citizen");
+                       spawnPreV0611UniqueMonster(world, "old_man");
+                       spawnPreV0611UniqueMonster(world, "guard");
+                       spawnPreV0611UniqueMonster(world, "drunkard");
+                       spawnPreV0611UniqueMonster(world, "acolyte");
+               } else if (name.equals("fallhaven_sw")) {
+                       spawnPreV0611UniqueMonster(world, "citizen");
+                       spawnPreV0611UniqueMonster(world, "jakrar");
+               } else if (name.equals("foaming_flask")) {
+                       spawnPreV0611UniqueMonster(world, "foaming_flask_cook");
+                       spawnPreV0611UniqueMonster(world, "torilo");
+                       spawnPreV0611UniqueMonster(world, "feygard_patrol");
+                       spawnPreV0611UniqueMonster(world, "feygard_patrol_captain");
+                       spawnPreV0611UniqueMonster(world, "ambelie");
+               } else if (name.equals("gapfiller4")) {
+                       spawnPreV0611UniqueMonster(world, "guard");
+               }
+       }
+
+       private void spawnPreV0611UniqueMonster(WorldContext world, String monsterTypeID) {
+               for (MonsterSpawnArea a : spawnAreas) {
+                       if (!a.monsterTypeIDs[0].equals(monsterTypeID)) continue;
+                       spawnAllInArea(world, a, true);
+               }
+       }
 }
index 02041cf21f010866140092ad40281659f68089a6..d58bd6b70c84d2786cba77623abdfd8c618a3a4e 100644 (file)
@@ -29,6 +29,6 @@ public final class Quest implements Comparable<Quest> {
 \r
        @Override\r
        public int compareTo(Quest q) {\r
-               return (new Integer(sortOrder)).compareTo(q.sortOrder);\r
+               return sortOrder - q.sortOrder;\r
        }\r
 }\r
index f360cf5860126317668571f2d01a9b90f960fe47..984ee3bcded6f183b3c3c78aae0c110e1d7d959f 100644 (file)
@@ -1,7 +1,9 @@
 package com.gpl.rpg.AndorsTrail.resource;
 
 import java.util.HashMap;
-import java.util.Map.Entry;
+
+import android.util.SparseArray;
+import android.util.SparseIntArray;
 
 import com.gpl.rpg.AndorsTrail.AndorsTrailApplication;
 import com.gpl.rpg.AndorsTrail.resource.tiles.ResourceFileTileset;
@@ -12,13 +14,13 @@ import com.gpl.rpg.AndorsTrail.util.Size;
 public final class DynamicTileLoader {
        private final TileCache tileCache;
        
-       private final HashMap<Integer, ResourceFileTilesetLoadList> preparedTilesetsByResourceId = new HashMap<Integer, ResourceFileTilesetLoadList>();
+       private final SparseArray<ResourceFileTilesetLoadList> preparedTilesetsByResourceId = new SparseArray<ResourceFileTilesetLoadList>();
        private final HashMap<String, ResourceFileTilesetLoadList> preparedTilesetsByResourceName = new HashMap<String, ResourceFileTilesetLoadList>();
        private int currentTileStoreIndex;
        
        private static final class ResourceFileTilesetLoadList {
                public final ResourceFileTileset tileset;
-               public final HashMap<Integer, Integer> tileIDsToLoadPerLocalID = new HashMap<Integer, Integer>();
+               public final SparseIntArray tileIDsToLoadPerLocalID = new SparseIntArray();
                public ResourceFileTilesetLoadList(ResourceFileTileset tileset) {
                        this.tileset = tileset;
                }
@@ -43,7 +45,7 @@ public final class DynamicTileLoader {
        }
        private ResourceFileTilesetLoadList getTilesetBitmap(int tilesetImageResourceID) {
                if (AndorsTrailApplication.DEVELOPMENT_VALIDATEDATA) {
-                       if (!preparedTilesetsByResourceId.containsKey(tilesetImageResourceID)) {
+                       if (preparedTilesetsByResourceId.get(tilesetImageResourceID) == null) {
                                L.log("WARNING: Cannot load tileset " + tilesetImageResourceID);
                                return null;
                        }
@@ -75,10 +77,8 @@ public final class DynamicTileLoader {
        }
        
        private int prepareTileID(ResourceFileTilesetLoadList tileset, int localID) {
-               int tileID = 0;
-               if (tileset.tileIDsToLoadPerLocalID.containsKey(localID)) {
-                       tileID = tileset.tileIDsToLoadPerLocalID.get(localID);
-               } else {
+               int tileID = tileset.tileIDsToLoadPerLocalID.get(localID);
+               if (tileID == 0) {
                        ++currentTileStoreIndex;
                        tileID = currentTileStoreIndex;
                        tileset.tileIDsToLoadPerLocalID.put(localID, tileID);
@@ -89,10 +89,12 @@ public final class DynamicTileLoader {
        
        public void flush() {
                tileCache.allocateMaxTileID(currentTileStoreIndex);     
-               for(Entry<Integer, ResourceFileTilesetLoadList> e : preparedTilesetsByResourceId.entrySet()) {
-                       ResourceFileTileset tileset = e.getValue().tileset;
-                       for(Entry<Integer, Integer> tile : e.getValue().tileIDsToLoadPerLocalID.entrySet()) {
-                               tileCache.setTile(tile.getValue(), tileset, tile.getKey());
+               for (int i = 0; i < preparedTilesetsByResourceId.size(); ++i) {
+                       ResourceFileTilesetLoadList e = preparedTilesetsByResourceId.valueAt(i);
+                       ResourceFileTileset tileset = e.tileset;
+                       SparseIntArray tileIDsToLoad = e.tileIDsToLoadPerLocalID;
+                       for (int j = 0; j < tileIDsToLoad.size(); ++j) {
+                               tileCache.setTile(tileIDsToLoad.valueAt(j), tileset, tileIDsToLoad.keyAt(j));
                        }
                }
        }
index db7a5bf10572bbea206300769e230341b7df7b87..b222f7563a77c7cde50ebd8852adf78db8f25d18 100644 (file)
@@ -245,7 +245,7 @@ public final class ResourceLoader {
         loader.prepareTileset(R.drawable.map_tiles_2_7, "map_tiles_2_7.png", src_mapTileSize, defaultTileSize);
         loader.prepareTileset(R.drawable.map_tiles_2_8, "map_tiles_2_8.png", src_mapTileSize7, defaultTileSize);
 
-        loader.prepareTileset(R.drawable.effect_blood3, "effect_blood3", new Size(8, 2), defaultTileSize);
+        loader.prepareTileset(R.drawable.effect_blood4, "effect_blood4", new Size(7, 2), defaultTileSize);
         loader.prepareTileset(R.drawable.effect_heal2, "effect_heal2", new Size(8, 2), defaultTileSize);
         loader.prepareTileset(R.drawable.effect_poison1, "effect_poison1", new Size(8, 2), defaultTileSize);
        }
index 50babbc89179a128dce10b1e493b4aa12f23cb1f..f9b29cd8345223321096a9c8bca48a79aa7389ec 100644 (file)
@@ -1,5 +1,7 @@
 package com.gpl.rpg.AndorsTrail.resource.parsers;
 
+import android.util.FloatMath;
+
 import com.gpl.rpg.AndorsTrail.controller.Constants;
 import com.gpl.rpg.AndorsTrail.model.CombatTraits;
 import com.gpl.rpg.AndorsTrail.model.ability.ActorConditionTypeCollection;
@@ -64,6 +66,6 @@ public final class MonsterTypeParser extends ResourceParserFor<MonsterType> {
                if (hitEffect != null && hitEffect.addedConditions_target != null && hitEffect.addedConditions_target.length > 0) {
                        attackConditionBonus += 50;
                }
-               return (int) Math.ceil((avgAttackHP * 3 + avgDefenseHP) * Constants.EXP_FACTOR_SCALING) + attackConditionBonus;
+               return (int) FloatMath.ceil((avgAttackHP * 3 + avgDefenseHP) * Constants.EXP_FACTOR_SCALING) + attackConditionBonus;
        }
 }
index 09a8fd463f20dfe70834d3dc3bee320955ac216e..a7dd230e26785cfe19f99fb61bfd7b2732674097 100644 (file)
@@ -13,12 +13,14 @@ import com.gpl.rpg.AndorsTrail.util.LruCache;
 
 import android.content.res.Resources;
 import android.graphics.Bitmap;
+import android.util.SparseArray;
+import android.util.SparseIntArray;
 
 public final class TileCache {
 
        private final ReferenceQueue<Bitmap> gcQueue = new ReferenceQueue<Bitmap>(); 
        private ResourceFileTile[] resourceTiles = new ResourceFileTile[1];
-       private final HashMap<String, HashMap<Integer, Integer>> tileIDsPerTilesetAndLocalID = new HashMap<String, HashMap<Integer,Integer>>();
+       private final HashMap<String, SparseIntArray> tileIDsPerTilesetAndLocalID = new HashMap<String, SparseIntArray>();
        private final LruCache<Integer, Bitmap> cache = new LruCache<Integer, Bitmap>(1000); 
        
        public int getMaxTileID() { return resourceTiles.length-1; }
@@ -31,9 +33,9 @@ public final class TileCache {
        }
        public void setTile(int tileID, ResourceFileTileset tileset, int localID) {
                if (resourceTiles[tileID] == null) resourceTiles[tileID] = new ResourceFileTile(tileset, localID);
-               HashMap<Integer, Integer> tileIDsPerLocalID = tileIDsPerTilesetAndLocalID.get(tileset.tilesetName);
+               SparseIntArray tileIDsPerLocalID = tileIDsPerTilesetAndLocalID.get(tileset.tilesetName);
                if (tileIDsPerLocalID == null) {
-                       tileIDsPerLocalID = new HashMap<Integer, Integer>();
+                       tileIDsPerLocalID = new SparseIntArray();
                        tileIDsPerTilesetAndLocalID.put(tileset.tilesetName, tileIDsPerLocalID);
                }
                tileIDsPerLocalID.put(localID, tileID);
@@ -65,12 +67,12 @@ public final class TileCache {
        public TileCollection loadTilesFor(Collection<Integer> iconIDs, Resources r, TileCollection result) {
                if (AndorsTrailApplication.DEVELOPMENT_DEBUGMESSAGES) L.log("TileCache::loadTilesFor({" + iconIDs.size() + " items})");
                int maxTileID = 0;
-               HashMap<ResourceFileTileset, HashMap<Integer, ResourceFileTile>> tilesToLoadPerSourceFile = new HashMap<ResourceFileTileset, HashMap<Integer, ResourceFileTile>>();
+               HashMap<ResourceFileTileset, SparseArray<ResourceFileTile>> tilesToLoadPerSourceFile = new HashMap<ResourceFileTileset, SparseArray<ResourceFileTile>>();
                for(int tileID : iconIDs) {
                        ResourceFileTile tile = resourceTiles[tileID];
-                       HashMap<Integer, ResourceFileTile> tiles = tilesToLoadPerSourceFile.get(tile.tileset);
+                       SparseArray<ResourceFileTile> tiles = tilesToLoadPerSourceFile.get(tile.tileset);
                        if (tiles == null) {
-                               tiles = new HashMap<Integer, TileCache.ResourceFileTile>();
+                               tiles = new SparseArray<TileCache.ResourceFileTile>();
                                tilesToLoadPerSourceFile.put(tile.tileset, tiles);
                        }
                        tiles.put(tileID, tile);
@@ -79,12 +81,13 @@ public final class TileCache {
                
                boolean hasLoadedTiles = false;
                if (result == null) result = new TileCollection(maxTileID);
-               for(Entry<ResourceFileTileset, HashMap<Integer, ResourceFileTile>> e : tilesToLoadPerSourceFile.entrySet()) {
+               for(Entry<ResourceFileTileset, SparseArray<ResourceFileTile>> e : tilesToLoadPerSourceFile.entrySet()) {
                        TileCutter cutter = null;
                        
-                       for(Entry<Integer, ResourceFileTile> j : e.getValue().entrySet()) {
-                               int tileID = j.getKey();
-                               ResourceFileTile tile = j.getValue();
+                       SparseArray<ResourceFileTile> tilesToLoad = e.getValue();
+                       for (int i = 0; i < tilesToLoad.size(); ++i) {
+                               int tileID = tilesToLoad.keyAt(i);
+                               ResourceFileTile tile = tilesToLoad.valueAt(i);
                                
                                Bitmap bitmap = cache.get(tileID);
                                
index d0c984bd2b5948c68e7e95627c852eece128e7ac..4d10a40b0b152db81005b6d794a5cad130d9ae69 100644 (file)
@@ -10,6 +10,7 @@ import android.graphics.drawable.Drawable;
 import android.graphics.drawable.LayerDrawable;
 import android.os.AsyncTask;
 import android.widget.ImageView;
+import android.widget.TextView;
 
 import com.gpl.rpg.AndorsTrail.AndorsTrailApplication;
 import com.gpl.rpg.AndorsTrail.AndorsTrailPreferences;
@@ -123,6 +124,36 @@ public final class TileManager {
        
        
        
+       public void setImageViewTile(TextView textView, Monster monster) { setImageViewTileForMonster(textView, monster.actorTraits.iconID); }
+       public void setImageViewTile(TextView textView, Player player) { setImageViewTileForPlayer(textView, player.actorTraits.iconID); }
+       public void setImageViewTileForMonster(TextView textView, int iconID) { setImageViewTile(textView, currentMapTiles.getBitmap(iconID)); }
+       public void setImageViewTileForPlayer(TextView textView, int iconID) { setImageViewTile(textView, preloadedTiles.getBitmap(iconID)); }
+       public void setImageViewTile(TextView textView, ActorConditionType conditionType) { setImageViewTile(textView, preloadedTiles.getBitmap(conditionType.iconID)); }
+       public void setImageViewTileForUIIcon(TextView textView, int iconID) { setImageViewTile(textView, preloadedTiles.getBitmap(iconID)); }
+       private void setImageViewTile(TextView textView, Bitmap b) { textView.setCompoundDrawablesWithIntrinsicBounds(new BitmapDrawable(b), null, null, null); }
+
+       public void setImageViewTileForSingleItemType(TextView textView, ItemType itemType, Resources r) {
+               final Bitmap icon = tileCache.loadSingleTile(itemType.iconID, r);
+               setImageViewTile(textView, itemType, icon);
+       }
+       public void setImageViewTile(TextView textView, ItemType itemType, TileCollection itemTileCollection) {
+               final Bitmap icon = itemTileCollection.getBitmap(itemType.iconID);
+               setImageViewTile(textView, itemType, icon);
+       }
+       private void setImageViewTile(TextView textView, ItemType itemType, Bitmap icon) {
+               final int overlayIconID = itemType.getOverlayTileID();
+               if (overlayIconID != -1) {
+                       textView.setCompoundDrawablesWithIntrinsicBounds(
+                               new LayerDrawable(new Drawable[] {
+                                       new BitmapDrawable(preloadedTiles.getBitmap(overlayIconID))
+                                       ,new BitmapDrawable(icon)
+                               }), null, null, null
+                       );
+               } else {
+                       setImageViewTile(textView, icon);
+               }
+       }
+       
        public void setImageViewTile(ImageView imageView, Monster monster) { setImageViewTileForMonster(imageView, monster.actorTraits.iconID); }
        public void setImageViewTile(ImageView imageView, Player player) { setImageViewTileForPlayer(imageView, player.actorTraits.iconID); }
        public void setImageViewTileForMonster(ImageView imageView, int iconID) { imageView.setImageBitmap(currentMapTiles.getBitmap(iconID)); }
index a2cb2761e701662aadb38c2cabecdc8a644ae240..9440e1cb96116f22a576077cab445574bf65214f 100644 (file)
@@ -1,5 +1,7 @@
 package com.gpl.rpg.AndorsTrail.util;
 
+import android.util.FloatMath;
+
 public final class ConstRange {
        public final int max;
        public final int current;
@@ -34,6 +36,6 @@ public final class ConstRange {
                return ((float) max + current) / 2f;
        }
        public String toPercentString() {
-               return Integer.toString((int) Math.ceil((float)current * 100 / max)) + "%";
+               return Integer.toString((int) FloatMath.ceil((float)current * 100 / max)) + "%";
        }
 }
index 8f5179d6960af7cb1c07a1f90a40ceac274486e3..2dffdee9f44c369acf4ace95df1afdd8bfa73652 100644 (file)
@@ -65,7 +65,6 @@ public final class SkillListAdapter extends ArrayAdapter<SkillInfo> {
                final TextView title = (TextView) result.findViewById(R.id.skillentry_title);
                final TextView description = (TextView) result.findViewById(R.id.skillentry_description);
                
-               SkillController.setSkillIcon(icon, skillID, r);
                String skillTitle = r.getString(SkillInfoActivity.getSkillTitleResourceID(skillID));
                final int skillLevel = player.getSkillLevel(skillID);
                if (skillLevel > 0) {