mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Add Chrismas wreath (25% chance) and make the towns go wild with illumination
This commit is contained in:
parent
3edc7b5846
commit
cbd2a422f3
@ -2030,6 +2030,16 @@ ChristmasOrnament: Some((
|
|||||||
],
|
],
|
||||||
wind_sway: 0.2,
|
wind_sway: 0.2,
|
||||||
)),
|
)),
|
||||||
|
ChristmasWreath: Some((
|
||||||
|
variations: [
|
||||||
|
(
|
||||||
|
model: "voxygen.voxel.sprite.furniture.wreath-0",
|
||||||
|
offset: (-6.5, -4.5, 0.0),
|
||||||
|
lod_axes: (1.0, 1.0, 1.0),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
wind_sway: 0.0,
|
||||||
|
)),
|
||||||
// WallSconce
|
// WallSconce
|
||||||
WallSconce: Some((
|
WallSconce: Some((
|
||||||
variations: [
|
variations: [
|
||||||
|
@ -189,6 +189,7 @@ make_case_elim!(
|
|||||||
JungleRedGrass = 0xA2,
|
JungleRedGrass = 0xA2,
|
||||||
Bomb = 0xA3,
|
Bomb = 0xA3,
|
||||||
ChristmasOrnament = 0xA4,
|
ChristmasOrnament = 0xA4,
|
||||||
|
ChristmasWreath = 0xA5,
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
@ -453,6 +454,7 @@ impl SpriteKind {
|
|||||||
| SpriteKind::Loom
|
| SpriteKind::Loom
|
||||||
| SpriteKind::DismantlingBench
|
| SpriteKind::DismantlingBench
|
||||||
| SpriteKind::ChristmasOrnament
|
| SpriteKind::ChristmasOrnament
|
||||||
|
| SpriteKind::ChristmasWreath
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@ use crate::{
|
|||||||
IndexRef,
|
IndexRef,
|
||||||
};
|
};
|
||||||
use common::{
|
use common::{
|
||||||
calendar::Calendar,
|
calendar::{Calendar, CalendarEvent},
|
||||||
make_case_elim,
|
make_case_elim,
|
||||||
terrain::{Block, BlockKind, SpriteKind},
|
terrain::{Block, BlockKind, SpriteKind},
|
||||||
};
|
};
|
||||||
@ -241,7 +241,9 @@ impl Archetype for House {
|
|||||||
noise: RandomField::new(rng.gen()),
|
noise: RandomField::new(rng.gen()),
|
||||||
roof_ribbing: rng.gen(),
|
roof_ribbing: rng.gen(),
|
||||||
roof_ribbing_diagonal: rng.gen(),
|
roof_ribbing_diagonal: rng.gen(),
|
||||||
christmas_decorations: calendar.map(|c| c.is_event(CalendarEvent::Christmas)),
|
christmas_decorations: calendar
|
||||||
|
.map(|c| c.is_event(CalendarEvent::Christmas))
|
||||||
|
.unwrap_or_default(),
|
||||||
};
|
};
|
||||||
|
|
||||||
(this, skel)
|
(this, skel)
|
||||||
@ -612,13 +614,21 @@ impl Archetype for House {
|
|||||||
if dist == width + 1
|
if dist == width + 1
|
||||||
&& center_offset.map(|e| e.abs()).reduce_min() == 0
|
&& center_offset.map(|e| e.abs()).reduce_min() == 0
|
||||||
&& profile.y == floor_height + 3
|
&& profile.y == floor_height + 3
|
||||||
&& self
|
&& self.noise.chance(
|
||||||
.noise
|
Vec3::new(center_offset.x, center_offset.y, z),
|
||||||
.chance(Vec3::new(center_offset.x, center_offset.y, z), 0.35)
|
if christmas_theme { 0.70 } else { 0.35 },
|
||||||
|
)
|
||||||
&& attr.storey_fill.has_lower()
|
&& attr.storey_fill.has_lower()
|
||||||
{
|
{
|
||||||
let ornament = if christmas_theme {
|
let ornament = if christmas_theme {
|
||||||
SpriteKind::ChristmasOrnament
|
match self
|
||||||
|
.noise
|
||||||
|
.get(Vec3::new(center_offset.x, center_offset.y, z + 100))
|
||||||
|
% 4
|
||||||
|
{
|
||||||
|
0 => SpriteKind::ChristmasWreath,
|
||||||
|
_ => SpriteKind::ChristmasOrnament,
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
match self
|
match self
|
||||||
.noise
|
.noise
|
||||||
|
Loading…
x
Reference in New Issue
Block a user