-
-
Notifications
You must be signed in to change notification settings - Fork 116
Update the super weapon to play music. #1832
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Conversation
Perhaps a flag should be added to control which houses will be affected. |
where is dll? |
Nightly build for this pull request:
This comment is automatic and is meant to allow guests to get latest nightly builds for this pull request without registering. It is updated on every successful build. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should add docs in CREDITS.md
done |
I accidentally synced with the latest branch, but it should be restored now. |
I'm not sure if |
I am making a small mod myself, and I really need this feature. |
If we're keeping this feature then it'd better be done in a way like AutoDeath and TransportReloader, which is making a global vector to store the superweapon entity and only iterate it instead of looping all houses + all SWs. That would require a proper InvalidatePointer modification tho Another idea is to only store a timer in HouseExt, which will be set once such SW is fired, and checking if it's completed in the same hook for music reset. This could at least decrease the complexity of checking every SW. It'll change the behavior a bit tho: if the original superweapon is gone (by building destruction or such), the music will still be reset once the time meets |
In my opinion, this feature is somewhat "arbitrary". To me it sounds like there should be a basic dynamic music system, with ability to designate idle/combat/special event tracks, and this should be a part of it. |
maybe Music.AffectedHouses could use (owner/self|allies/ally|team|enemies/enemy|all) , just like other features whitch affect houses. At least, team is different from ally. |
and when |
I don't think it matters. Some maps in StarCraft 2 have similar designs. As far as I know, no one thinks this is a problem that needs attention.
If you are worried about performance, we can add the affected HouseClass to an additional vector of ScenarioExt and then loop through that vector. Also, HouseClass::Array is a relatively small array. I guess looping through it shouldn't incur much additional overhead. |
Music.Theme
selects the soundtrack theme by its ID defined inthememd.ini
(such asGodsendOne
).Music.Duration
sets how long to keep playing, in game frames. 0 or below means no auto-stop.Music.Theme
; if music was changed during the countdown, it will not be altered.Music.AffectedHouses
determines which houses will hear and be affected by the superweapon music on their client:owner
,allies
,enemies
, orall
(default). Playback and auto-stop are applied only for those houses.