Skip to content

Commit

Permalink
Fade times can now be set to 0 ms in the MCM.
Browse files Browse the repository at this point in the history
There is already code that snaps the alpha directly to the desired
goal when the remaining fade time is less than a 5ms, which will
handle this rest of the requested feature.

This should fix #78: make it possible to have the HUD snap in/out
of visibility
  • Loading branch information
ceejbot committed Nov 29, 2023
1 parent 249f912 commit c637209
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 20 deletions.
26 changes: 6 additions & 20 deletions data/mcm/config/SoulsyHUD/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -340,7 +340,7 @@
"help": "$SoulsyHUD_Options_FadeTime_Help",
"type": "slider",
"valueOptions": {
"min": 500,
"min": 0,
"max": 5000,
"step": 100,
"sourceType": "ModSettingInt"
Expand Down Expand Up @@ -371,10 +371,7 @@
"type": "enum",
"help": "$SoulsyHUD_Options_Controller_Help",
"valueOptions": {
"options": [
"$SoulsyHUD_Controls_PS",
"$SoulsyHUD_Controls_Xbox"
],
"options": ["$SoulsyHUD_Controls_PS", "$SoulsyHUD_Controls_Xbox"],
"sourceType": "ModSettingInt",
"defaultValue": 0
}
Expand Down Expand Up @@ -446,9 +443,7 @@
"action": {
"type": "CallFunction",
"function": "ShowCycleEntries",
"params": [
"{value}"
]
"params": ["{value}"]
}
},
{
Expand All @@ -457,10 +452,7 @@
"help": "$SoulsyHUD_ChosenCycle_Help",
"type": "menu",
"valueOptions": {
"options": [
" ",
" "
],
"options": [" ", " "],
"sourceType": "PropertyValueInt",
"propertyName": "pCycleItemShown",
"defaultValue": 0
Expand Down Expand Up @@ -522,10 +514,7 @@
"help": "$SoulsyHUD_EquipSetList_Help",
"type": "menu",
"valueOptions": {
"options": [
"$SoulsyHUD_NoEquipSets",
" "
],
"options": ["$SoulsyHUD_NoEquipSets", " "],
"sourceType": "PropertyValueString",
"propertyName": "pEquipSetMenuSelection"
}
Expand Down Expand Up @@ -577,10 +566,7 @@
"help": "$SoulsyHUD_EquipSetItemList_Help",
"type": "menu",
"valueOptions": {
"options": [
"$SoulsyHUD_NoItems",
" "
],
"options": ["$SoulsyHUD_NoItems", " "],
"sourceType": "PropertyValueString",
"propertyName": "pIconSourceSelection"
}
Expand Down
1 change: 1 addition & 0 deletions src/layouts/layout_v2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@ pub struct TextElement {
alignment: Align,
contents: String,
font_size: f32,
bounds: Option<Point>,
}

// TODO TODO TODO
Expand Down

0 comments on commit c637209

Please sign in to comment.