HELP c: Is there a better way to test your game in CScript IDE?

Hello it’s me again! Upsi
I started learning CScript like a week ago maybe and I am using the ChoiceScript IDE.

Is there a better way to playtest your games? Because as of right now, I always have to start from the beginning and click myself through to the point where I attempted to fix an error in either my code, the formatting etc. It’s just really annoying and when I actually start to make my game that seems an impossible way to test if you fixed your errors.
I’m just doing exercises right now to learn it in 3 scene files and it’s already annoying as hell.

Does anyone know a better way to do that in the CScript IDE?

Right click on the project name, hover over Test Project and use the Quicktest and Randomtest feature. Not %100 accurate, but a pretty good way to find easy mistakes.

I had a quick look at both.
The Quicktest confuses me a lot, but the random test I can get behind. I’m not sure where the difference is tho? The Quicktest looks like it makes 1 Walkthrough and the Randomtest does like what it looks like all of the possible ones?

I take it there is no way to kinda have a save system and just look at that one scene you’re working on?

Thank you by the way!

You can manually code in short-cuts, but it’s a lot of work.

this likely isn’t the best way to do it - i’m not really experienced in CSIDE - but i tend to make use of the *goto and *label commands when i’m testing and writing

for example, i’ll have a *goto command at the top of the file, and then a *label named [whatever you want] right before any of the text that i’m looking to edit

i think the only big downside is that you will need to set any specific variables that you’re testing or whatever after the playtest label. basically after the “*label playtest”, set specific variables that are either important or ones you’re testing in the scene. this isn’t needed if you have default variables already set in the startup.txt that you like/need and if you use the “*goto scene playtest” at the end of startup.txt. or if you don’t need any of the variables set at that point

for example starting from the very top:
*goto playtest

[any words or code you want to skip]

*label playtest
*set flag true
*set stat 50
*set hair “red”

code/writing im working on
choices here

(i’m also too lazy to really get out of bed to double check of this is all right :sweat_smile: hopefully this still helps somewhat)

CJW created a save plugin which is super-useful. However (and very frustratingly) it isn’t usable within CSIDE, even though CSIDE was also created by the same user!

However, it is compatible with Dashingdon, the website on which ChoiceScript demos are usually hosted. You need to add the following bit of code to your startup file:

*sm_init <<your game name>> <<num of saveslots (preferably 1 - 6)>>

Then upload your game to Dashingdon and tick the checkbox that says “enable save system”, and you’ll have a version of your game with a fully-implemented save system ready to go!

What I do is write the game in CSide, then I upload the files to a private version of the game on Dashingdon which nobody else can access, with the save code added, and use that for my own manual testing.

3 Likes

CSIDE has a command line, you can input commands to go to specific parts of the game you want to test.

image
Just click the >_ to make it pop up

3 Likes

Thats super smart thank you so much! <3

That was what I was looking for I think

1 Like

What are the commands? I’m sure how to use this ^^’’

Thank you for helping! I will give it a go after tonight because I’m sleepy xD

1 Like

Basically normal choicescript commands ("*goto, *set, *goto_scene etc.) But if you type in *help, it should give you a full list.

As mentioned above, there are two options here (in CSIDE): save mods, or the ChoiceScript console.

Save mods will eventually be supported in CSIDE, but aren’t inherently good for testing because every time you change the game, you’re risking invalidating your saves.

The ChoiceScript console is better, if a little harder to grasp. This will allow you to interface with your game in real-time. There’s documentation on this feature (under advanced topics) in CSIDE itself. You just have to be aware that by using the console you can trigger situations that won’t occur for a player, and that can be disconcerting.

8 Likes