Files
tp/src/d/d_select_icon.cpp
T
LagoLunatic 9eea9289b1 Fix JUT_ASSERT and several other macros (#2711)
* Fix JUT_ASSERT to be a nested define

* Switch names that appear in asserts to be constants instead of defines

* Replace `0` in asserts with `NULL` or `FALSE`

* Fix fpclassify

* Fix ARRAY_SIZE

* Use G_CM3D_F_INF

* More fixes for fpclassify

* Remove FLOAT_LABEL

* Remove incorrect FLAG_ON macro

* Remove UNK_BSS macro

* Silence clangd unused header warning for PCH
2025-09-28 13:11:07 -07:00

40 lines
1.0 KiB
C++

#include "d/dolzel.h" // IWYU pragma: keep
#include "d/d_select_icon.h"
#include "JSystem/J2DGraph/J2DAnimation.h"
dSi_HIO_c::dSi_HIO_c() {}
void dSelect_icon_c::animation() {
if (field_0x10->getAlpha() != 0) {
field_0x20 += field_0x2c;
if (field_0x20 >= field_0x1c->getFrameMax()) {
field_0x20 = 0.0f;
}
field_0x1c->setFrame(field_0x20);
field_0x28 += field_0x2c;
if (field_0x28 >= field_0x24->getFrameMax()) {
field_0x28 = 0.0f;
}
field_0x24->setFrame(field_0x28);
field_0x8->animation();
field_0x10->paneScale(field_0x14, field_0x14);
}
}
void dSelect_icon_c::setAlpha(u8 param_0) {
field_0x10->setAlpha(param_0);
}
void dSelect_icon_c::setPos(J2DPane* param_0, f32 transX, f32 transY) {
field_0x14 = param_0->getWidth() / 100.0f;
field_0x18 = param_0->getHeight() / 100.0f;
field_0x10->paneScale(field_0x14, field_0x14);
field_0xc->getPanePtr()->translate(transX, transY);
}
static dSi_HIO_c g_siHIO;