New Super Mario Bros. U Headers
Loading...
Searching...
No Matches
Bg.h
Go to the documentation of this file.
1#pragma once
2
3#include <collision/BgUnitCode.h>
4
5#include <heap/seadDisposer.h>
6
7class Bg
8{
10
11public:
12 Bg();
13 virtual ~Bg();
14
15 static u16* getUnit(u16 x, u16 y, u32 file, u8 layer, s32* block_idx = nullptr);
16 static u16* getUnitCurrentCdFile(u16 x, u16 y, u8 layer, s32* block_idx = nullptr);
17
18 u64 getBgCheckData(u16 x, u16 y, u8 layer, bool with_p_sw = true); // See BgUnitCode
19 u64 getBgCheckData(f32 x, f32 y, u8 layer, bool with_p_sw = true) // ^^^
20 {
21 return getBgCheckData(u16(x), u16(-y), layer, with_p_sw);
22 }
23
24 BgUnitCode::HitType getUnitHitType(u16 x, u16 y, u8 layer);
25 BgUnitCode::HitType getUnitHitType(f32 x, f32 y, u8 layer)
26 {
27 return getUnitHitType(u16(x), u16(-y), layer);
28 }
29
30 BgUnitCode::Type getUnitType(u16 x, u16 y, u8 layer);
31 BgUnitCode::Type getUnitType(f32 x, f32 y, u8 layer)
32 {
33 return getUnitType(u16(x), u16(-y), layer);
34 }
35
36 BgUnitCode::TypeInfo getUnitTypeInfo(u16 x, u16 y, u8 layer);
37 BgUnitCode::TypeInfo getUnitTypeInfo(f32 x, f32 y, u8 layer)
38 {
39 return getUnitTypeInfo(u16(x), u16(-y), layer);
40 }
41
42 void setWaterInWave(const sead::Vector2f& pos, u8 wave_scale);
43};
Definition Bg.h:8
void setWaterInWave(const sead::Vector2f &pos, u8 wave_scale)
BgUnitCode::TypeInfo getUnitTypeInfo(u16 x, u16 y, u8 layer)
u64 getBgCheckData(u16 x, u16 y, u8 layer, bool with_p_sw=true)
virtual ~Bg()
static u16 * getUnit(u16 x, u16 y, u32 file, u8 layer, s32 *block_idx=nullptr)
static u16 * getUnitCurrentCdFile(u16 x, u16 y, u8 layer, s32 *block_idx=nullptr)
BgUnitCode::Type getUnitType(u16 x, u16 y, u8 layer)
BgUnitCode::HitType getUnitHitType(u16 x, u16 y, u8 layer)