# Opposite stats (problem)

**URL:** <https://forum.choiceofgames.com/t/opposite-stats-problem/40088>\
**Category:** ChoiceScript Help\
**Created:** [June 17, 2018, 5:29pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088 "2018-06-17T17:29:51Z")\
**Posts on this page:** 17\
**Page:** 1

<div class="post-metadata">

**Author:** ![Emmelienxd](https://avatars.discourse-cdn.com/v4/letter/e/76d3ee/32.png) [@Emmelienxd](https://forum.choiceofgames.com/u/Emmelienxd)\
**Post date:** [June 17, 2018, 5:29pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/1 "2018-06-17T17:29:51Z")

</div>

Hii guys, I’m probably blind but I can’t find anywhere how to make opposite stats. Like those percent stats where (mostly) in the beginning it is 50/50 each and by making choices it goes either way: like childlike/mature good/evil independent/dependent.

![afbeelding](https://global.discourse-cdn.com/choiceofgames/original/3X/f/1/f14793e0dc6ecc9ac72f44a37ebbd4477829ec4c.jpg)

This effect is what I want achieve 🙂  
Anyone who can help me and give me an example?

Thanks alot!

a newly trying coder 😉

---

<div class="post-metadata">

**Author:** ![MeltingPenguins](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/meltingpenguins/32/255855_2.png) [@MeltingPenguins](https://forum.choiceofgames.com/u/MeltingPenguins)\
**Post date:** [June 17, 2018, 5:33pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/2 "2018-06-17T17:33:53Z")

</div>

It’s

```
*stat_chart
   opposed_stat var1
      Text2

Or
*stat_chart
   opposed_stat var1
      Text1
      Text2

```

I think (on mobile atm, cant check quickly)  
First will display as  
Var1name vs text2  
The other as  
Text1 vs text2

---

<div class="post-metadata">

**Author:** ![lunawisp](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/lunawisp/32/85423_2.png) [@lunawisp](https://forum.choiceofgames.com/u/lunawisp)\
**Post date:** [June 17, 2018, 5:46pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/3 "2018-06-17T17:46:21Z")

</div>

When you create an opposed pair, you only need to create a variable for one of each of the pairs and you use text labels on each side. The way they’ve done your example is:

Create the variables for each of the stats in startup.txt

```
*create stat_impulsive 58
*create stat_sarcastic 58
*create stat_friendly 59
*create stat_easygoing 43

```

And in choicescript\_stats.txt they’ve used:

```
*stat_chart
	opposed_pair stat_impulsive
		Impulsive
		Cautious
	opposed_pair stat_sarcastic
		Sarcastic
		Genuine
	opposed_pair stat_friendly
		Friendly
		Stoic
	opposed_pair stat_easygoing
		Easygoing
		Stubborn
```

---

<div class="post-metadata">

**Author:** ![MeltingPenguins](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/meltingpenguins/32/255855_2.png) [@MeltingPenguins](https://forum.choiceofgames.com/u/MeltingPenguins)\
**Post date:** [June 17, 2018, 5:55pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/4 "2018-06-17T17:55:51Z")

</div>

Just have the  
\*create  
Start out with 50 (or whatever you wish it to start at)

---

<div class="post-metadata">

**Author:** ![Emmelienxd](https://avatars.discourse-cdn.com/v4/letter/e/76d3ee/32.png) [@Emmelienxd](https://forum.choiceofgames.com/u/Emmelienxd)\
**Post date:** [June 17, 2018, 6:00pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/5 "2018-06-17T18:00:31Z")

</div>

I tried to do it like you guys said but something is still wrong :s

![afbeelding](https://global.discourse-cdn.com/choiceofgames/original/3X/c/8/c800bcef062cb8d5c387011f58653d66939b4ff8.png)  
and

![afbeelding](https://global.discourse-cdn.com/choiceofgames/original/3X/b/0/b0586332606dc1ad9dbf89f81b48ca7ff821f4b3.png)

![afbeelding](https://global.discourse-cdn.com/choiceofgames/original/3X/b/0/b0dfa34205a4e51aaf91dc0fc038fde02fe3f1b0.png)

can you guys see what I did wrong?

---

<div class="post-metadata">

**Author:** ![Flaine1996](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/flaine1996/32/99838_2.png) [@Flaine1996](https://forum.choiceofgames.com/u/Flaine1996)\
**Post date:** [June 17, 2018, 6:03pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/6 "2018-06-17T18:03:11Z")

</div>

hi, just popping in have u tried making sure theres no space between opposed\_pair and stat chart and arranging them so that the opposed\_pair is under the t for stat\_chart? i know indentation is super important…

like

edit: sorry super weird how it wont allow me to do spacing properly…

 ![image](https://global.discourse-cdn.com/choiceofgames/original/3X/2/a/2a87fc2b343570e58ec4ee8145f4c007ffc55571.jpg)

---

<div class="post-metadata">

**Author:** ![MeltingPenguins](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/meltingpenguins/32/255855_2.png) [@MeltingPenguins](https://forum.choiceofgames.com/u/MeltingPenguins)\
**Post date:** [June 17, 2018, 6:07pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/7 "2018-06-17T18:07:50Z")

</div>

Add three ` above and below the code to format it in a post

---

<div class="post-metadata">

**Author:** ![Flaine1996](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/flaine1996/32/99838_2.png) [@Flaine1996](https://forum.choiceofgames.com/u/Flaine1996)\
**Post date:** [June 17, 2018, 6:08pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/8 "2018-06-17T18:08:29Z")

</div>

oohhh thank you for that XD had a hard time lol

---

<div class="post-metadata">

**Author:** ![lunawisp](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/lunawisp/32/85423_2.png) [@lunawisp](https://forum.choiceofgames.com/u/lunawisp)\
**Post date:** [June 17, 2018, 6:12pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/9 "2018-06-17T18:12:07Z")

</div>

You don’t need a blank line between \*stat\_chart and the following \*opposed\_pair and when you’re indenting, use either spaces or tabs, never try to use both.

---

<div class="post-metadata">

**Author:** ![Emmelienxd](https://avatars.discourse-cdn.com/v4/letter/e/76d3ee/32.png) [@Emmelienxd](https://forum.choiceofgames.com/u/Emmelienxd)\
**Post date:** [June 17, 2018, 6:18pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/10 "2018-06-17T18:18:08Z")

</div>

perfectly aligned, no (faulty) spaces and starting under the T of stat, with or without space between \*stat\_chart there keeps being a fault in the system 😓

---

<div class="post-metadata">

**Author:** ![lunawisp](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/lunawisp/32/85423_2.png) [@lunawisp](https://forum.choiceofgames.com/u/lunawisp)\
**Post date:** [June 17, 2018, 6:21pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/11 "2018-06-17T18:21:11Z")

</div>

Got to be something in your files. I didn’t just type that out on the fly, I created it in a test file I use in CSIDE and checked that it worked before copying and pasting it in to the forum.

Can you show us exactly what you have in your choicescript\_stats file. Put ``` above the text before you paste it in so it formats correctly.

---

<div class="post-metadata">

**Author:** ![Emmelienxd](https://avatars.discourse-cdn.com/v4/letter/e/76d3ee/32.png) [@Emmelienxd](https://forum.choiceofgames.com/u/Emmelienxd)\
**Post date:** [June 17, 2018, 7:05pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/12 "2018-06-17T19:05:30Z")

</div>

I will do it but I dont think it would turn up with much, did not put a lot before it since I’m still trying to form the beginning stats :s but if you think it will help. (this is what you mean right?)

btw I appriciate it a lot that you help so much and I’m sure you put your time into this 🙂

![afbeelding](https://global.discourse-cdn.com/choiceofgames/original/3X/4/5/4575d20babcb959e3995424bf635b0be124d42b8.png)

---

<div class="post-metadata">

**Author:** ![lunawisp](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/lunawisp/32/85423_2.png) [@lunawisp](https://forum.choiceofgames.com/u/lunawisp)\
**Post date:** [June 17, 2018, 7:15pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/13 "2018-06-17T19:15:22Z")

</div>

You pasted an image. We can’t see what’s going on with that. Can you just copy the text from the file onto the clipboard and paste it in as a forum post. Put ``` above it so it formats as text.

If you’re on windows, CTRL+A selects everything in the editing window, CTRL+C copies the selection onto the clipboard then create a reply in this thread, add the ``` followed by a return and then use CTRL+V to paste the code in.

---

<div class="post-metadata">

**Author:** ![Emmelienxd](https://avatars.discourse-cdn.com/v4/letter/e/76d3ee/32.png) [@Emmelienxd](https://forum.choiceofgames.com/u/Emmelienxd)\
**Post date:** [June 17, 2018, 7:19pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/14 "2018-06-17T19:19:33Z")

</div>

```
This is your stats screen!

Name:? Castle

Age: 1 year old

Gender: ?

*stat_chart
opposed_pair stat_impulsive
		Impulsive
		Cautious

opposed_pair stat_charming
		Charming
		Direct
```

---

<div class="post-metadata">

**Author:** ![lunawisp](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/lunawisp/32/85423_2.png) [@lunawisp](https://forum.choiceofgames.com/u/lunawisp)\
**Post date:** [June 17, 2018, 7:41pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/15 "2018-06-17T19:41:15Z")

</div>

Thanks, that’s better. It’s easier to see what’s going on there 😉

opposed\_pair needs to be indented.

It should look like:

\*stat\_chart  
[INDENT] opposed\_pair stat\_impulsive  
[INDENT][INDENT] Impulsive  
[INDENT][INDENT] Cautious

Choicescript is like Python in the way it uses indents to identify code blocks. Correct indentation is essential.

---

<div class="post-metadata">

**Author:** ![Emmelienxd](https://avatars.discourse-cdn.com/v4/letter/e/76d3ee/32.png) [@Emmelienxd](https://forum.choiceofgames.com/u/Emmelienxd)\
**Post date:** [June 17, 2018, 9:45pm UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/16 "2018-06-17T21:45:27Z")

</div>

eep! it just started working! 😃 tnx so much!

---

<div class="post-metadata">

**Author:** ![lunawisp](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/lunawisp/32/85423_2.png) [@lunawisp](https://forum.choiceofgames.com/u/lunawisp)\
**Post date:** [June 18, 2018, 8:15am UTC](https://forum.choiceofgames.com/t/opposite-stats-problem/40088/17 "2018-06-18T08:15:53Z")

</div>

> [@Emmelienxd](#):
>
> eep! it just started working! 😃 tnx so much!

You’re welcome. Glad to help. Once you’re over those first few formatting choicescript headaches the rest should just fall into place 😉
