Inputting name code?


#21

@WiReDcHiMpAnZeE, no I didn’t set it as a variable, how do you that? I try to look in the wikia but everything can be confusing at times …


#22

@irule9344, no I don’t think I did. I have pretty much got sorta the basics down. The stats are something I can’t really seem to understand and have difficulty even trying …


#23

Apparently my way of making games is different than others


#24

@AlexCosarca, oh okay, thanks. Barely caught that last comment of yours :stuck_out_tongue: I’ll check it out and see if it’ll work this time. :slight_smile:


#25

Hello

I’m new to the forum & new to Choicescript & have a similar issue. I started working on coding my story this evening & here’s where I’m up to. (feedback on the game idea would also be appreciated)

VICTORY WRESTLING FEDERATION: LORD OF THE RING

It had been a dreary day, devoid of all hope. The sort of day that just passes you by & before you know it, it’s over, gone, passed & once again you’ve done nothing with your life. Today was going to be different you had thought to yourself over breakfast & so it was to prove.

You’d decided to take the Bus home & it was whilst you were waiting in the shelter that you saw it. It was the moment you’d been waiting for, the moment your life was destined to change. It was the poster on the wall, the Victory Wrestling Federation was coming to town. Ordinarily, this wouldn’t have got you that excited, yes, you’d loved watching the Wrestlers every week when you were young but that had been a long time ago. you’d kind of outgrown it as you discovered girls.

And yet this poster had caught your eye, captured your imagination. The VWF was coming to Town & they were having tryouts for a local to get his shot at a career with the VWF & an entry into the prestigious ‘Lord of the Ring’ Tournament. The tryouts were going to be held this Friday night at the local Gymnasium, with the winner getting an entry into the knockout tournament with the Winner crowned the ‘Lord of the Ring’.

You hopped on the Bus, & you started to think about some of the big names in the Federation. The names filled you with fear & dread, but also with anticipation & excitement. Maybe you’d get to fight the big Russian Dmitri ‘Red’ Radchenko, or perhaps the former VWF Champion Charlie Horse or even the mad Australian Bruce ‘Dingo’ McGreal. It was then you realised that you’d need a name to fight under.

After thinking about it for the whole journey you eventually settled on?

*choice
#input_text name.
*finish

Any ideas as to why when I run the software I don’t get the option to type in a name.

With thanks,
AKN


#26

Its not a choice option is why


#27

Type *input_text name with no *choice


#28

I would have to agree it should look like this
#thats not my name…
*input_text name
*finish


#29

Nope, it still doesn’t like it.

Is it because there is nowhere to ‘goto’ yet


#30

Well what’s the error message?


#31

@SweetKiss There is a file in mygame called “mygame”. If you scroll down, there is a part where it says “stats.” You can put variables there like “name” or others. Just put four spaces before any variables you want to add, and then type in the actual name of the variable, along with the current status. Use this as an example.


    name: "Bob"
    ,strength: 10


#32

Oh, almost forgot. Here is a link to an article that goes into more detail about Mygame.


#33

So I’ve read the link to the mygame.js, and I’m still getting it wrong.

I have this exactly typed in the mygame section (the one in the same page as “scenes” and “index”):

// Specify the default starting stats here

stats = {
leadership: 50
,strength: 50
,text_name
};

// Specify the stats to use in debug mode

debugStats = {
leadership: 50
,strength: 50
,text_name
};

I keep receiving a script error in both the game and the stats. Can someone please correct me? (the leadership, strength and name have all four spaces)


#34

I disagree headhunter it would be
my nme is:
*input_text name
*goto_scene/finish


#35

Dont put in text_name in mygame


#36

But headhunter there woyld be no *choice and no #


#37

How is that different from what i said @WiReDcHiMpAnZeE


#38

@SweetKiss You don’t have to write “text_name” for that variable. Just writing “name” should suffice. Second, you have to write something beside it. It should look a little like this"


    name: "None"

Of course, you could replace “None” with something else if you wanted, but it doesn’t matter. As long as you have something there.

Now if you want the character to input their own name, it is simple.
Just put *input_text name where ever you want the player to enter their name.


#39

@Headhunter180

line 12: it is illegal to fall out of a *choice statement; you must *goto or *finish before the end of the indented block.

I have a *finish at the end of the indented block ???


#40

Oh okay I’ll try it ItalionStalion