Function: CharAt

Where i can locate ‘CharAt’ , in the openbullet version 2, i searched in all functions, and i didnt located it

2022-04-05 19_50_20

You can use C# directly in OB2 so just do

  value = "test"
  => VAR @str

string firstLetter = str[0].ToString();

Where 0 is the index

I wanna to use the string ‘code’ which i will charat it.
So where i will place the ‘code’

sir this script cannot be working with C#, i clicked modify he tell me you will not able to use stacker anymore, i clicked yes and i added your code i got an error

Not working sir

and here is it a config using c# , it makes problem
i convert it to C# but it makes problems, and also i tried in a normal config, because this code you give it to me , it works in a normal config, not c# , but also the same problem

also this not working

You can write it in the LoliCode tab, you can write C# in LoliCode (it is even written at the bottom of the editor). You don’t need to convert the config to C#.

Just write this in the LoliCode tab

  value = "test"
  => VAR @str

string letter = str[code].ToString();
LOG $"Extracted the letter {letter}"

If it says that code is a string and should be an int then please use the constant int block to convert code to int first.

If you really cannot make this work by yourself then I guess just open an issue and I will make a block for it.

its the same problem sir

as you tell me he tell me to convert string to int, but i dont know how to make it !
please make a block easy named (CharAt) and let we use it normally like in the old version

2022-04-06 20_15_16

I did your issue, it will be in the next version of OB2

please how much it still to make update ?

No clue, it could be 1 week or 1 month it depends on how much time I have on my hands

Aa ok thanks bro.
But i need it very quick in my config, can i send you it quickly and add to me the string as you told me in the older message ?

Sorry I cannot do that, if you cannot figure out how to do it with the examples that I gave you then just wait for the patch or ask someone else

still didnt updated ?