Update RingRayLib - raylib.c - Add Function : const char *TextJoin(const char **textList, int count, const char *delimiter)
@@ -4428,6 +4428,28 @@ RING_FUNC(ring_TextInsert)
RING_API_RETSTRING(TextInsert(RING_API_GETSTRING(1),RING_API_GETSTRING(2), (int ) RING_API_GETNUMBER(3)));
}
+
+RING_FUNC(ring_TextJoin)
+{
+ if ( RING_API_PARACOUNT != 3 ) {
+ RING_API_ERROR(RING_API_MISS3PARA);
+ return ;
+ }
+ if ( ! RING_API_ISPOINTER(1) ) {
+ RING_API_ERROR(RING_API_BADPARATYPE);
+ return ;
+ }
+ if ( ! RING_API_ISNUMBER(2) ) {
+ RING_API_ERROR(RING_API_BADPARATYPE);
+ return ;
+ }
+ if ( ! RING_API_ISSTRING(3) ) {
+ RING_API_ERROR(RING_API_BADPARATYPE);
+ return ;
+ }
+ RING_API_RETSTRING(TextJoin((char **) RING_API_GETCPOINTER2POINTER(1,"char"), (int ) RING_API_GETNUMBER(2),RING_API_GETSTRING(3)));
+}
+
RING_API void ringlib_init(RingState *pRingState)
{
ring_vm_funcregister("initwindow",ring_InitWindow);
@@ -4682,4 +4704,5 @@ RING_API void ringlib_init(RingState *pRingState)
ring_vm_funcregister("textsubtext",ring_TextSubtext);
ring_vm_funcregister("textreplace",ring_TextReplace);
ring_vm_funcregister("textinsert",ring_TextInsert);
+ ring_vm_funcregister("textjoin",ring_TextJoin);
}
