Fixed lots of Android lint warnings.

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
This commit is contained in:
oskar.wiksten
2012-03-24 11:28:14 +00:00
parent a985b6e29f
commit 02d5a2fac1
56 changed files with 533 additions and 627 deletions

View 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>

View 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>

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

View File

@@ -18,28 +18,14 @@
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"

View File

@@ -19,29 +19,15 @@
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"

View 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

View 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>
/>

View 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"

View File

@@ -1,141 +1,121 @@
<?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"
>
<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" >
<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"
>
<ScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1" >
<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="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"
/>
<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"
/>
</LinearLayout>
</ScrollView>
<TableLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/section_margin" >
<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"
<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>

View 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>

View File

@@ -17,28 +17,14 @@
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"

View File

@@ -12,33 +12,20 @@
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
@@ -66,28 +53,14 @@
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" />

View 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>

View File

@@ -11,33 +11,21 @@
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>

View File

@@ -17,39 +17,35 @@
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"
>
<ImageView
android:id="@+id/monsterinfo_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/monsterinfo_title"
android:layout_width="match_parent"
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>
<TextView
android:text="@string/actorinfo_difficulty"
android:layout_marginRight="10sp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
/>
<TextView
android:id="@+id/monsterinfo_difficulty"
android:text="@string/monster_difficulty_normal"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
/>
</LinearLayout>
<com.gpl.rpg.AndorsTrail.view.RangeBar
android:id="@+id/monsterinfo_healthbar"
@@ -106,7 +102,6 @@
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/dialog_close"
android:layout_alignParentRight="true"
/>
</LinearLayout>
</LinearLayout>

View 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"

View File

@@ -30,27 +30,15 @@
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"
@@ -71,27 +59,15 @@
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"

View 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"
@@ -14,17 +13,15 @@
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"

View File

@@ -17,31 +17,17 @@
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"

View 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>

View 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>

View 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>

View File

@@ -123,8 +123,6 @@
<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>

View 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>

View 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>
@@ -3329,7 +3331,7 @@
{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|||||}}|};
@@ -3409,7 +3411,7 @@
{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|||||}
@@ -3824,7 +3826,7 @@
{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|||||}
}|};
@@ -3880,7 +3882,7 @@
{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|}}|{
@@ -3888,11 +3890,11 @@
{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>

View File

@@ -622,6 +622,24 @@
{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">

View File

@@ -378,6 +378,7 @@
{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>

View File

@@ -400,8 +400,21 @@
{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>

View File

@@ -54,15 +54,15 @@
</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>
@@ -72,13 +72,13 @@
</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>

View 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>

View 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);
}

View 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

View 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);

View 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);
}

View 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;

View 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);

View 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));

View 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);

View File

@@ -13,7 +13,6 @@ import android.view.View.OnClickListener;
import android.view.ViewGroup;
import android.view.ViewGroup.LayoutParams;
import android.widget.Button;
import android.widget.ImageView;
import android.widget.TextView;
import com.gpl.rpg.AndorsTrail.AndorsTrailApplication;
@@ -42,13 +41,12 @@ public final class LoadSaveActivity extends Activity implements OnClickListener
setContentView(R.layout.loadsave);
ImageView img = (ImageView) findViewById(R.id.loadsave_image);
TextView tv = (TextView) findViewById(R.id.loadsave_title);
if (isLoading) {
img.setImageResource(android.R.drawable.ic_menu_search);
tv.setCompoundDrawablesWithIntrinsicBounds(android.R.drawable.ic_menu_search, 0, 0, 0);
tv.setText(R.string.loadsave_title_load);
} else {
img.setImageResource(android.R.drawable.ic_menu_save);
tv.setCompoundDrawablesWithIntrinsicBounds(android.R.drawable.ic_menu_save, 0, 0, 0);
tv.setText(R.string.loadsave_title_save);
}

View 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

View File

@@ -24,7 +24,6 @@ import android.widget.TextView;
public final class MonsterInfoActivity extends Activity {
private ImageView monsterinfo_image;
private TextView monsterinfo_title;
private TextView monsterinfo_difficulty;
private TraitsInfoView monsterinfo_currenttraits;
@@ -45,7 +44,6 @@ public final class MonsterInfoActivity extends Activity {
setContentView(R.layout.monsterinfo);
monsterinfo_image = (ImageView) findViewById(R.id.monsterinfo_image);
monsterinfo_title = (TextView) findViewById(R.id.monsterinfo_title);
monsterinfo_difficulty = (TextView) findViewById(R.id.monsterinfo_difficulty);
monsterinfo_immune_criticals = (TextView) findViewById(R.id.monsterinfo_immune_criticals);
@@ -82,8 +80,8 @@ public final class MonsterInfoActivity extends Activity {
}
private void updateTitle(Monster monster) {
world.tileManager.setImageViewTile(monsterinfo_image, monster);
monsterinfo_title.setText(monster.actorTraits.name);
monsterinfo_title.setText(monster.actorTraits.name);
world.tileManager.setImageViewTile(monsterinfo_title, monster);
monsterinfo_difficulty.setText(getMonsterDifficultyResource(world, monster));
}

View 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));

View 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.

View 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;

View 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;

View File

@@ -1,7 +1,9 @@
package com.gpl.rpg.AndorsTrail.model.ability;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashMap;
import android.util.SparseArray;
import com.gpl.rpg.AndorsTrail.controller.Constants;
import com.gpl.rpg.AndorsTrail.model.CombatTraits;
@@ -66,7 +68,7 @@ public final class SkillCollection {
public static final int MAX_LEVEL_LOWER_EXPLOSS = 100 / PER_SKILLPOINT_INCREASE_EXPLOSS_PERCENT;
public static final int MAX_LEVEL_RESISTANCE = 70 / PER_SKILLPOINT_INCREASE_RESISTANCE_CHANCE_PERCENT;
private final HashMap<Integer, SkillInfo> skills = new HashMap<Integer, SkillInfo>();
private final SparseArray<SkillInfo> skills = new SparseArray<SkillInfo>();
private void initializeSkill(SkillInfo skill) {
skills.put(skill.id, skill);
}
@@ -116,6 +118,8 @@ public final class SkillCollection {
}
public Collection<SkillInfo> getAllSkills() {
return skills.values();
ArrayList<SkillInfo> result = new ArrayList<SkillInfo>(skills.size());
for(int i = 0; i < skills.size(); ++i) result.add(skills.valueAt(i));
return result;
}
}

View 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);

View 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 boolean maybeSpawn(WorldContext context) {
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 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);
}
}
}

View File

@@ -29,6 +29,6 @@ public final class Quest implements Comparable<Quest> {
@Override
public int compareTo(Quest q) {
return (new Integer(sortOrder)).compareTo(q.sortOrder);
return sortOrder - q.sortOrder;
}
}

View 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));
}
}
}

View 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);
}

View 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;
}
}

View 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);

View 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)); }

View 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)) + "%";
}
}

View 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) {