Skip to content

Conversation

@daft7
Copy link
Contributor

@daft7 daft7 commented Nov 17, 2025

Useful groundwork for xHudFontMeter, all methods for this file.

@github-actions
Copy link

main/SB/Core/x/xHudFontMeter

Section From To Bytes
📈 .data 0.00% 68.38% +38
📈 .rodata 0.00% 46.88% +26
.sbss 0.00% 100.00% +8
📈 .sdata2 0.00% 68.75% +16
📈 .text 0.00% 40.98% +572
Function From To Bytes
📈 xhud::font_meter_widget::load(xBase&, xDynAsset&, unsigned long) 0.00% 4.55% +4
xhud::font_meter_widget::destruct() 0.00% 100.00% +32
xhud::font_meter_widget::destroy() 0.00% 100.00% +32
📈 xhud::font_meter_widget::update(float) 0.00% 60.99% +300
xhud::font_meter_widget::render() 0.00% 100.00% +192
xhud::font_meter_asset::type_name() 0.00% 100.00% +12


void xhud::font_meter_widget::destruct()
{
((xhud::meter_widget*)this)->destruct();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Prefer xhud::meter_widget::destruct() to call a base class virtual function over manually casting the this pointer.

Comment on lines 88 to 96
(*this).updater(dt);
this->xf.id = (this->font).id;
this->xf.space = (this->font).space;
a = (*this).rc.size.x;
this->font.w = a;
this->xf.width = a;
a = (*this).rc.size.y;
this->font.h = a;
this->xf.height = a;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(*this). is the same as this->, you should use the arrow operator here for consistency and readability. Additionally the redundant parentheses should be cleaned up (i.e this->font.id instead of (this->font).id. Same goes for the rest of the additions in this file.

@github-actions
Copy link

main/SB/Core/x/xHudFontMeter

Section From To Bytes
📈 .data 0.00% 68.38% +38
📈 .rodata 0.00% 46.88% +26
.sbss 0.00% 100.00% +8
📈 .sdata2 0.00% 68.75% +16
📈 .text 0.00% 40.98% +572
Function From To Bytes
📈 xhud::font_meter_widget::load(xBase&, xDynAsset&, unsigned long) 0.00% 4.55% +4
xhud::font_meter_widget::destruct() 0.00% 100.00% +32
xhud::font_meter_widget::destroy() 0.00% 100.00% +32
📈 xhud::font_meter_widget::update(float) 0.00% 60.99% +300
xhud::font_meter_widget::render() 0.00% 100.00% +192
xhud::font_meter_asset::type_name() 0.00% 100.00% +12

@JoshSanch JoshSanch merged commit 17e3761 into bfbbdecomp:main Nov 19, 2025
5 checks passed
@daft7 daft7 deleted the xHudFontMeter branch November 19, 2025 02:16
escape209 pushed a commit to escape209/bfbbdecomp that referenced this pull request Nov 19, 2025
* xHudFontMeter overhead

* Method for converting color32u to iColor_tag

* Generally okay matches for xHudFontMeter

* Seeing if it builds with new commented out

* Other build fix (thanks Sway)

* Revert, this was fine

* My redefinition of the load method was breaking things. Reverted and method commented to be a stub.

* Square tweaks

Work DO NOT PR

xEntBoulder progress

xEntBoulder progress

Mostly match xEntBoulder_Update

Match more stuff
escape209 pushed a commit to escape209/bfbbdecomp that referenced this pull request Nov 19, 2025
* xHudFontMeter overhead

* Method for converting color32u to iColor_tag

* Generally okay matches for xHudFontMeter

* Seeing if it builds with new commented out

* Other build fix (thanks Sway)

* Revert, this was fine

* My redefinition of the load method was breaking things. Reverted and method commented to be a stub.

* Square tweaks

Work DO NOT PR

xEntBoulder progress

xEntBoulder progress

Mostly match xEntBoulder_Update

Match more stuff
escape209 pushed a commit to escape209/bfbbdecomp that referenced this pull request Nov 19, 2025
* xHudFontMeter overhead

* Method for converting color32u to iColor_tag

* Generally okay matches for xHudFontMeter

* Seeing if it builds with new commented out

* Other build fix (thanks Sway)

* Revert, this was fine

* My redefinition of the load method was breaking things. Reverted and method commented to be a stub.

* Square tweaks
escape209 pushed a commit to escape209/bfbbdecomp that referenced this pull request Nov 19, 2025
* xHudFontMeter overhead

* Method for converting color32u to iColor_tag

* Generally okay matches for xHudFontMeter

* Seeing if it builds with new commented out

* Other build fix (thanks Sway)

* Revert, this was fine

* My redefinition of the load method was breaking things. Reverted and method commented to be a stub.

* Square tweaks

Work DO NOT PR

xEntBoulder progress

xEntBoulder progress

Mostly match xEntBoulder_Update

Match more stuff
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants