# Inventory help!

**URL:** <https://forum.choiceofgames.com/t/inventory-help/15679>\
**Category:** ChoiceScript Help\
**Created:** [March 15, 2016, 12:37am UTC](https://forum.choiceofgames.com/t/inventory-help/15679 "2016-03-15T00:37:31Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mydoghasfleas](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/mydoghasfleas/32/110504_2.png) [@Mydoghasfleas](https://forum.choiceofgames.com/u/Mydoghasfleas)\
**Post date:** [March 15, 2016, 12:37am UTC](https://forum.choiceofgames.com/t/inventory-help/15679/1 "2016-03-15T00:37:31Z")

</div>

Maybe someone here can help me figure this out.

I am setting up an inventory system, and am having problems with inventory consisting of two or more words. I can get it to work using underscores, but then on the stat page it pops up with underscores separating and that is kind of ugly. I have tried several methods but can’t seem to get around the issue.

(Before people ask “why haven’t you used the search button to figure this out?” Yes…Yes I have. I have looked all over the forum, the Wika page, and a few other sources before posting this. So please don’t patronize me.)

Anyway, just trying to make my stat page look nice!

---

<div class="post-metadata">

**Author:** ![Nemeean\_lion](https://avatars.discourse-cdn.com/v4/letter/n/7cd45c/32.png) [@Nemeean\_lion](https://forum.choiceofgames.com/u/Nemeean_lion)\
**Post date:** [March 15, 2016, 12:55am UTC](https://forum.choiceofgames.com/t/inventory-help/15679/3 "2016-03-15T00:55:14Z")

</div>

I don’t use choicescript, but I’m pretty sure that you need to use string variables for this.

Here’s a forum post I found through a quick search of “string variable” and that seems to explain how you add words with spaces in a string variable.

Hope it helps!

> [@Adding strings to variables](https://forum.choiceofgames.com/t/adding-strings-to-variables/803):
>
> In my game you can gain abilities so, naturally, I tried adding a string to my abilities variable like so: \*set abilities +",Life blast". Doesn’t work so how would I do this?

---

<div class="post-metadata">

**Author:** ![Mydoghasfleas](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/mydoghasfleas/32/110504_2.png) [@Mydoghasfleas](https://forum.choiceofgames.com/u/Mydoghasfleas)\
**Post date:** [March 15, 2016, 1:00am UTC](https://forum.choiceofgames.com/t/inventory-help/15679/4 "2016-03-15T01:00:04Z")

</div>

Thanks, I have already seen this. I even read through the wiki page. Still not understanding what I need to change.

---

<div class="post-metadata">

**Author:** ![Nemeean\_lion](https://avatars.discourse-cdn.com/v4/letter/n/7cd45c/32.png) [@Nemeean\_lion](https://forum.choiceofgames.com/u/Nemeean_lion)\
**Post date:** [March 15, 2016, 1:03am UTC](https://forum.choiceofgames.com/t/inventory-help/15679/5 "2016-03-15T01:03:44Z")

</div>

Try pasting a code snippet here, to illustrate your problem. Maybe someone will be able to identify the problem in your code.

---

<div class="post-metadata">

**Author:** ![CJW](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/cjw/32/111787_2.png) [@CJW](https://forum.choiceofgames.com/u/CJW)\
**Post date:** [March 15, 2016, 1:04am UTC](https://forum.choiceofgames.com/t/inventory-help/15679/6 "2016-03-15T01:04:07Z")

</div>

If the snippet is small enough, posting your code is always a good start^.

---

<div class="post-metadata">

**Author:** ![Silverstone](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/silverstone/32/9901_2.png) [@Silverstone](https://forum.choiceofgames.com/u/Silverstone)\
**Post date:** [March 15, 2016, 1:08am UTC](https://forum.choiceofgames.com/t/inventory-help/15679/8 "2016-03-15T01:08:32Z")

</div>

So, do you mean you just want it to display however you’ve written it? Have a look at this link below, hopefully this answers what you were trying to achieve. If not that post, read the one under it.

[Inventory Code Help](https://forum.choiceofgames.com/t/inventory-code-help/9253/2)

---

<div class="post-metadata">

**Author:** ![Mydoghasfleas](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/mydoghasfleas/32/110504_2.png) [@Mydoghasfleas](https://forum.choiceofgames.com/u/Mydoghasfleas)\
**Post date:** [March 15, 2016, 1:09am UTC](https://forum.choiceofgames.com/t/inventory-help/15679/9 "2016-03-15T01:09:47Z")

</div>

On the startup page

\*create Magical\_Aura false

On the stat page

\*temp ability “”  
\*temp comma false  
\*if (Magical\_Aura)  
\*set ability &“Magical\_Aura”  
\*set comma true  
Ability: ${Ability}

I can get this to work with underscores, but I would like to make this two words. Not sure where to go from here. Been at it for a while.

---

<div class="post-metadata">

**Author:** ![Mydoghasfleas](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/mydoghasfleas/32/110504_2.png) [@Mydoghasfleas](https://forum.choiceofgames.com/u/Mydoghasfleas)\
**Post date:** [March 15, 2016, 1:11am UTC](https://forum.choiceofgames.com/t/inventory-help/15679/10 "2016-03-15T01:11:26Z")

</div>

Thanks a bunch!! You are my hero 😊

---

<div class="post-metadata">

**Author:** ![Silverstone](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/silverstone/32/9901_2.png) [@Silverstone](https://forum.choiceofgames.com/u/Silverstone)\
**Post date:** [March 15, 2016, 1:12am UTC](https://forum.choiceofgames.com/t/inventory-help/15679/11 "2016-03-15T01:12:25Z")

</div>

No worries, I have that one book marked myself. It’s a good reference 😄
