Added some neat die images

This commit is contained in:
2020-03-05 19:24:38 -05:00
parent d069108759
commit f3601f4694
9 changed files with 485 additions and 8 deletions

View File

@@ -16,8 +16,7 @@ class MainActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
binding = ActivityMainBinding.inflate(layoutInflater)
val view = binding.root
setContentView(view)
setContentView(R.layout.activity_main)
roll_button.setOnClickListener() {
rollDice()
@@ -25,8 +24,16 @@ class MainActivity : AppCompatActivity() {
}
private fun rollDice() {
val rollResult = Random().nextInt(DICE_SIDES + 1)
dice_result.text = rollResult.toString()
val rollResult = Random().nextInt(DICE_SIDES) + 1
dice_image.setImageResource(when(rollResult) {
1 -> R.drawable.dice_1
2 -> R.drawable.dice_2
3 -> R.drawable.dice_3
4 -> R.drawable.dice_4
5 -> R.drawable.dice_5
6 -> R.drawable.dice_6
else -> R.drawable.empty_dice
})
}
}

View File

@@ -0,0 +1,66 @@
<!--
~ Copyright 2018, The Android Open Source Project
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="200dp"
android:height="250dp"
android:viewportWidth="800"
android:viewportHeight="1000">
<path
android:fillAlpha="0.5"
android:fillColor="#eee"
android:pathData="M740.8,635.42c-68.27,90.47 -249.77,201.76 -316,240.63a50.7,50.7 0,0 1,-49.93 0.81c-64.19,-35 -234.09,-133.88 -315.65,-242a14.69,14.69 0,0 1,-0.12 -17.49c77.58,-106.29 159.67,-258.89 341.06,-258.89 182,0 242.19,139.08 340.27,258.88A14.62,14.62 0,0 1,740.8 635.42Z"
android:strokeAlpha="0.5" />
<path
android:fillColor="#bdbdbd"
android:pathData="M704.9,630l-294.29,191.06l0,-340.85l294.29,-191.06l0,340.85z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M97.59,630l294.29,191.06l0,-340.85l-294.29,-191.06l0,340.85z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-293.19,-191.45l293.19,-156.31l295.39,156.31l-295.39,191.45z" />
<path
android:fillColor="#eee"
android:pathData="M106.95,273.28l-9.36,15.87l294.29,191.06l8.26,-15.48l-293.19,-191.45z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M695.53,273.28l9.37,15.87l-294.29,191.06l-10.47,-15.48l295.39,-191.45z" />
<path
android:fillColor="#eee"
android:pathData="M391.88,480.21h18.73v340.85h-18.73z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-8.26,15.48l18.73,0l-10.47,-15.48z" />
<path
android:fillColor="#78c257"
android:pathData="M397.45,297.62a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M297.17,539.02a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M161.96,588.24a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M551.15,579.45a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
<path
android:fillColor="#78c257"
android:pathData="M469.12,549.58a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
<path
android:fillColor="#78c257"
android:pathData="M633.17,609.29a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
</vector>

View File

@@ -0,0 +1,66 @@
<!--
~ Copyright 2018, The Android Open Source Project
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="200dp"
android:height="250dp"
android:viewportWidth="800"
android:viewportHeight="1000">
<path
android:fillAlpha="0.5"
android:fillColor="#eee"
android:pathData="M740.8,635.42c-68.27,90.47 -249.77,201.76 -316,240.63a50.7,50.7 0,0 1,-49.93 0.81c-64.19,-35 -234.09,-133.88 -315.65,-242a14.69,14.69 0,0 1,-0.12 -17.49c77.58,-106.29 159.67,-258.89 341.06,-258.89 182,0 242.19,139.08 340.27,258.88A14.62,14.62 0,0 1,740.8 635.42Z"
android:strokeAlpha="0.5" />
<path
android:fillColor="#bdbdbd"
android:pathData="M704.9,630l-294.29,191.06l0,-340.85l294.29,-191.06l0,340.85z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M97.59,630l294.29,191.06l0,-340.85l-294.29,-191.06l0,340.85z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-293.19,-191.45l293.19,-156.31l295.39,156.31l-295.39,191.45z" />
<path
android:fillColor="#eee"
android:pathData="M106.95,273.28l-9.36,15.87l294.29,191.06l8.26,-15.48l-293.19,-191.45z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M695.53,273.28l9.37,15.87l-294.29,191.06l-10.47,-15.48l295.39,-191.45z" />
<path
android:fillColor="#eee"
android:pathData="M391.88,480.21h18.73v340.85h-18.73z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-8.26,15.48l18.73,0l-10.47,-15.48z" />
<path
android:fillColor="#78c257"
android:pathData="M520.85,303.25a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M273.33,291.99a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M229.56,563.64a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M311.58,533.77a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M147.54,593.49a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M551.15,579.45a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
</vector>

View File

@@ -0,0 +1,66 @@
<!--
~ Copyright 2018, The Android Open Source Project
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="200dp"
android:height="250dp"
android:viewportWidth="800"
android:viewportHeight="1000">
<path
android:fillAlpha="0.5"
android:fillColor="#eee"
android:pathData="M740.8,635.42c-68.27,90.47 -249.77,201.76 -316,240.63a50.7,50.7 0,0 1,-49.93 0.81c-64.19,-35 -234.09,-133.88 -315.65,-242a14.69,14.69 0,0 1,-0.12 -17.49c77.58,-106.29 159.67,-258.89 341.06,-258.89 182,0 242.19,139.08 340.27,258.88A14.62,14.62 0,0 1,740.8 635.42Z"
android:strokeAlpha="0.5" />
<path
android:fillColor="#bdbdbd"
android:pathData="M704.9,630l-294.29,191.06l0,-340.85l294.29,-191.06l0,340.85z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M97.59,630l294.29,191.06l0,-340.85l-294.29,-191.06l0,340.85z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-293.19,-191.45l293.19,-156.31l295.39,156.31l-295.39,191.45z" />
<path
android:fillColor="#eee"
android:pathData="M106.95,273.28l-9.36,15.87l294.29,191.06l8.26,-15.48l-293.19,-191.45z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M695.53,273.28l9.37,15.87l-294.29,191.06l-10.47,-15.48l295.39,-191.45z" />
<path
android:fillColor="#eee"
android:pathData="M391.88,480.21h18.73v340.85h-18.73z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-8.26,15.48l18.73,0l-10.47,-15.48z" />
<path
android:fillColor="#78c257"
android:pathData="M398.11,297.62a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M548.27,304.46a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M247.95,290.79a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M229.56,563.64a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M483.54,554.83a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
<path
android:fillColor="#78c257"
android:pathData="M618.75,604.04a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
</vector>

View File

@@ -0,0 +1,69 @@
<!--
~ Copyright 2018, The Android Open Source Project
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="200dp"
android:height="250dp"
android:viewportWidth="800"
android:viewportHeight="1000">
<path
android:fillAlpha="0.5"
android:fillColor="#eee"
android:pathData="M740.8,635.42c-68.27,90.47 -249.77,201.76 -316,240.63a50.7,50.7 0,0 1,-49.93 0.81c-64.19,-35 -234.09,-133.88 -315.65,-242a14.69,14.69 0,0 1,-0.12 -17.49c77.58,-106.29 159.67,-258.89 341.06,-258.89 182,0 242.19,139.08 340.27,258.88A14.62,14.62 0,0 1,740.8 635.42Z"
android:strokeAlpha="0.5" />
<path
android:fillColor="#bdbdbd"
android:pathData="M704.9,630l-294.29,191.06l0,-340.85l294.29,-191.06l0,340.85z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M97.59,630l294.29,191.06l0,-340.85l-294.29,-191.06l0,340.85z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-293.19,-191.45l293.19,-156.31l295.39,156.31l-295.39,191.45z" />
<path
android:fillColor="#eee"
android:pathData="M106.95,273.28l-9.36,15.87l294.29,191.06l8.26,-15.48l-293.19,-191.45z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M695.53,273.28l9.37,15.87l-294.29,191.06l-10.47,-15.48l295.39,-191.45z" />
<path
android:fillColor="#eee"
android:pathData="M391.88,480.21h18.73v340.85h-18.73z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-8.26,15.48l18.73,0l-10.47,-15.48z" />
<path
android:fillColor="#78c257"
android:pathData="M530.08,303.65a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M389.68,218.17a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M405.35,377.09a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M264.95,291.6a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M297.17,541.59a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M161.96,590.81a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M551.15,579.45a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
</vector>

View File

@@ -0,0 +1,75 @@
<!--
~ Copyright 2018, The Android Open Source Project
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="200dp"
android:height="250dp"
android:viewportWidth="800"
android:viewportHeight="1000">
<path
android:fillAlpha="0.5"
android:fillColor="#eee"
android:pathData="M740.8,635.42c-68.27,90.47 -249.77,201.76 -316,240.63a50.7,50.7 0,0 1,-49.93 0.81c-64.19,-35 -234.09,-133.88 -315.65,-242a14.69,14.69 0,0 1,-0.12 -17.49c77.58,-106.29 159.67,-258.89 341.06,-258.89 182,0 242.19,139.08 340.27,258.88A14.62,14.62 0,0 1,740.8 635.42Z"
android:strokeAlpha="0.5" />
<path
android:fillColor="#bdbdbd"
android:pathData="M704.9,630l-294.29,191.06l0,-340.85l294.29,-191.06l0,340.85z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M97.59,630l294.29,191.06l0,-340.85l-294.29,-191.06l0,340.85z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-293.19,-191.45l293.19,-156.31l295.39,156.31l-295.39,191.45z" />
<path
android:fillColor="#eee"
android:pathData="M106.95,273.28l-9.36,15.87l294.29,191.06l8.26,-15.48l-293.19,-191.45z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M695.53,273.28l9.37,15.87l-294.29,191.06l-10.47,-15.48l295.39,-191.45z" />
<path
android:fillColor="#eee"
android:pathData="M391.88,480.21h18.73v340.85h-18.73z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-8.26,15.48l18.73,0l-10.47,-15.48z" />
<path
android:fillColor="#78c257"
android:pathData="M397.05,297.63a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M547.21,304.45a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M388.17,207.62a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M405.93,387.62a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M246.89,290.79a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M229.56,563.64a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M551.15,579.45a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
<path
android:fillColor="#78c257"
android:pathData="M469.12,549.58a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
<path
android:fillColor="#78c257"
android:pathData="M633.17,609.29a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
</vector>

View File

@@ -0,0 +1,81 @@
<!--
~ Copyright 2018, The Android Open Source Project
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="200dp"
android:height="250dp"
android:viewportWidth="800"
android:viewportHeight="1000">
<path
android:fillAlpha="0.5"
android:fillColor="#eee"
android:pathData="M740.8,635.42c-68.27,90.47 -249.77,201.76 -316,240.63a50.7,50.7 0,0 1,-49.93 0.81c-64.19,-35 -234.09,-133.88 -315.65,-242a14.69,14.69 0,0 1,-0.12 -17.49c77.58,-106.29 159.67,-258.89 341.06,-258.89 182,0 242.19,139.08 340.27,258.88A14.62,14.62 0,0 1,740.8 635.42Z"
android:strokeAlpha="0.5" />
<path
android:fillColor="#bdbdbd"
android:pathData="M704.9,630l-294.29,191.06l0,-340.85l294.29,-191.06l0,340.85z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M97.59,630l294.29,191.06l0,-340.85l-294.29,-191.06l0,340.85z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-293.19,-191.45l293.19,-156.31l295.39,156.31l-295.39,191.45z" />
<path
android:fillColor="#eee"
android:pathData="M106.95,273.28l-9.36,15.87l294.29,191.06l8.26,-15.48l-293.19,-191.45z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M695.53,273.28l9.37,15.87l-294.29,191.06l-10.47,-15.48l295.39,-191.45z" />
<path
android:fillColor="#eee"
android:pathData="M391.88,480.21h18.73v340.85h-18.73z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-8.26,15.48l18.73,0l-10.47,-15.48z" />
<path
android:fillColor="#78c257"
android:pathData="M326.53,254.89a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M537.57,298.78a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M397.17,213.3a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M396.31,381.95a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M255.91,296.47a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M466.93,340.37a16.9,28.71 97.07,1 0,4.16 -33.54a16.9,28.71 97.07,1 0,-4.16 33.54z" />
<path
android:fillColor="#78c257"
android:pathData="M230,563.64a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M312.02,533.78a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M147.96,593.48a30.12,16.11 53.82,1 0,26.01 -19.02a30.12,16.11 53.82,1 0,-26.01 19.02z" />
<path
android:fillColor="#78c257"
android:pathData="M483.54,554.83a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
<path
android:fillColor="#78c257"
android:pathData="M618.75,604.04a30.12,16.11 126.18,1 0,35.56 -48.62a30.12,16.11 126.18,1 0,-35.56 48.62z" />
</vector>

View File

@@ -0,0 +1,48 @@
<!--
~ Copyright 2018, The Android Open Source Project
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="200dp"
android:height="250dp"
android:viewportWidth="800"
android:viewportHeight="1000">
<path
android:fillAlpha="0.5"
android:fillColor="#eee"
android:pathData="M740.8,635.42c-68.27,90.47 -249.77,201.76 -316,240.63a50.7,50.7 0,0 1,-49.93 0.81c-64.19,-35 -234.09,-133.88 -315.65,-242a14.69,14.69 0,0 1,-0.12 -17.49c77.58,-106.29 159.67,-258.89 341.06,-258.89 182,0 242.19,139.08 340.27,258.88A14.62,14.62 0,0 1,740.8 635.42Z"
android:strokeAlpha="0.5" />
<path
android:fillColor="#bdbdbd"
android:pathData="M704.9,630l-294.29,191.06l0,-340.85l294.29,-191.06l0,340.85z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M97.59,630l294.29,191.06l0,-340.85l-294.29,-191.06l0,340.85z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-293.19,-191.45l293.19,-156.31l295.39,156.31l-295.39,191.45z" />
<path
android:fillColor="#eee"
android:pathData="M106.95,273.28l-9.36,15.87l294.29,191.06l8.26,-15.48l-293.19,-191.45z" />
<path
android:fillColor="#e0e0e0"
android:pathData="M695.53,273.28l9.37,15.87l-294.29,191.06l-10.47,-15.48l295.39,-191.45z" />
<path
android:fillColor="#eee"
android:pathData="M391.88,480.21h18.73v340.85h-18.73z" />
<path
android:fillColor="#f5f5f5"
android:pathData="M400.14,464.73l-8.26,15.48l18.73,0l-10.47,-15.48z" />
</vector>

View File

@@ -7,13 +7,12 @@
android:layout_gravity="center_vertical"
tools:context=".MainActivity">
<TextView
android:id="@+id/dice_result"
<ImageView
android:id="@+id/dice_image"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:text="1"
android:textSize="30sp" />
android:src="@drawable/empty_dice" />
<Button
android:id="@+id/roll_button"