Skip to content

Commit

Permalink
Complete Getting Started category.
Browse files Browse the repository at this point in the history
  • Loading branch information
iChun committed Aug 2, 2018
1 parent 6cd35a4 commit 35dfb0b
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 7 deletions.
21 changes: 15 additions & 6 deletions docs/gettingstarted/importantdefinitions.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ It keeps everything in one place. Read about it in more detail [here](http://url

## Variables

Variables are, as the name implies, variables. They are essentially a key -> value mapping and are called using the $ symbol.
Variables are, as the name implies, variables. They are essentially a key -> value mapping and are called using the `$` symbol.

For example:
A chat message comes in:
Expand All @@ -27,17 +27,21 @@ user => Toto
message => I bless the rains down in Africa.
```

You can then check if the message is from Toto by checking the `user` variable for `Toto` (or use the Specific User Condition), or you tell the streamer that Toto said something using variable insertion such as `Hey $streamer, $user said something!`. Bear in mind that variable names are case-sensitive.
You can then check if the message is from Toto by checking the `user` variable for `Toto` (or use the Specific User Condition), or you tell the streamer that Toto said something using variable insertion such as `Hey $streamer, $user said something!`.

Bear in mind that variable names are case-sensitive.

Not everything in CCI supports variable insertion however, look out in their descriptions to see if they do.

<br>

### Global Variables

Now global variables function on the same concept, but they are always available. Normally, when a stream event happens, information gets put into variables, and once processed, are discarded.
Global variables function on the same concept, but they are always available. Normally, when a stream event happens, information gets put into variables, and once processed, are discarded.

Global variables allow these information to persist so you can reference them in different Events.

These are some global variables that are created when the mod is started
These are some global variables that are created when the mod is started:

| Variable Name |
|---------------|
Expand All @@ -48,11 +52,11 @@ These are some global variables that are created when the mod is started

A Condition is something used to check variables for the right value. If fitting, the condition is passed.

There is a variation which is "unconditional", despite being a Condition. These conditions are used to manipulate variables before they are checked or used in other conditions or outcomes.
There is a variation which is "unconditional", despite being a Condition. These conditions are used to manipulate variables before they are checked or used in other conditions or outcomes, and will always pass.

## Outcome

An Outcome is something, when triggered, would normall cause something to happen in the game. A sound being played, or a command being executed, that sort of thing.
An Outcome is something, when triggered, would normally cause something to happen in the game. A sound being played, or a command being executed, that sort of thing.

## Stream Event

Expand All @@ -73,3 +77,8 @@ An event is something that can potentially trigger from a Stream Event. Once the
Then, depending on the information from the stream event, conditions, if set, are checked, and depending on the Event's setup, the outcomes of the event will be triggered.

Bear in mind that Events are different from Stream Events, explained above.


## Constants

Constants is a special Event Configuration that contains a list of Events, Conditions and Outcomes that can be referenced by a name. For example, a condition that checks to see if the person who sent the chat message is a mod/editor.
2 changes: 1 addition & 1 deletion docs/gettingstarted/openingconfigeditor.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Presuming everything was done correctly and the service is working, CCI is now c

With the sockets connected, CCI is ready to receive events, but CCI doesn't know what to do with them yet. Therefore, you need to set up the event configuration.

Every type of layer in CCI has their own configuration, with exception of the chat layers. If things worked correctly, CCI should have generated the default event config and you can now see it in the config edit GUI.
Every type of layer in CCI has their own configuration, with exception of the chat layers. If things worked correctly, CCI should have generated the default event config and you can now see it in the config editor.

## The Config Editor

Expand Down
37 changes: 37 additions & 0 deletions docs/gettingstarted/settingup.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
Setting Up The Event Configuration
==================================

Alright so, we've gotten the important definitions out of the way, and you're looking at the Config Editor right now. Ideally, all editing of the Event Configuration file should be done in this GUI. Only edit by hand if you know what you are doing!

This doc would be a lot more useful with pictures but text will have to do for now.

1. Hopefully there is an entry in the left-most panel (that isn't named "Constants"). Click on it.

2. A new panel should have popped up. You've managed to go one level into the Event Configuration file.

...You should have noticed by now, on the bottom right panel, there will be useful flavor text that describes what you're looking at or clicking on.

3. Now you should see a couple of things listed in the second panel. One of these should be called `configs`. Click on it and click on the `+` on the header toolbar.

4. You should be able to click on `configs` once again and another panel should appear, showing a new Configuration. From here, you can set queues, define what this configuration is for, and set the events by type. More is explained in the Event Configuration class.

5. Experiment.

6. ????

7. Profit!


Remember to hit save.


### Disclaimer

Unfortunately, not much of the stream events are documented on their end, so the best you can do is experiment. CCI already provides you what info it can, particularly in terms of the variables of stream events that have occured on the bottom left of the Config Editor.

Streamlabs however has [some documentation](https://dev.streamlabs.com/docs/socket-api)(scroll down beyond the javascript code) but it is not 100% accurate to the real world application. CCI was initially designed around Streamlabs so you can see how things fit, following that documentation.


### That's all folks

That concludes our Getting Started category. This should be enough information for you to get the mod up and running and to the point where you yourself can create Events. The rest of the documentation will be more towards actually detailing the objects rather than "How-To"s. Good luck!
1 change: 1 addition & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ pages:
- First Launch, Mod Configs and Commands: 'gettingstarted/configs.md'
- Opening the Config Editor: 'gettingstarted/openingconfigeditor.md'
- Important Definitions: 'gettingstarted/importantdefinitions.md'
- Setting Up The Event Configuration: 'gettingstarted/settingup.md'

# Do not edit in PRs below here
site_name: Content Creator Integration Documentation
Expand Down

0 comments on commit 35dfb0b

Please sign in to comment.