new icon art

This commit is contained in:
Pfauenauge90 2020-03-25 01:41:43 +01:00
parent 7f02f5e7d2
commit 550dd144bc
8 changed files with 58 additions and 16 deletions

BIN
assets/voxygen/element/icons/fire_bolt_1.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/element/icons/fire_spell_0.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/element/icons/heal_0.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/element/misc_bg/map_bg.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
assets/voxygen/element/misc_bg/map_frame.png (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -117,7 +117,6 @@ image_ids! {
flyingrod_m2: "voxygen.element.icons.debug_wand_m2", flyingrod_m2: "voxygen.element.icons.debug_wand_m2",
charge: "voxygen.element.icons.skill_charge_3", charge: "voxygen.element.icons.skill_charge_3",
// Icons // Icons
flower: "voxygen.element.icons.item_flower", flower: "voxygen.element.icons.item_flower",
grass: "voxygen.element.icons.item_grass", grass: "voxygen.element.icons.item_grass",
@ -203,6 +202,10 @@ image_ids! {
////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////
<ImageGraphic> <ImageGraphic>
// Map
map_bg: "voxygen.element.misc_bg.map_bg",
map_frame: "voxygen.element.misc_bg.map_frame",
// MiniMap // MiniMap
mmap_frame: "voxygen.element.frames.mmap", mmap_frame: "voxygen.element.frames.mmap",
mmap_frame_2: "voxygen.element.frames.mmap_frame", mmap_frame_2: "voxygen.element.frames.mmap_frame",
@ -271,7 +274,9 @@ image_ids! {
banner_top: "voxygen.element.frames.banner_top", banner_top: "voxygen.element.frames.banner_top",
// Icons
fire_spell_1: "voxygen.element.icons.fire_spell_0",
heal_0: "voxygen.element.icons.heal_0",
// Buttons // Buttons
button: "voxygen.element.buttons.button", button: "voxygen.element.buttons.button",

View File

@ -56,6 +56,7 @@ const TEXT_COLOR: Color = Color::Rgba(1.0, 1.0, 1.0, 1.0);
const MENU_BG: Color = Color::Rgba(0.0, 0.0, 0.0, 0.4); const MENU_BG: Color = Color::Rgba(0.0, 0.0, 0.0, 0.4);
//const TEXT_COLOR_2: Color = Color::Rgba(0.0, 0.0, 0.0, 1.0); //const TEXT_COLOR_2: Color = Color::Rgba(0.0, 0.0, 0.0, 1.0);
const TEXT_COLOR_3: Color = Color::Rgba(1.0, 1.0, 1.0, 0.1); const TEXT_COLOR_3: Color = Color::Rgba(1.0, 1.0, 1.0, 0.1);
const BLACK: Color = Color::Rgba(0.0, 0.0, 0.0, 0.98);
//const BG_COLOR: Color = Color::Rgba(1.0, 1.0, 1.0, 0.8); //const BG_COLOR: Color = Color::Rgba(1.0, 1.0, 1.0, 0.8);
const HP_COLOR: Color = Color::Rgba(0.33, 0.63, 0.0, 1.0); const HP_COLOR: Color = Color::Rgba(0.33, 0.63, 0.0, 1.0);
const LOW_HP_COLOR: Color = Color::Rgba(0.93, 0.59, 0.03, 1.0); const LOW_HP_COLOR: Color = Color::Rgba(0.93, 0.59, 0.03, 1.0);

View File

@ -1,6 +1,6 @@
use super::{ use super::{
img_ids::Imgs, BarNumbers, ShortcutNumbers, XpBar, CRITICAL_HP_COLOR, HP_COLOR, LOW_HP_COLOR, img_ids::Imgs, BarNumbers, ShortcutNumbers, XpBar, BLACK, CRITICAL_HP_COLOR, HP_COLOR,
MANA_COLOR, TEXT_COLOR, XP_COLOR, LOW_HP_COLOR, MANA_COLOR, TEXT_COLOR, XP_COLOR,
}; };
use crate::{ use crate::{
i18n::{i18n_asset_key, VoxygenLocalization}, i18n::{i18n_asset_key, VoxygenLocalization},
@ -10,7 +10,7 @@ use crate::{
use common::{ use common::{
assets::load_expect, assets::load_expect,
comp::{ comp::{
item::{DebugKind, ToolData, ToolKind}, item::{DebugKind, StaffKind, ToolData, ToolKind},
CharacterState, ControllerInputs, Energy, ItemKind, Loadout, Stats, CharacterState, ControllerInputs, Energy, ItemKind, Loadout, Stats,
}, },
}; };
@ -19,7 +19,11 @@ use conrod_core::{
widget::{self, Button, Image, Rectangle, Text}, widget::{self, Button, Image, Rectangle, Text},
widget_ids, Color, Colorable, Positionable, Sizeable, Widget, WidgetCommon, widget_ids, Color, Colorable, Positionable, Sizeable, Widget, WidgetCommon,
}; };
use std::time::{Duration, Instant}; //use const_tweaker::tweak;
use std::time::{Duration, Instant}; // <- REMOVE THIS BEFORE MERGE!
/*#[tweak(min = 0.5, max = 1.0, step = 0.01)]
const ALPHA: f32 = 0.90;*/
widget_ids! { widget_ids! {
struct Ids { struct Ids {
@ -703,6 +707,7 @@ impl<'a> Widget for Skillbar<'a> {
ToolKind::Hammer(_) => self.imgs.twohhammer_m2, ToolKind::Hammer(_) => self.imgs.twohhammer_m2,
ToolKind::Axe(_) => self.imgs.twohaxe_m2, ToolKind::Axe(_) => self.imgs.twohaxe_m2,
ToolKind::Bow(_) => self.imgs.bow_m2, ToolKind::Bow(_) => self.imgs.bow_m2,
ToolKind::Staff(StaffKind::Sceptre) => self.imgs.heal_0,
ToolKind::Staff(_) => self.imgs.staff_m2, ToolKind::Staff(_) => self.imgs.staff_m2,
ToolKind::Debug(DebugKind::Boost) => self.imgs.flyingrod_m2, ToolKind::Debug(DebugKind::Boost) => self.imgs.flyingrod_m2,
_ => self.imgs.twohaxe_m2, _ => self.imgs.twohaxe_m2,
@ -819,19 +824,35 @@ impl<'a> Widget for Skillbar<'a> {
} }
Image::new(self.imgs.skillbar_slot_bg) Image::new(self.imgs.skillbar_slot_bg)
.w_h(19.5 * scale, 19.5 * scale) .w_h(19.5 * scale, 19.5 * scale)
.color(Some(BG_COLOR)) .color(
match self.loadout.active_item.as_ref().map(|i| &i.item.kind) {
Some(ItemKind::Tool(ToolData { kind, .. })) => match kind {
ToolKind::Staff(StaffKind::BasicStaff) => Some(BLACK),
_ => Some(BG_COLOR),
},
_ => Some(BG_COLOR),
},
)
.middle_of(state.ids.slot1) .middle_of(state.ids.slot1)
.set(state.ids.slot1_bg, ui); .set(state.ids.slot1_bg, ui);
// TODO: Changeable slot image // TODO: Changeable slot image
/*Image::new(self.imgs.charge) match self.loadout.active_item.as_ref().map(|i| &i.item.kind) {
.w_h(18.0 * scale, 18.0 * scale) Some(ItemKind::Tool(ToolData { kind, .. })) => match kind {
.color(if self.energy.current() as f64 >= 200.0 { ToolKind::Staff(StaffKind::BasicStaff) => {
Some(Color::Rgba(1.0, 1.0, 1.0, 1.0)) Image::new(self.imgs.fire_spell_1)
} else { .w_h(18.0 * scale, 18.0 * scale)
Some(Color::Rgba(0.4, 0.4, 0.4, 1.0)) .color(if self.energy.current() as f64 >= 500.0 {
}) Some(Color::Rgba(1.0, 1.0, 1.0, 1.0))
.middle_of(state.ids.slot1_bg) } else {
.set(state.ids.slot1_icon, ui);*/ Some(Color::Rgba(0.4, 0.4, 0.4, 1.0))
})
.middle_of(state.ids.slot1_bg)
.set(state.ids.slot1_icon, ui);
},
_ => {},
},
_ => {},
}
// Slot 6 // Slot 6
Image::new(self.imgs.skillbar_slot) Image::new(self.imgs.skillbar_slot)
.w_h(20.0 * scale, 20.0 * scale) .w_h(20.0 * scale, 20.0 * scale)