Adding bosses to the game #6

Merged
mico merged 21 commits from feature/boss-mechanic into main 2024-10-31 13:56:05 +00:00
2 changed files with 14 additions and 14 deletions
Showing only changes of commit ad0aa6e6d3 - Show all commits

View File

@ -4,17 +4,17 @@ import styles from "../styles/Army.module.css";
// Quote categories based on total minted GELD
const PROGRESSION_TIERS = {
BEGINNER: BigInt(1000000),
NOVICE: BigInt(10000000),
INTERMEDIATE: BigInt(100000000),
EXPERIENCED: BigInt(1000000000),
EXPERT: BigInt(10000000000),
MASTER: BigInt(100000000000),
EPIC: BigInt(1000000000000),
LEGENDARY: BigInt(10000000000000),
GUILD_LEADER: BigInt(100000000000000),
DIVINE: BigInt(1000000000000000),
MAXIMUM: BigInt(10000000000000000),
BEGINNER: BigInt("1000000"),
NOVICE: BigInt("10000000"),
INTERMEDIATE: BigInt("100000000"),
EXPERIENCED: BigInt("1000000000"),
EXPERT: BigInt("10000000000"),
MASTER: BigInt("100000000000"),
EPIC: BigInt("1000000000000"),
LEGENDARY: BigInt("10000000000000"),
GUILD_LEADER: BigInt("100000000000000"),
DIVINE: BigInt("1000000000000000"),
MAXIMUM: BigInt("10000000000000000"),
};
const quotes = {
@ -177,7 +177,7 @@ function PixelatedQuote() {
intervalIdRef.current = setInterval(() => {
const totalMinted = player?.total_minted ?? BigInt(0);
// Show welcome message only once at the start
if (!hasShownWelcome.current) {
setCurrentQuote("Welcome to the Dark Forest!");

View File

@ -20,7 +20,7 @@ const bossToMountainsClass = {
}
const Scene = () => {
const { isRegistered, boss } = usePlayer();
const { isRegistered, boss, player } = usePlayer();
const [isLeaderboardOpen, setIsLeaderboardOpen] = useState(false);
const handleMusicReady = useCallback((unmute: () => void) => {
@ -38,7 +38,7 @@ const Scene = () => {
<div className={`${styles.clouds_small} ${styles.background_asset}`} />
<div className={`${styles.mountains} ${styles.background_asset} ${bossToMountainsClass[variant]}`} />
<div className={`${styles.village} ${styles.background_asset}`} />
{isRegistered && <BossInfo />}
{isRegistered && player?.has_active_session && <BossInfo />}
<MarchingBand />
<div className={`${styles.bonfire} ${styles.background_asset}`} />
<Army />