Skip to content

Commit 347b89a

Browse files
committed
Release v1.22.0
1 parent 274d449 commit 347b89a

File tree

6 files changed

+19
-3
lines changed

6 files changed

+19
-3
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@
55
- Masked enemies holding items can now drop their items.
66
- Added a config option called ``Drop store item on death``. Default value: ``false``.
77
- Added a config option called ``Drop scrap item on death``. Default value: ``true``.
8+
- Added a config option called ``Scrap value multiplier``.
9+
- This only affects the scrap value multiplier for scrap items dropped by masked enemies.
10+
- Defualt value: ``1.0``.
811

912
### 1.21.0
1013

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ Mirage is a mod that gives any enemy the ability to mimic a player's voice (full
1414
- Only masked enemies mimic voices by default, other enemies can be enabled via config.
1515
- Masked enemies use the mimicking player's suit and cosmetics.
1616
- Masked enemies can spawn with a held item.
17+
- By default, only held scrap items are dropped.
1718
- Remove the mask from masked enemies.
1819
- Remove the arms-out animation from masked enemies.
1920
- Configuration is synced to all players (only the host's config is used).

package/mirage-lc/manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "Mirage",
3-
"version_number": "1.21.0",
3+
"version_number": "1.22.0",
44
"website_url": "https://github.com/qwbarch/mirage",
55
"description": "Voice mimicking where all players hear the same voice, with a focus on masked enemies. Alternative to Skinwalkers + MaskedEnemyOverhaul.",
66
"dependencies": [

package/mirage-lc/src/Mirage/Domain/Config.fs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,13 @@ type LocalConfig(general: ConfigFile, enemies: ConfigFile, items: ConfigFile) =
245245
"Drop held scrap item on death"
246246
true
247247
<| ConfigDescription description
248+
249+
member val ScrapValueMultiplier =
250+
let description = "Value multiplier to use on scrap items that drop from masked enemies."
251+
bindConfigureItem
252+
"Scrap value multiplier"
253+
1.0
254+
<| ConfigDescription description
248255

249256
let internal localConfig =
250257
LocalConfig(
@@ -286,6 +293,7 @@ type SyncedConfig =
286293
storeItemRollChance: int
287294
maskedDropStoreItemOnDeath: bool
288295
maskedDropScrapItemOnDeath: bool
296+
scrapValueMultiplier: float
289297

290298
enableMimicVoiceWhileAlive: bool
291299
enableRecordVoiceWhileDead: bool
@@ -341,6 +349,7 @@ let private toSyncedConfig () =
341349
storeItemRollChance = localConfig.StoreItemRollChance.Value
342350
maskedDropStoreItemOnDeath = localConfig.MaskedDropStoreItemOnDeath.Value
343351
maskedDropScrapItemOnDeath = localConfig.MaskedDropScrapItemOnDeath.Value
352+
scrapValueMultiplier = localConfig.ScrapValueMultiplier.Value
344353

345354
enableMimicVoiceWhileAlive = localConfig.EnableMimicVoiceWhileAlive.Value
346355
enableRecordVoiceWhileDead = localConfig.EnableRecordVoiceWhileDead.Value

package/mirage-lc/src/Mirage/PluginInfo.fs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ module Mirage.PluginInfo
22

33
let [<Literal>] pluginName = "Mirage"
44
let [<Literal>] pluginId = "qwbarch." + pluginName
5-
let [<Literal>] pluginVersion = "1.21.0"
5+
let [<Literal>] pluginVersion = "1.22.0"

package/mirage-lc/src/Mirage/Unity/MaskedAnimator.fs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,10 @@ type MaskedAnimator() =
5252
prefab.GetComponent<NetworkObject>().Spawn(destroyWithScene = true)
5353
struct (
5454
prefab.GetComponent<GrabbableObject>(),
55-
int <| float32 (random.Next(item.minValue, item.maxValue)) * RoundManager.Instance.scrapValueMultiplier
55+
int <|
56+
float (random.Next(item.minValue, item.maxValue))
57+
* float RoundManager.Instance.scrapValueMultiplier
58+
* getConfig().scrapValueMultiplier
5659
)
5760

5861
member val HeldItem = null with get, set

0 commit comments

Comments
 (0)