[CSIDE] The ChoiceScript IDE (v1.3.0 Now Available — 18/06/2019)

In my project, I have a scene that has one line of code in the scene: “*ending”; however, I am receiving the following error when I run quicktest:

chapter4
executing
QUICKTEST FAILED
ERROR: couldn’t open .txt

Do you know what could be causing this? (Randomtest works though)

Edit: And I have an error for this: *selectable_if (x > 5) # …

RANDOMTEST FAILED: Error: scene line 16: Non-existent command ‘selectable_if’

Triple check the file names and what you have listed in the code for call outs and gotos.

No, but then I also doubt these are CSIDE related issues. Have you tried the Randomtest.html/Quicktest.html that come in the ChoiceScript zip? If they pass, and CSIDE fails, then it’s probably an issue with CSIDE. As it stands, this sounds more like a ChoiceScript quirk to me.

Hi.
I’m having a problem with CSIDE recognising the scenes in my project.
The scenes are clearly named in the *scenes_list in the startup file, but im getting the error:
Couldn’t load scene ‘name’ The file doesn’t exist

So, I moved my games out of the master folder, deleted the ChoiceScript folder, unzipped it from my backup master zip file, moved the one game on which I am working into the folder, and tried again. I still had the same problem, so I tried the Randomtest.html and Quicktest.html. When I did the randomtest, it asked me to upload the files and check off a few options. After pressing the “Start Randomtest” button, the screen went blank. It didn’t happen. When I did the Quicktest.html, it just pulled up a screen with the words “Loading…” without it ever loading anything.

Hi.
I’m having a problem with CSIDE recognising the scenes in my project.
The scenes are clearly named in the *scenes_list in the startup file, but im getting the error:
Couldn’t load scene ‘name’ The file doesn’t exist

Are the scenes all in lowercase? They won’t work in uppercase. All scenes and variables must be written in lowercase.

Yeah, they’re in lower case @RileyRock-pen

If you could both zip up your projects and send them to me via PM, I can investigate further.

1 Like

Tried to send you the Zip file as a PM on here, but it doesn’t accept zip files…
I might be doing something wrong so :confused:

Yeah. You’ll have to use some other service: Dropbox, Google drive etc.

image

This is new? I got this when trying to run a project in CSIDE. I ran the exact same files last night, and they were fine. I uploaded the same files to Dashingdon and they are running just fine. It’s strange to me because I’m not getting any more of a detailed error message, or anything. I will check the files in the file browser, just in case.

That is strange indeed. This is in the run tab? Could you try closing and re-opening the project (save first!)?

Restarting CSIDE fixed it, but before that I couldn’t run or test the game. Now it’s fine. I’m scratching my head, I’ve never run into something like this before.

2 Likes

If you run in to it again, see if you can retrace your ‘steps’, and let me know how to reproduce it.

2 Likes

@CJW Can you establish a command for *sm_init save plugin for Dashingdon?

Hi, I am having a nightmare!

Through the help of the forum I have been able to get my game written and all along I have been testing it with choicescript ide
It is now at pending asset stage but failing quicktest over and over. I have just found this is because whilst the code passes quicktest ide it does not pass the inbuilt quicktest . bat file

aside from the complications of running tests on an old version of firefox I am struggling to fix the new issues.

Would love help on why this is happening?

line 120 is #refuse , there is a lot of code “connected” so I put all that in for context

I’m having trouble with Error: spider line 120: It is illegal to fall out of a *choice statement; you must *goto or *finish before the end of the indented block.

My code looks like this:

"Seems straight foward enough," says Sir Malcolm. "Go to the cave, kill the spider, get our stuff back." 
   	*choice
   		#Accept
   			*label accept
   			You agree to the deal and she smiles widely. Turning to the group she speaks and they react with happiness. With a new found sense of comradeship you are reunited with your equipment and provided with some torches. You are pointed to a path that will lead you to the cave and you set off.
   			
   			You haven’t traveled down the path very far before you notice the weird quietness, very unlike the normally raucous jungle. Some of the foliage on the side of the path is draped with whispery cobwebs and these become thicker and more prevalent until everything around you is grey. The entrance to the cave is unmistakable, a black hole at the epicenter of the depressing webs. You light your torches and enter. The tunnels are circular and you have to crouch slightly to proceed. The walls are smooth, it seems as if they have been bored into the ground. The tunnel splits into three.
   			*choice
   				#North
   					The passage is just big enough for you to walk down without crouching but the wispy cobwebs cling to your clothes and stick to your hair. Every so often you stop to pull the webbing off of you in disgust. You notice that there is a mural of some kind on the passage wall ahead, just visible under the ever present covering of choking web. 
   					*choice
   						#Investigate
   							The webbing sticks everywhere so it takes some while to remove it. The mural is etched into the stone with incredibly fine detail, it looks more like a technical blueprint than a piece of art. It depicts a nightmare world of arachnids and their human food source. Sickened you turn away.
   							*goto drytunnel
   						#Ignore
   							*label drytunnel
   							You continue down the dry tunnel until you reach a cobweb that blocks progress. As you are thinking about how to proceed Lady Jane steps forward and touches her torch to the gossamer mesh. The flames consume it greedily and within a moment the way forward is clear.
   							
   							You step into a large underground cavern. Webbing covers every wall like soft white drapes. Shapes hang from the ceiling, gently swaying stalactites. In the middle of the cavern sits an immense black spider. It’s eight red eyes twinkle like rubies. You shift your foot slightly and the spider adjusts itself fractionally. Then it moves towards you confidently.
   							
   							"It's more scared of us than we are of it!" says Sir Malcolm.
   							
   							You are amused but not convinced.
   						
   							You must fight the:
   							
   							[b]Giant Spider[/b]
   						
   							[b]Skill 8, Stamina 10[/b]
   							
   							*label giantspider_fight
   							*choice
   								#Fight
   									*goto roll_dice_loop1
   								*if (gun = true) #Use gun
   									*if (bullets_number > 0)
   										*goto set_bullet_damage1
   									*if (bullets_number = 0)
   										*goto click1
   								*if (instant_win = true) #Insta Win
   									*goto win1
   								*if (knuckle = true) #Use Knuckle-Duster
   									"Time to send you back up the drainpipe!"
   									*goto roll_dice_loopk1
   							
   				#Northwest
   					The passage gets narrower and you crouch more and more. Just as you start to think about turning back the passage widens again and opens out into small chamber. The air is dry and dusty and you feel as if the atmosphere is sucking all the moisture out of you. Something is moving in the shadows. A dark shape scuttles towards you. The spiders body is the size of a dinner plate and it’s long legs click on the ground repellently.
   					You must fight the:
   					
   					[b]Somewhat Giant Spider[/b]
   					
   					[b]Skill 7, Stamina 6[/b]
   					
   					*label spider_fight
   					*choice
   						#Fight
   							*goto roll_dice_loop
   						*if (gun = true) # Use gun
   							*if (bullets_number > 0)
   								*goto set_bullet_damage
   							*if (bullets_number = 0)
   								*goto click
   						*if (instant_win = true) #Insta Win
   							*goto win
   						*if (knuckle = true) #Use Knuckle-Duster
   							"This is a step up from a rolled newspaper!"
   							*goto roll_dice_loopk
   				#Northeast
   					You follow the passage for a while, the constant stooping makes your back ache. The walls of the tunnel are covered in white webs that billow out and caress you as you walk past. 
   					
   					"These things remind me of shrouds," says Sir Malcolm, unhelpfully. 
   					
   					The tunnel widens out a little and there is an alcove on the right. In the alcove is a figure, they are covered in webbing like a mummy. 
   					*choice
   						#Investigate
   							You pull the webbing from the figure and it comes away reluctantly in sticky clumps revealing a grey, sallow face underneath. There are two puncture wounds in his neck. As you examine the wound his eyelids flutter but he does not awake. Lady Jane places her fingers gently on his neck and then places her ear to his mouth 
   							
   							"He’s alive, but barely. I don’t think there is anything we can do for him."
   							*goto drytunnel
   															
   						#Ignore
   							*goto drytunnel
   					
   					
   		#Refuse
   			*label refuse
   			You refuse the deal and she frowns deeply. Turning to the group she speaks and they react sadly. Your equipment and inventory is returned, except any provisions you may have.
   			*set provisions false
   			*set provisions_number 0
   			
   			She points to a path leading away from their settlement.
   			
   			*label lushgreen
   			You follow a track through lush green grass that sways gently in the breeze.
   			*if (stamina = max_stamina)
   				*goto lushgreen1
   			*elseif (provisions = false)
   				*goto lushgreen1
   			*else
   				*goto choice1
   			*label choice1
   			*choice
   				*if (provisions = true) #Eat Provisions
   					*if (provisions_number > 0)
   						*gosub_scene eatprovisions
   						*goto lushgreen1
   					*if (provisions_number = 0)
   						*gosub_scene noprovisions
   						*goto lushgreen1
   				*if (provisions = true) #Don't Eat Provisions
   					*goto lushgreen1
   				*if (provisions = false) #Follow the track
   					*goto lushgreen1				
   			*label lushgreen1
   			Insects buzz and a brightly coloured dragonfly hovers for a moment before zipping off. Past the grass, giant ferns mark the edge of the dark and mysterious jungle. The path starts to widen out and the ground becomes softer. You reach a wide, shallow ford that runs across your path. Gently flowing water runs over sleek flat stones. The other side is about one thousand yards away. Sir Malcolm starts to take his boots off.
   			
   			"No need to get my boots wet," he says and with the laces tied together he hangs them round his neck. 
   			
   			This seems like a good idea so you and Lady Jane follow suit and start crossing. The cool, bubbling water caresses your tired feet wonderfully. When you are halfway across the riverbed starts to shift in front of you. Arising under a a shower of mud and rocks a giant crab towers above you, its claws snapping in anticipation! It advances. The water rises.
   			You must fight the:
   			
   			[b]Giant Crab[/b]
   			
   			[b]Skill 6, Stamina 8[/b]
   			
   			*label crab_fight
   			*choice
   				#Fight
   					*goto roll_dice_loop3
   				*if (gun = true) #Use gun
   					*if (bullets_number > 0)
   						*goto set_bullet_damage3
   					*if (bullets_number = 0)
   						*goto click3
   				*if (instant_win = true) #Insta Win
   					*goto win3
   				*if (knuckle = true) #Use Knuckle-Duster
   					"Time for the lobster claws"
   					
   					*goto roll_dice_loopk3



Example
*commend
    Indent

Well, first of all I didn’t know you could use indented labels. And second I think that it could be a problem of not properly using the *if *else command right here

*if (bullets_number > 0)
  *goto set_bullet_damage3
*if (bullets_number = 0)
  *goto click3

(line 131 to 134)

You have empty lines (83, 84). Try removing those lines.

   				#Northeast
   					You follow the passage for a while, the constant stooping makes your back ache. The walls of the tunnel are covered in white webs that billow out and caress you as you walk past. 
   					
   					"These things remind me of shrouds," says Sir Malcolm, unhelpfully. 
   					
   					The tunnel widens out a little and there is an alcove on the right. In the alcove is a figure, they are covered in webbing like a mummy. 
   					*choice
   						#Investigate
   							You pull the webbing from the figure and it comes away reluctantly in sticky clumps revealing a grey, sallow face underneath. There are two puncture wounds in his neck. As you examine the wound his eyelids flutter but he does not awake. Lady Jane places her fingers gently on his neck and then places her ear to his mouth 
   							
   							"He’s alive, but barely. I don’t think there is anything we can do for him."
   							*goto drytunnel
   															
   						#Ignore
   							*goto drytunnel
   					!!!
   					!!!
   		#Refuse
   			*label refuse
   			You refuse the deal and she frowns deeply. Turning to the group she speaks and they react sadly. Your equipment and inventory is returned, except any provisions you may have.
   			*set provisions false
   			*set provisions_number 0
   			
   			She points to a path leading away from their settlement.
1 Like

many thanks, these lines of code are in all the scenes and they do pass quicktest
I can try changing to see if that helps would I change the second if to elseif?

Hi Szaal!

Many thanks, I removed these and still no change