Statchart problem

Unfortunately, this proves to be something beyond my capabilities of fixing. The game itself passes all the tests that I run on it. When I play through the game it is also. The problem I have is with stat chart. This is how it looks in code:

*set Race "Vampire"
*set Race "Hekan"

*stat_chart
	text Name
	text Gender
	text Race

*if Race = "Vampire"
	*stat_chart
		text Class

*if Race = "Hekan"
	*stat_chart
		text Specialization

*stat_chart
	text PP Political Power
	text Strength
	text Intelligence
	text Willpower

The problem is that when I play through the game and choose the race vampire and class aristocrat, stat chart does not follow that and gives me this:

Name: Lisbeth
Gender: Female
Race: Hekan
Specialization: unknown
Political Power: 10
Strength: 5
Intelligence: 5
Willpower: 5

Name, gender and the rest of the stats are correct, but the Race is wrong and Specialization is not even meant to appear with vampire race. I have the same issue if I choose the path of human race. The only time the stat chart is correct is when I actually choose hekans.

Any idea what I might be doing wrong?

Is what you’re doing wrong. You shouldn’t have that at the top of the stat chart because it’s over-riding any other race set with “Hekan”

@FairyGodfeather
Got rid of the *set command, but it didn’t solve the issue. Now, it give me race as false:

Name: Lisbeth
Gender: Female
Race: false
Political Power: 10
Strength: 5
Intelligence: 5
Willpower: 5

would using *temp race work? Or is there an issue with the code on the start-up?

Do you have *create race “false” anywhere?

Are you checking the stat chart after the choice where you choose your race and it’s still showing as false?

Can you copy and paste in the code from where you choose your race, etc?

1 Like

@CoelSmythe
Unfortunately *temp doesn’t sort it

@FairyGodfeather

This is at the top of startup.txt that I want to show in statchart

*create PP 0
*create Strength 0
*create Intelligence 0
*create Willpower 0
*create Gender "unknown"
*create Name "unknown"
*create Race "unknown"
*create Class "unknown"
*create Specialization "unknown"   

This is from the bit where you choose the race, along with classes for vampires and specialization for Hekans.

*choice
	#Stuff here
		Stuff here
		*set PP 5
		*set Strength 5
		*set Intelligence 5
		*set Willpower 5
		*set Race "Vampire"
		*choice
			#Stuff here
				*set PP 10
				*set Intelligence 5
				*set Class "Aristocrat"
				*goto gender
			#Stuff here
				*set Strength 10
				*set Intelligence 5
				*set Class "Soldier"
				*goto gender
			#Stuff here
				*set Intelligence 5
				*set Class "Common_individual"
				*goto gender
	#Stuff here
		Stuff here
		*set Race "Human"
		*choice
			#Stuff here
				*set Class "dead"
				*goto_scene death
			#Stuff here
				*set Willpower 5
				*goto gender
	#Stuff here
		Stuff here
		*set Intelligence 10
		*set Race "Hekan"
		*choice
			#Stuff here
				*set Strength 10
				*set Specialization "Manipulation"
				*goto gender
			#Stuff here
				*set Intelligence 10
				*set Specialization "Illusion"
				*goto gender
			#Stuff here
				*set Willpower 10
				*set Specialization "Life Forcing"
				*goto gender

If you look at the stat chart after you’ve set your race to Vampire do you still have the same problem?

@FairyGodfeather
Actually, I think I might have found a glitch. I always play the game to the end when the stat chart shows as last part before you click next to play again. On that screen the stats are wrong, but if I look at the stats during the game, they are correct. I might have just caused this humbug for nothing >.< But how is that possible anyway?

I just thought of something that might work. *if (race_vampire=true) you’d have to set up some of your code a little different but having separate race_hekan false race_human false etcs. might work out

Do you have any sort of *set race right before the last stat chart? Check over your code again, using find to look at all the instances where you set the race.

@CoelSmythe
How much of an overhaul are we talking?

@FairyGodfeather
No, there is no *set race right before the last stat chart.

Do you have a link to the entire file? I can have a look over it to see the problem.It is likely something very simple, a stray *set race in the wrong place that you might be overlooking. Are you certain that the only three set races are those in that choice tree you pasted here, and that *create race is right at the top of the startup file?

I’d suggest against doing what @CoelSmythe’s suggesting. You don’t need to.

@FairyGodfeather
Now, you might need to walk me through how to get a link to the entire file as I have no clue how to get that xD But if you wouldn’t mind doing that, that would be great and I be so grateful!
And yeah, I am certain that what I pasted here is the only choice tree where you can choose your race and the *create race command is right at the top of start up.

Go with what @FairyGodfeather is saying.

1 Like

@CoelSmythe
But thanks for trying to help too :smile:

1 Like

If you’d rather not email if you’ve a dropbox account upload it there, or use a pastebin and just copy/paste in there.

@FairyGodfeather

Dropbox is probably the best idea.

Here is the link for the statchart:

And here is the link for startup:

Thank you so much again! I have been trying to figure this out for the past night without any success. I guess it is like you say and I am just missing something small. I really appreciate your help, thank you!

I’d suggest against capitalizing your variable names, but that’s just a stylistic choice really. As long as you’re consistent it shouldn’t matter.

I can’t see anything wrong on that page. Do you have links to those future scene files?

@FairyGodfeather
I capitalized them so that they’d look better on stat screen. So original none of that was capitilized.

Anyways, I don’t, not yet, as these files are empty so far.

Actually apart from the death scene…if you want a link for that one, it’s here: