Skip to content

Commit

Permalink
Some cleanup/bugfixes, README.md additions
Browse files Browse the repository at this point in the history
  • Loading branch information
ScriptedSnark committed Mar 16, 2024
1 parent fda063c commit b1a26d1
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 14 deletions.
9 changes: 0 additions & 9 deletions GSChaos.sln
Original file line number Diff line number Diff line change
Expand Up @@ -7,24 +7,15 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GSChaos", "GSChaos\GSChaos.
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|x64 = Release|x64
Release|x86 = Release|x86
Retail|x64 = Retail|x64
Retail|x86 = Retail|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{B711BD44-B111-4EE2-9445-111685C51B86}.Debug|x64.ActiveCfg = Debug|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Debug|x64.Build.0 = Debug|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Debug|x86.ActiveCfg = Debug|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Debug|x86.Build.0 = Debug|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Release|x64.ActiveCfg = Release|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Release|x64.Build.0 = Release|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Release|x86.ActiveCfg = Release|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Release|x86.Build.0 = Release|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Retail|x64.ActiveCfg = Release|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Retail|x64.Build.0 = Release|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Retail|x86.ActiveCfg = Release|Win32
{B711BD44-B111-4EE2-9445-111685C51B86}.Retail|x86.Build.0 = Release|Win32
EndGlobalSection
Expand Down
7 changes: 4 additions & 3 deletions GSChaos/CChaos.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ void CChaos::Init()

chaos_effectname_ypos = pEngfuncs->pfnRegisterVariable("chaos_effectname_ypos", "0.0", 0);

for (int i = 0; i < 2; i++)
for (int i = 0; i < 3; i++)
{
m_aiEffectsForVoting[i] = GetRandomEffect(0, gChaosFeatures.size() - 1);
}
Expand Down Expand Up @@ -375,7 +375,8 @@ void CChaos::Reset()

void CChaos::Shutdown()
{
twitch->Disconnect();
if (twitch && twitch->status != TWITCH_DISCONNECTED)
twitch->Disconnect();
}

void CChaos::PrintVersion()
Expand Down Expand Up @@ -591,7 +592,7 @@ void CChaos::OnFrame(double time)

InitVotingSystem();

for (int i = 0; i < 2; i++)
for (int i = 0; i < 3; i++)
{
m_aiEffectsForVoting[i] = GetRandomEffect(0, gChaosFeatures.size() - 1);
}
Expand Down
14 changes: 12 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,17 @@ Additional info:
- `chaos_effectname_ypos` - sets position of effect name text by vertical (Y coord)

## Twitch voting integration (WIP)
Chaos Mod supports voting feature via Twitch chat. You can setup it by editing `chaos/twitch.ini`. Get your OAuth pass **[here](https://twitchapps.com/tmi/)**.
If you don't want to play with this feature, you can delete (or rename) `chaos/twitch.ini`.
GSChaos supports Twitch chat voting. If you want to use it, then do some steps:
1. Download [latest continuous release](https://github.com/ScriptedSnark/GSChaos/releases/tag/continuous)
2. Install it
3. Edit `chaos/twitch.ini`. It should have your [OAuth password](https://twitchapps.com/tmi/) and Twitch username
4. Add text element (GDI) to your OBS scene
5. Create file - `chaos/voting_progress.txt`
6. Pass a path of that file in text options
7. Run the game and check if everything is installed successfully (wait for 10 seconds in game after chaos bar activating so you can check voting system)

To vote, you need to type `effectNUMBER` in chat (for example, `effect2`).
If you don't want to play with this feature, rename `twitch.ini` to `twitch_DISABLED.ini`.

## Effects
```
Expand Down Expand Up @@ -76,5 +85,6 @@ Special thanks to:
- anewnick (a.k.a codque) for designing HUDs
- SmileyAG for provided help about some aspects of hooking
- BlueNightHawk for late precache system
- suXinjke for [Half-Payne](https://github.com/suXinjke/HalfPayne)
- un4seen (a.k.a. yanny) for supporting/playtesting
- Tankfird, StereoBucket, prolert, gatar and other people for suggesting effects, ideas

0 comments on commit b1a26d1

Please sign in to comment.