Trouble displaying results of if statements


#1

So I have a part in the game where the palyer could fail a test if they dont make the right choice. The problem is the text if they fail the test will not appear. for some reason it was working fine and now it is not. Here is the Code.

*set Specialist 50
*set Stealth 60
*set Technology 70

Your first test is a somewhat basic routine. A mock enemy base is occupied by fellow candidates all of them equipped with state of the art
comm systems, heart beat monitors, and fully automatic non leathal assault rifles

With this in mind you remember you'll also have a team of your own to back you up on this enrty mission. If you command you're team properly you'll be able to get
through the test with ease and your skills as a feild coordinator will improve. On the other hand you could support your team using stealth which could help you with future 
stealth operations; although, this would mean your missing out on a chance to becom a better feild coordinator. Then theres the tech route. If you play your cards right
you will be able to get rid of that staete of the art tech your targets are outfitted with. Whichever route you choose, remember this is one of many tests so any increases
in skill will be minimal for the most part and none of your other skills will decrease, at least this time they won't.
*page_break
Whats your strong suit?
 *choice
 #Im a leader at heart.  
   *set Specialist %- 20
   *goto action
#Stealth is how I've always handled situations such as this.
  *set Stealth %+30 
  *goto action
#I can use my own gadgets to aid my team, after all no one knows inflitration tech like I do.
  *set Technology %+15
  *goto action

*label action
 With this in mind, how are you going to tackle this situation?
*choice
 #I'll task my team with different sub-missions based on their ablities and skills, that way I can increase my skills as feild coordinator.
*if Specialist  < 50
  You utilize every aspect of you team deafeating the enemy swiftly. Your skill as a feild coordinator increases and your team seems greatful for your
  assistance.
*set Specialist %-20
*finish 
*else
  You defeat the enenmy alothough your team doesn't walk away unharmed. You ended up relaying vague orders to your team and ultimatley end up taking out most
  of the enemy force single handely.
*finish
#I'll use stealth to help my team and avoid upfrom confrontation. I can also observe them from the shadows and see how they cary themselves during combat.
*if Stealth > 60
  You stick to the shadows using your tech to shroud yourself from security monitors. You also gain more knowladge about your current teamates that could
  come in handy in the future.
*set Specialist %-20
*finish  
*else
  You are spotted and end up comprimising your whole team. You've learned from your failure that you should stick to what you know when your team is counting on you 
  to maintain the integrity of the mission.
*finish
#My technological finesse will come in handy to disable the opposing candidates gear. This way they'll be defensless.
*if Technology > 70
  You use your array of gadgets to disable enemy defenses and comms. 
  Now that they are blind you and your team take each enemy candidate out with ease.
*set Technology %+10
*finish  
*else
  You've underestimated the enemies gear and they end up ambushing you and your team before you can carry out your own ambush.
  Test failed. Next time sitck to your guns when you're dealing with multiple targets.
*finish

#2

I’m no coder so unfortunately I can’t help you. For future reference though, questions like these should go in the choicescript help section.


#3
  1. Strong recommendation that you switch to tabs are multiple spaces per indent (for just this reason, I can barely tell one line from the next).

  2. Is that a straight copy/paste? Because that looks like it should be crashing #Im a leader at heart. is indented once, but the line immediately following it is not indented. That shouldn’t be at all functional.


#5

Thanks for the help I wasn’t sure were to post this to. I’m a newbie :sweat_smile:


#6

Fixed the formating. It goth rid of the indents when i pasted it.


#7

Don’t worry about forum categories. They’re an easy fix.

It’s probably an indentation problem.

Are your choices indented correctly? Like

With this in mind, how are you going to tackle this situation?

*choice
	#I'll task my team with different sub-missions based on their ablities and skills, that way I can increase my skills as feild coordinator.
		*if Specialist  < 50
			You utilize every aspect of you team deafeating the enemy swiftly. Your skill as a feild coordinator increases and your team seems greatful for your
  assistance.
			*set Specialist %-20
			*finish 
		*else
			You defeat the enenmy alothough your team doesn't walk away unharmed. You ended up relaying vague orders to your team and ultimatley end up taking out most  of the enemy force single handely.
			*finish

#8

thanks i was using spaces instead of indents so your advice worked :thumbsup: