Close Mark all as read
Notifications Announcements
Okay. Let’s talk about the flag.

First of all, you need to understand what is a flag? If you are an anime fan, I think you might be familiar with the term ‘raising the flag’. Like in One Piece, if Luffy said their journey is going to be smooth, he is raising a flag as right after he said that, they encountered a problem.

Copy pasting from a site called Techopedia, a flag is one or more data bits used to store binary values as specific program structure indicators. A flag is a component of a programming language's data structure.

Too technical for you?

Well, it is too technical for me. You do not have to mind it if you cannot understand it. 

Flags in CloudNovel can be anything, honestly. It can be your criteria for conditions, it can be your data keeper or it can be just a feature to mess up with.

However, the flag is an unquestionably one of the most important elements in CloudNovel. 

For this post, I will just briefly introduce you to the three types of flags.

The boolean flag is the true/false flag. This type of flag is like a switch. It has only two options, True or False. On or Off. Yes or No. Exist or Not Exist. 
It is only one or another. It never has the third option and will never be.

So, just like a switch, you can just either turn it on (true) or turn it off (false).

The integer flag is a flag with numbers. The value of this flag can either increases or decreases. Happy math-ing with this flag! However don’t worry, it will just use simple math such as adding(increasing) and subtracting(decreasing). 

The third and last type of flags is the string flag. String flag is an alphanumeric flag. What is alphanumeric? Alpha is alphabet and numeric is number. That means you can use both letters and numbers for this flag. Normally use for the customizable name.

Additionally, you can also enable auto-save for any flags you have created. By auto-saving a flag, it will remember the value of the flag even after the player closes the site so the next time they come back, they will still retain their flag values which can be useful for game currency, CG Gallery and etc.

We will learn more about flags in future posts including:

  • How to Create a CG Gallery
  • How to Set Up Game Stats
  • How to Create Customizable Name

    ...and many more.