Commit 06ad0ac6 authored by Isa's avatar Isa

HUD Design-Update

parent af1096a5
fileFormatVersion: 2
guid: f7ec8ad896f47904cb7499a6425f0c4c
TextureImporter:
fileIDToRecycleName: {}
externalObjects: {}
serializedVersion: 9
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: -1
aniso: -1
mipBias: -100
wrapU: 1
wrapV: 1
wrapW: -1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 1
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 8
textureShape: 1
singleChannelComponent: 0
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
platformSettings:
- serializedVersion: 2
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
- serializedVersion: 2
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID:
vertices: []
indices:
edges: []
weights: []
spritePackingTag:
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:
Assets/_Game/Graphics/Sprite/HUD/Luft_1.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/Luft_1.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/Luft_1.png
Assets/_Game/Graphics/Sprite/HUD/Luft_1.png
Assets/_Game/Graphics/Sprite/HUD/Luft_1.png
Assets/_Game/Graphics/Sprite/HUD/Luft_1.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/Luft_2.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/Luft_2.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/Luft_2.png
Assets/_Game/Graphics/Sprite/HUD/Luft_2.png
Assets/_Game/Graphics/Sprite/HUD/Luft_2.png
Assets/_Game/Graphics/Sprite/HUD/Luft_2.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/Luft_3.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/Luft_3.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/Luft_3.png
Assets/_Game/Graphics/Sprite/HUD/Luft_3.png
Assets/_Game/Graphics/Sprite/HUD/Luft_3.png
Assets/_Game/Graphics/Sprite/HUD/Luft_3.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/Luft_4.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/Luft_4.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/Luft_4.png
Assets/_Game/Graphics/Sprite/HUD/Luft_4.png
Assets/_Game/Graphics/Sprite/HUD/Luft_4.png
Assets/_Game/Graphics/Sprite/HUD/Luft_4.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/Luft_5.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/Luft_5.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/Luft_5.png
Assets/_Game/Graphics/Sprite/HUD/Luft_5.png
Assets/_Game/Graphics/Sprite/HUD/Luft_5.png
Assets/_Game/Graphics/Sprite/HUD/Luft_5.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/erde_1.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/erde_1.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/erde_1.png
Assets/_Game/Graphics/Sprite/HUD/erde_1.png
Assets/_Game/Graphics/Sprite/HUD/erde_1.png
Assets/_Game/Graphics/Sprite/HUD/erde_1.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/erde_2.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/erde_2.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/erde_2.png
Assets/_Game/Graphics/Sprite/HUD/erde_2.png
Assets/_Game/Graphics/Sprite/HUD/erde_2.png
Assets/_Game/Graphics/Sprite/HUD/erde_2.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/erde_3.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/erde_3.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/erde_3.png
Assets/_Game/Graphics/Sprite/HUD/erde_3.png
Assets/_Game/Graphics/Sprite/HUD/erde_3.png
Assets/_Game/Graphics/Sprite/HUD/erde_3.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/erde_4.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/erde_4.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/erde_4.png
Assets/_Game/Graphics/Sprite/HUD/erde_4.png
Assets/_Game/Graphics/Sprite/HUD/erde_4.png
Assets/_Game/Graphics/Sprite/HUD/erde_4.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/erde_5.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/erde_5.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/erde_5.png
Assets/_Game/Graphics/Sprite/HUD/erde_5.png
Assets/_Game/Graphics/Sprite/HUD/erde_5.png
Assets/_Game/Graphics/Sprite/HUD/erde_5.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/fire_1.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/fire_1.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/fire_1.png
Assets/_Game/Graphics/Sprite/HUD/fire_1.png
Assets/_Game/Graphics/Sprite/HUD/fire_1.png
Assets/_Game/Graphics/Sprite/HUD/fire_1.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/fire_2.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/fire_2.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/fire_2.png
Assets/_Game/Graphics/Sprite/HUD/fire_2.png
Assets/_Game/Graphics/Sprite/HUD/fire_2.png
Assets/_Game/Graphics/Sprite/HUD/fire_2.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/fire_3.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/fire_3.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/fire_3.png
Assets/_Game/Graphics/Sprite/HUD/fire_3.png
Assets/_Game/Graphics/Sprite/HUD/fire_3.png
Assets/_Game/Graphics/Sprite/HUD/fire_3.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/fire_4.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/fire_4.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/fire_4.png
Assets/_Game/Graphics/Sprite/HUD/fire_4.png
Assets/_Game/Graphics/Sprite/HUD/fire_4.png
Assets/_Game/Graphics/Sprite/HUD/fire_4.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/fire_5.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/fire_5.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/fire_5.png
Assets/_Game/Graphics/Sprite/HUD/fire_5.png
Assets/_Game/Graphics/Sprite/HUD/fire_5.png
Assets/_Game/Graphics/Sprite/HUD/fire_5.png
  • 2-up
  • Swipe
  • Onion skin
fileFormatVersion: 2
guid: fceda3bd95cbcc34890b77ed58b7e07e
TextureImporter:
fileIDToRecycleName: {}
fileIDToRecycleName:
21300000: fire_5_0
21300002: fire_5_1
21300004: fire_5_2
21300006: fire_5_3
21300008: fire_5_4
externalObjects: {}
serializedVersion: 9
mipmaps:
......@@ -82,11 +87,111 @@ TextureImporter:
androidETC2FallbackOverride: 0
spriteSheet:
serializedVersion: 2
sprites: []
sprites:
- serializedVersion: 2
name: fire_5_0
rect:
serializedVersion: 2
x: 22
y: 14
width: 196
height: 196
alignment: 0
pivot: {x: 0, y: 0}
border: {x: 0, y: 0, z: 0, w: 0}
outline: []
physicsShape: []
tessellationDetail: 0
bones: []
spriteID: f681a01cf01f3f541b32828838efbc82
vertices: []
indices:
edges: []
weights: []
- serializedVersion: 2
name: fire_5_1
rect:
serializedVersion: 2
x: 244
y: 14
width: 196
height: 196
alignment: 0
pivot: {x: 0, y: 0}
border: {x: 0, y: 0, z: 0, w: 0}
outline: []
physicsShape: []
tessellationDetail: 0
bones: []
spriteID: 5bf806a92fd64b64493694f7ac4f5659
vertices: []
indices:
edges: []
weights: []
- serializedVersion: 2
name: fire_5_2
rect:
serializedVersion: 2
x: 468
y: 14
width: 196
height: 196
alignment: 0
pivot: {x: 0, y: 0}
border: {x: 0, y: 0, z: 0, w: 0}
outline: []
physicsShape: []
tessellationDetail: 0
bones: []
spriteID: 8db3233c44b0e324b9bb72d620915851
vertices: []
indices:
edges: []
weights: []
- serializedVersion: 2
name: fire_5_3
rect:
serializedVersion: 2
x: 686
y: 14
width: 196
height: 196
alignment: 0
pivot: {x: 0, y: 0}
border: {x: 0, y: 0, z: 0, w: 0}
outline: []
physicsShape: []
tessellationDetail: 0
bones: []
spriteID: bbab3b146372cbb499453e04edf11172
vertices: []
indices:
edges: []
weights: []
- serializedVersion: 2
name: fire_5_4
rect:
serializedVersion: 2
x: 910
y: 14
width: 196
height: 196
alignment: 0
pivot: {x: 0, y: 0}
border: {x: 0, y: 0, z: 0, w: 0}
outline: []
physicsShape: []
tessellationDetail: 0
bones: []
spriteID: cb4ed6bcfe9c7df4eb47c41031b0204d
vertices: []
indices:
edges: []
weights: []
outline: []
physicsShape: []
bones: []
spriteID:
spriteID: fd429e4f5c3f717448192609bf7e686f
vertices: []
indices:
edges: []
......
Assets/_Game/Graphics/Sprite/HUD/wasser_1.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/wasser_1.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/wasser_1.png
Assets/_Game/Graphics/Sprite/HUD/wasser_1.png
Assets/_Game/Graphics/Sprite/HUD/wasser_1.png
Assets/_Game/Graphics/Sprite/HUD/wasser_1.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/wasser_2.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/wasser_2.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/wasser_2.png
Assets/_Game/Graphics/Sprite/HUD/wasser_2.png
Assets/_Game/Graphics/Sprite/HUD/wasser_2.png
Assets/_Game/Graphics/Sprite/HUD/wasser_2.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/wasser_3.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/wasser_3.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/wasser_3.png
Assets/_Game/Graphics/Sprite/HUD/wasser_3.png
Assets/_Game/Graphics/Sprite/HUD/wasser_3.png
Assets/_Game/Graphics/Sprite/HUD/wasser_3.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/wasser_4.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/wasser_4.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/wasser_4.png
Assets/_Game/Graphics/Sprite/HUD/wasser_4.png
Assets/_Game/Graphics/Sprite/HUD/wasser_4.png
Assets/_Game/Graphics/Sprite/HUD/wasser_4.png
  • 2-up
  • Swipe
  • Onion skin
Assets/_Game/Graphics/Sprite/HUD/wasser_5.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/wasser_5.png

130 Bytes | W: | H:

Assets/_Game/Graphics/Sprite/HUD/wasser_5.png
Assets/_Game/Graphics/Sprite/HUD/wasser_5.png
Assets/_Game/Graphics/Sprite/HUD/wasser_5.png
Assets/_Game/Graphics/Sprite/HUD/wasser_5.png
  • 2-up
  • Swipe
  • Onion skin
This diff is collapsed.
......@@ -12287,19 +12287,6 @@ PrefabInstance:
propertyPath: m_Pivot.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 114817957, guid: 50a0ddec8ac259c46a58a6b5324a759d, type: 3}
propertyPath: m_Name
value: Anzeige
objectReference: {fileID: 0}
- target: {fileID: 388107567, guid: 50a0ddec8ac259c46a58a6b5324a759d, type: 3}
propertyPath: ElementBox
value:
objectReference: {fileID: 0}
- target: {fileID: 388107565, guid: 50a0ddec8ac259c46a58a6b5324a759d, type: 3}
propertyPath: m_Sprite
value:
objectReference: {fileID: 21300000, guid: 706d34e52b620a34abdffce7a27726a1,
type: 3}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 50a0ddec8ac259c46a58a6b5324a759d, type: 3}
--- !u!1 &1046025670
......
......@@ -8,52 +8,76 @@ public class ElementAnzeige : MonoBehaviour
{
[SerializeField] private PlayerState state;
public Sprite empty;
public GameObject ElementBox;
public Sprite[] FeuerSprites;
public Sprite[] ErdeSprites;
public Sprite[] LuftSprites;
public Sprite[] WasserSprites;
public Sprite[] currentSprites;
public int availableCount = 0;
public Sprite[] feuerSprites;
public Sprite[] erdeSprites;
public Sprite[] luftSprites;
public Sprite[] wasserSprites;
private Sprite[] currentSprites;
private int availableCount = 0;
public GameObject[] textBox;
public void UpdateFeuerAnzeige()
{
currentSprites = FeuerSprites;
currentSprites = feuerSprites;
}
public void UpdateErdeAnzeige()
{
currentSprites = ErdeSprites;
currentSprites = erdeSprites;
}
public void UpdateWasserAnzeige()
{
currentSprites = WasserSprites;
currentSprites = wasserSprites;
}
public void UpdateLuftAnzeige()
{
currentSprites = LuftSprites;
currentSprites = luftSprites;
}
public void GetRemainingCharges()
{
availableCount = state.GetCharges();
Debug.Log(availableCount);
switch (availableCount)
{
case 5: ElementBox.GetComponent<Image>().sprite = currentSprites[4];
case 5: GetComponent<Image>().sprite = currentSprites[4];
break;
case 4: ElementBox.GetComponent<Image>().sprite = currentSprites[3];
case 4: GetComponent<Image>().sprite = currentSprites[3];
break;
case 3: ElementBox.GetComponent<Image>().sprite = currentSprites[2];
case 3: GetComponent<Image>().sprite = currentSprites[2];
break;
case 2: ElementBox.GetComponent<Image>().sprite = currentSprites[1];
case 2: GetComponent<Image>().sprite = currentSprites[1];
break;
case 1: ElementBox.GetComponent<Image>().sprite = currentSprites[0];
case 1: GetComponent<Image>().sprite = currentSprites[0];
break;
case 0: ElementBox.GetComponent<Image>().sprite = empty;
case 0: GetComponent<Image>().sprite = empty;
break;
}
}
public void ShowTextBox()
{
if (currentSprites == feuerSprites)
{
textBox[0].SetActive(true);
} else if (currentSprites == erdeSprites)
{
textBox[1].SetActive(true);
} else if (currentSprites == wasserSprites)
{
textBox[2].SetActive(true);
} else if (currentSprites == luftSprites)
{
textBox[3].SetActive(true);
}
}
public void HideTextBox()
{
textBox[0].SetActive(false);
textBox[1].SetActive(false);
textBox[2].SetActive(false);
textBox[3].SetActive(false);
}
}
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
using _Game.Scripts.Scriptable_Object;
public class FaehigkeitenBox : MonoBehaviour
{
[SerializeField] private PlayerState state;
private Image BoxImg;
public Sprite[] Boxen;
public GameObject[] TextBox;
// Start is called before the first frame update
void Start()
{
BoxImg = GetComponent<Image>();
}
// Update is called once per frame
void Update()
{
}
public void SetFeuerBox()
{
BoxImg.sprite = Boxen[1];
}
public void SetErdeBox()
{
BoxImg.sprite = Boxen[2];
}
public void SetWasserBox()
{
BoxImg.sprite = Boxen[3];
}
public void SetLuftBox()
{
BoxImg.sprite = Boxen[4];
}
public void ResetBox()
{
BoxImg.sprite = Boxen[0];
}
public void CheckCharges()
{
if (state.GetCharges() == 0)
{
ResetBox();
}
}
public void ShowTextBox()
{
TextBox[0].SetActive(true);
if (BoxImg.sprite == Boxen[1])
{
TextBox[0].SetActive(true);
} else if (BoxImg.sprite == Boxen[2])
{
TextBox[1].SetActive(true);
} else if (BoxImg.sprite == Boxen[3])
{
TextBox[2].SetActive(true);
} else if (BoxImg.sprite == Boxen[4])
{
TextBox[3].SetActive(true);
}
}
public void HideTextBox()
{
TextBox[0].SetActive(false);
TextBox[1].SetActive(false);
TextBox[2].SetActive(false);
TextBox[3].SetActive(false);
}
}
fileFormatVersion: 2
guid: 58d10beda6ed0de4a8aaf25af9976ee9
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment