# Trying to create a power list

**URL:** <https://forum.choiceofgames.com/t/trying-to-create-a-power-list/39084>\
**Category:** ChoiceScript Help\
**Created:** [May 20, 2018, 2:24am UTC](https://forum.choiceofgames.com/t/trying-to-create-a-power-list/39084 "2018-05-20T02:24:00Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Omegareaven](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/omegareaven/32/46502_2.png) [@Omegareaven](https://forum.choiceofgames.com/u/Omegareaven)\
**Post date:** [May 20, 2018, 2:24am UTC](https://forum.choiceofgames.com/t/trying-to-create-a-power-list/39084/1 "2018-05-20T02:24:00Z")

</div>

I’m trying to create a stats section for a list of powers. To show those that have been attained and those that haven’t been.

For example, I want it to look kind like this when you view it:  
Healing - Acquired- Can not heal wounds, blah, blah, etc.  
Healing Advanced - Can not heal fatal wounds, etc.  
Echo - Unknown.

What would be the best method of achieving this screen?

Should I use boolean such as  
\*create healing true  
or use fairmath  
\*create healing 0

Then for putting it in the stats screen should it look like this?

```
*temp healing_text ""
*if (healing < 1)
    *set healing_text "Unknown"
    *goto healing
*else (healing = 1)
    *set healing_ text "Can heal wounds quickly and fatal wounds over time, can heal others from non-fatal injuries over time, and can slightly improve durability. 
    *goto healing
*label screen
*choice
   #Powers
        *stat_chart
            text healing_text Healing
        *goto screen

```

That look correct? That’s using the fairmath way, not even sure how to do it boolean style lol. Hope thats enough info to get what im shooting for.

---

<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:** [May 20, 2018, 6:37am UTC](https://forum.choiceofgames.com/t/trying-to-create-a-power-list/39084/2 "2018-05-20T06:37:01Z")

</div>

Fairmath is used to ensure that values never drop below zero or rise above 100. I’m not a fan of using it, I’d rather keep values within limits myself…

You’d need to use \*elseif rather than \*else in that context. You shouldn’t follow \*else with a condition, it’ll never be checked.

BUT…

If you only want to show text for powers that have been attained and you use a variable to hold the power’s current level, you could use something like…

@{(healing + 1) Unknown|text for level 1|text for level 2| etc}

You use vertical bars to delimit the strings for each ‘level’. Elements start at 1 so we have to add 1 to ‘healing’ since your initial value was zero and that will cause an error.

---

<div class="post-metadata">

**Author:** ![Szaal](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/szaal/32/112202_2.png) [@Szaal](https://forum.choiceofgames.com/u/Szaal)\
**Post date:** [May 20, 2018, 8:06am UTC](https://forum.choiceofgames.com/t/trying-to-create-a-power-list/39084/3 "2018-05-20T08:06:48Z")

</div>

Can ppl obtain both [healing] and [advanced healing]? Or is it one of them an upgraded version of the other?

---

<div class="post-metadata">

**Author:** ![Omegareaven](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/omegareaven/32/46502_2.png) [@Omegareaven](https://forum.choiceofgames.com/u/Omegareaven)\
**Post date:** [May 20, 2018, 9:31pm UTC](https://forum.choiceofgames.com/t/trying-to-create-a-power-list/39084/4 "2018-05-20T21:31:54Z")

</div>

Ok this is what I’m gonna try because mine def broke the game.

@Szaal You can,get both if you so choose. It’s like a power tree in which you select branching options.

---

<div class="post-metadata">

**Author:** ![Szaal](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/szaal/32/112202_2.png) [@Szaal](https://forum.choiceofgames.com/u/Szaal)\
**Post date:** [May 20, 2018, 9:42pm UTC](https://forum.choiceofgames.com/t/trying-to-create-a-power-list/39084/5 "2018-05-20T21:42:15Z")

</div>

> [@Omegareaven](#):
>
> You can,get both if you so choose.

In that case, you’ll want separate boolean vars for each of the power. IIRC, you’ve got like 5 or 6 powers in your WIP, no?

It’ll be just a matter of checking whether the player has unlocked relevant skill or not.

However, if you’re looking to spice things up by adding a skill lvl-up system, instead of boolean, use simple number (integer). Something like `*create healing 0/1/2`.

---

<div class="post-metadata">

**Author:** ![Omegareaven](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/omegareaven/32/46502_2.png) [@Omegareaven](https://forum.choiceofgames.com/u/Omegareaven)\
**Post date:** [May 20, 2018, 10:00pm UTC](https://forum.choiceofgames.com/t/trying-to-create-a-power-list/39084/6 "2018-05-20T22:00:19Z")

</div>

How would that work for skill checks?

---

<div class="post-metadata">

**Author:** ![Szaal](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/szaal/32/112202_2.png) [@Szaal](https://forum.choiceofgames.com/u/Szaal)\
**Post date:** [May 20, 2018, 10:04pm UTC](https://forum.choiceofgames.com/t/trying-to-create-a-power-list/39084/7 "2018-05-20T22:04:55Z")

</div>

Just as you would with normal boolean. But instead of `*if healing`, it’ll be `*if healing >= 1`. This way, you can make interesting fail, ok, success, and big success scenarios for your checks.

Of course if it’s not your thing, you can stick with boolean.
