[Open Sourced] Flag Testing Service

Flag Testing Service

Hey all!
Today I’d like to share with you a module I recently created named “EchosTestingService” to allow for easily testing features in studio without publishing them to a live-game.

What are ‘Flags’?

In computing, a flag is value that acts as a signal for a function or process. In short, they’re used to decide the next step of a program. Roblox also makes use of flags which they typically use to enable features in studio which aren’t yet accessible through the client / live game server.

What can it do and how do I use it?

This module can be used to create a flag for unreleased features in your live-game that you wish to test easily in studio without pushing them to the actual game. For example, imagine you have a shop of 100 different hats but there’s one particular grey hat you don’t wish for users to see just yet. Your code would look something like this:

image

The flags are structured as shown below:

image

If you ask the service to find a flag that doesn’t exist, it’ll return false.

The Model

You can find the model here:

I’ll be updating this module with useful features as they come to mind.
All suggestions are welcome :slightly_smiling_face:

Everything is documented in the module!!!

Thanks, as said before, suggestions are always welcome!


Side Note - A Potential Cinematic cutscene editor plugin

I am a univeristy undergraduate beginning to work on my final year dissertation in games technology and I’m in the middle of deciding to use Roblox as the IDE of my choice to develop an open sourced cinematic cutscene editor, or some other potential project ideas in other IDEs.

I have chosen a cinematic cutscene editor as (please correct me if i’m wrong), I don’t believe there’s no full cinematic cutscene editors on Roblox that can control as much as possible like animation applications such as blender and 3dsmax.

I’m just curious, and it’ll help me a great deal with my dissertation choice if I could get a response from anyone who’s interested.

  • Interested
  • Not Interested

0 voters

Thanks!

20 Likes

What stops developers from just checking RunService:IsStudio() over using your module then?

3 Likes

For starters, if you wanted to release the hat, you’d have to remove the “RunService:IsStudio()” case from your code which takes time, with this method all you have to do is set a bool value to true.

Secondly, at a base level, nothing stops developers from using that method instead, but the module provides basic flag tables that you’d have to manually check for yourself every time you want to develop a feature that requires a list of flags.

4 Likes

Based off the title, I was expecting a much more Fast Flag type system that people would be able to use in game.

5 Likes

Wouldn’t it have been much simpler to just have a ModuleScript containing all of your flags in a returned table to avoid this entire service and the use of ValueObjects?

2 Likes

Not really. Modules are just scripts that run once when required and return exactly one value. If that value is just a table without any metamethods blocking __newindex, you can change any value contained in it under an index. You could just add it to _G once required and type _G.FlagTestingService.FlagList[flagname] = newvalue in the console. You can also make an event system by creating unparented BindableEvents.

The thing I don’t exactly understand is the use of this service. As far as I can see, it can only return a boolean, so applying some kind of a numerical setting such as a render distance for testing is out of question (fast flags in Roblox work like this).

Unless I am mistaken, the only 2 ways to actually get a .Changed event is either by iterating through :GetFlags() which is an array, so you can’t index the flag by its name, or by avoiding the entire service and just indexing the module’s children.

This module lacks the basic requirements to be practical for use as a dynamic flag system (events) and blocks the players from applying anything but booleans.

4 Likes