• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

OFFICIAL 2022.1100 Beta Releases Thread

Status
Not open for further replies.

Dan

GameMaker Staff
GameMaker Dev.
This topic is for the discussion of issues relating to this update of GameMaker. However, this does not replace our normal bug reporting system and you should report all bugs as normal using https://contact.gamemaker.io/contact-us

As ever, PLEASE check the Required SDKs FAQ before/during updating and ensure your antivirus/OS permissions are correct by checking User Permissions and Internet Access Required by GameMaker before you submit any bug reports or post issues here.

You should post here if:
  • Something has changed between the previous version and this one, breaking your game (i.e.: code that worked previously now does not)
  • Something reported as fixed in the release notes is not actually fixed
  • You are having IDE or system issues related to something new in this update
  • You are having issues with new features introduced in this version
  • You are having issues updating to this version
  • Everything works and you want to tell us we are great (seriously, let us know if it all works correctly for you)
When reporting issues to the Helpdesk, please try to add as much information as possible, for example:
  • If the issue is with the IDE, then please give a screenshot if you can to help illustrate the problem and always attach the "ui.log" file found via the "Open Log in ..." Help menu command inside GameMaker
  • If it is a code issue, then link to or attach a YYZ showing the most basic project possible which exhibits the behaviour
  • If it is a system issue (like compiling to a specific target or running on a device) then please always include the compiler log we ask for (it's genuinely very important!) and provide details of the machine being used as well as the software versions involved
Again: posting a comment in these release threads is not a replacement for filing a bug!

Release Notes

Runtime Release Notes



Current Release - IDE v2022.1100.0.246 Runtime v2022.1100.0.258 (Nov 22, 2022)


This one is a small stability bug-fix update and mostly on the IDE side, so see the release notes for the full details.

And, speaking of release notes, we need to restore the download link on that page above, but for those who have been waiting so patiently... https://gms.yoyogames.com/GameMaker-Beta-2022.1100.0.246.deb


Beta 6 - IDE v2022.1100.0.244 Runtime v2022.1100.0.256 (Nov 15, 2022)

Adds a handful more layer effects for use in your rooms, a compiler fix for if you're using Android API 33 and you have Lint-checking enabled, and an important fix for SSO users to enable them to go offline. As ever, see the full notes above for all details.


Betas 5-3 are missing here (apologies!), but their info can be found elsewhere in this thread.


Beta 2 - IDE v2022.1100.0.230 Runtime v2022.1100.0.214 (Nov 1, 2022)


Introduces lovely new functionality for adding audio effects in-game; pasting into the image editor as a new layer (rather than as a brush); fixes for when trying to use GM offline if you had previously signed-in using SSO; some new Feather rules and a good selection of Feather bugs fixed; and a number of other fixes as well.


Original Release - IDE v2022.1100.0.227 Runtime v2022.1100.0.210 (Oct 20, 2022)

This is a very early look at November’s version, so we can concentrate on the LTS version for October and still introduce some of the newer November (2022.11) changes for your feedback sooner, as you will see there are some quite important changes as soon as you launch this new version!

The 2022.11/1100 release brings the ability for you to pick which bits of your runtimes you wish to download (allowing for smaller install sizes and less time downloading after a new install/update) and a number of other general fixes. It's linked-to in the release notes already, but you can read all about that new dialog here.

On the runtimes side, there are already a number of bug fixes and a selection of new functions, such as for arrays and Spine skeleton attachments - with more to come in future betas.


A reminder that there is no matching Ubuntu IDE for any version earlier than Beta 7 above. (The Ubuntu IDE before that one is from March, so please don't use that nowdays, get the new one I linked higher up...)

 
Last edited:

malonso

Member
Thanks, I'm traveling as digital nomad, I just have my laptop with Linux, I'm waiting for the return of the Ubuntu desktop app.
 

Alice

Darts addict
Forum Staff
Moderator
Looking at the Runtime Release Notes things are looking to be magnificent. And by "magnificent" I mean we're finally getting some JavaScript Array.prototype or C# System.Linq functionality. ^^

Some questions:

1. Why array_first and array_last have "Real" return type? If they're meant to return the first/last element of the array, wouldn't they return Any type? Maybe Real was meant to be the return type of array_find_index, and Any was meant to be used for array_first/array_last?

2. What is the purpose of array_join function? Is it to join all array elements together into a string - like Array.prototype.join - in which case it would have a String return type? Or is it to create one large array of all elements of smaller arrays - like Array.prototype.concat - in which case maybe it's better to call it "array_concat" in the first place?
I think "array_concat" makes it easier to intuitively understand for people with other programming languages background, and also will make it easier for people with GML knowledge to learn other languages. Also, it doesn't risk being mistaken for JavaScript Array.prototype.join or C# Enumerable.Join method.
 

Dan

GameMaker Staff
GameMaker Dev.
Looking at the Runtime Release Notes things are looking to be magnificent. And by "magnificent" I mean we're finally getting some JavaScript Array.prototype or C# System.Linq functionality. ^^
1. Yes, they return "Any" - that's my typo in the release notes, so I will fix that for the next Beta release.

2. As you suspected, this returns a new array concatenating the elements of all provided arrays. I will pass on your naming change suggestion - thanks!
 

FoxyOfJungle

Kazan Games
Wow, I don't know what happened, but GameMaker acted crazy just now. I simply tried to compile the project, the game didn't show up after 1 minute, then when I click "stop", GameMaker became unresponsive (but still working). Right after I stopped recording, I closed GameMaker, then my taskbar weather gadget started flashing and Explorer.exe stopped working and restarted!

Here's the video (sorry for the low resolution, I forgot to change it)

Edit:
This only happened the first time when I imported the project.
 

Dan

GameMaker Staff
GameMaker Dev.
Wow, I don't know what happened, but GameMaker acted crazy just now. I simply tried to compile the project, the game didn't show up after 1 minute, then when I click "stop", GameMaker became unresponsive (but still working). Right after I stopped recording, I closed GameMaker, then my taskbar weather gadget started flashing and Explorer.exe stopped working and restarted!

Here's the video (sorry for the low resolution, I forgot to change it)
Will see if we can recreate - but I can see the Stop button is stuck highlighted there, so I am guessing GM was waiting on some external tool to confirm it had stopped.

Which target were you trying to build?

If you could send us a bug report ticket with your ui.log attached, that would be great - thanks!
 

FoxyOfJungle

Kazan Games
Will see if we can recreate - but I can see the Stop button is stuck highlighted there, so I am guessing GM was waiting on some external tool to confirm it had stopped.

Which target were you trying to build?

If you could send us a bug report ticket with your ui.log attached, that would be great - thanks!
Hello, I was compiling for Windows, I will submit the bug with ui.log.

Edit:
I can't send the report (the page does not move)



Edit 2:
Okay, everything I wrote is gone and the bug hasn't been sent, I give up.
 
Last edited:

Zhanghua

Member
Emm...
Now, I might use functions like array_create And array_length and array_copy for cloning the first depth array.

Need deep clone for both array and struct such as...(please don't let me to use json_xxxxx.)


GML:
function DeepCloneStruct(s){
    if( is_array(s) ){
        var len = array_length(s);
        var arr = array_create(len);
        for( var i=0; i<len; ++i ){
            arr[i] = DeepCloneStruct(s[i]);
        }
        return arr;
    }else if( is_struct(s) ){
        var stc = {};
        var nms = variable_struct_get_names(s);
        var len = array_length(nms);
        for( var i=0; i<len; ++i ){
            var nm = nms[i];
            stc[$nm] = DeepCloneStruct(s[$nm]);
        }
        return stc;
    }
    return s;
}
 
Last edited:

FoxyOfJungle

Kazan Games
Hello... please read.

The application_get_position() function does not work correctly when exporting for GX.Games.

Windows:


GX.Games:



It's been some updates that I've been reporting this problem (that means several months).





I would like to understand the usefulness of the application_get_position() function in the GX.Games export...

According to the manual:


But when I try to draw a surface manually, it works perfectly on all platforms (including HTML5, Android...), except for GX.Games.


It was working until v2022.8 version of the runtime, but it broke after v2022.9 where they claimed to have been fixed:




In HTML5 (it's a browser - like Opera GX) it works fine:


(The black bars is an effect, not aspect ratio stuff)


Code Used:

Create Event:
GML:
application_surface_draw_enable(false);
Post-Draw:
GML:
var _pos = application_get_position();
draw_surface_stretched(application_surface, _pos[0], _pos[1], _pos[2]-_pos[0], _pos[3]-_pos[1]);

Here is the attached project (I had uploaded it on Discord too, but I think it went unnoticed):


I've already submitted a ticket about this, it was answered but I didn't get any answers afterwards.





My Post-Processing FX asset relies on this function to draw correctly on all platforms. I was using window_get_width/height instead, but it broke in GameMaker version 2022.5, so I switched to application_get_position(), but it broke again in version 2022.9.

An example of a user reporting the issue on the GX.Games platform:



Using window_get_width/height is also not feasible because it returns the size of the Browser window instead of the display buffer area.
Drawing the surface in the GUI is also not feasible as there are users who like to use the GUI of different sizes of the application_surface.
Post-Draw remains the most general.
Because:
  • I'll be drawing directly in the window;
  • Without any interference from the size of the GUI, cameras, views and among others

Please consider what I wrote, I really wouldn't want to keep stressing about it, but I have no other solution to this problem. 😟
 

Mehdi

Member
Very good job in terms of giving the options to download the needed bits of runtime!👏 Excellent work!


Btw, the issue:
  • Room Editor: Paths can't be modified when "select from any layer" is enabled
hasn't removed yet on my end. I mean when you activate "select from any layer" , you can't add/select or remove points from a path.
 

gnysek

Member
So, I've checked that "selected runtimes" option which I was dreaming about for a long time. I've only selected "base" + "Windows", but it took same amount of time to install.
It takes half the space that 2022.900 beta runtime, but I noticed, that in C:\ProgramData\GameMakerStudio2-Beta\Cache\runtimes\runtime-2022.1100.0.210\bin\assetcompiler and C:\ProgramData\GameMakerStudio2-Beta\Cache\runtimes\runtime-2022.1100.0.210\bin\igor there are still folders "linux" and "osx".
Those folders (2x osx + 2x linux) are taking 850 MB (55% of whole runtime!).
Is it possible to cut them too, or they are part of "base" which cannot be moved to other "on demand" parts of runtime, becase it's located in subfolders?

Also in release notes we can read:
November will include a lot of functionality for audio
So I understand it's not available yet in this version and will be added later in November, as betas are adding new features gradually?
 

Alice

Darts addict
Forum Staff
Moderator
if it returns array, it's rather array_merge
Guess it depends on whether we're using PHP naming conventions or JavaScript naming conventions?
I'm more familiar with JavaScript and C#, which is why I suggested array_concat (only now I found out there's actually array_merge in PHP).

As for extra functionality for audio - I really hope that aside from Audio Effects (which are an upcoming In Development item on the roadmap) we'll also get arbitrary looping points as well - these are especially annoying, since audio_sound_set_track_position tends to be at least a liiiittle bit out of sync no matter how seamlessly I try to loop (might have something to do with audio stream being relatively independent from the game thread).

Arbitrary looping points together with extra array functions would make 2022.11 one of the best recent releases provided it won't leave the beta with some nasty bugs!
 

Stra

Member
Stuff in C:\ProgramData\GameMakerStudio2-Beta\Cache\runtimes keeps piling up, there was 100GB of stuff from older versions.
So the uninstaller doesn't take care of that?
Can that be deleted from inside the IDE?
 

Alice

Darts addict
Forum Staff
Moderator
Can that be deleted from inside the IDE?
Yes, when you go into Runtime Feed Preferences, you can remove the excess runtimes using the trash can button. I couldn't get automatic runtimes removal to work, though.
Also, keep in mind that stables and betas need to have their runtimes removed separately (so you can't remove a stable runtime from beta and vice versa, as far as I can tell).
Hope this helps. ^^
 
@Dan @rwkay The Nintendo Switch exporter audio is completely broken, in the beta 900 just some sound was not playing now all sounds are broken and glitch including video.
Please ask Fritz he has the project i sent with all the tests already made.
Thanks
 

gnysek

Member
What happened with 2022.10 ? On rodmap there were separate filters for 2022.10 and 2022.11, but now it seems that we either get those two versions merged, or now releases will have number not after month which ends, but by month which starts few days after release (which will have more sense IMHO, as that sounds more up to date).
 

kburkhart84

Firehammer Games
Hello, I was compiling for Windows, I will submit the bug with ui.log.

Edit:
I can't send the report (the page does not move)



Edit 2:
Okay, everything I wrote is gone and the bug hasn't been sent, I give up.
I ran into the same problem as I mentioned a few posts up. I thought it was related to something with the png I was trying to attach, seems I was wrong.
 

JeffJ

Member
Just confirmed that the Spine rotation bug I reported 3 months ago is finally fixed - this is so great to see!

Also, seeing these features on the release notes that I suggested a long time ago made my day
skeleton_attachment_exists() can be used to check if an attachment with the given name has already been created
skeleton_attachment_replace() and skeleton_attachment_destroy() can now be used to modify the attachments on your skeletons

However, I am a bit confused about the room editor. I am sorely missing the list of instances / assets on a specific layer. Previously when I selected a certain asset on a layer, it would be highlighted in a very handy list of all elements on that layer, as such:

Screenshot 1:
gmux1.png

However, now all I see is rather irrelevant information in the "inspector", but I can't seem to find any way to see that handy list. I've looked in the room editor preferences, the "Windows" menu, and in the room editor itself... What am I missing here? And how do I make it behave more in line with the first screenshot? I am using that list A LOT and the way the room editor is right now would be a nightmare to be stuck with for LTS.

Screenshot 2:
gmux2.png
 

JeffJ

Member
Just wanted to test the new attachment replace functionality, but it seems skeleton_attachment_exists() does not... well... exist?

nofunction.png
 

Zhanghua

Member
Error return of array_filter_ext
GML:
    a = [1,2,3];
    b = array_filter_ext(a,function(e,v){
        //show_debug_message([e,v])
        return v;
    })
    show_message(b); //2
    show_message(a); //error [2,3,3], should be [2,3]
also the "array_unique_ext" has abnormal length~~


And I think each function should has the 3rd argument of callback which is the reference of the array。。although we have array_map~
 
Last edited:

hxyy

Member
Feather's function hint is not fully displayed in the ide
This can be found by comparison in the original file
But in the case of Chinese, it can be fully displayed
0BV@63}GP~CM@49M19]8JTD.png

XY5FHQWR[[4{B)EWU2~PGCP.png

KP)I6J9QXUH[HWI%6@V}%[M.png

(machine translation)
 

hxyy

Member
fa_archive can be used to get files only
fa_directory gets folders and files
There is no constant for just getting folders
When you use file_attributes(), it always returns 0 regardless of the parameter fa_directory or fa_archive
This means that the game cannot tell if a path is a folder or not
I think fa_directory and file_attributes() are buggy
(Machine translation)
 

rwkay

GameMaker Staff
GameMaker Dev.
fa_archive can be used to get files only
fa_directory gets folders and files
There is no constant for just getting folders
When you use file_attributes(), it always returns 0 regardless of the parameter fa_directory or fa_archive
This means that the game cannot tell if a path is a folder or not
I think fa_directory and file_attributes() are buggy
(Machine translation)
Please file a bug with a project that shows the problems that you are seeing

Russell
 

efeberku

Member
This topic is for the discussion of issues relating to this update of GameMaker. However, this does not replace our normal bug reporting system and you should report all bugs as normal using https://contact.gamemaker.io/contact-us

As ever, PLEASE check the Required SDKs FAQ before/during updating and ensure your antivirus/OS permissions are correct by checking User Permissions and Internet Access Required by GameMaker before you submit any bug reports or post issues here.

You should post here if:
  • Something has changed between the previous version and this one, breaking your game (i.e.: code that worked previously now does not)
  • Something reported as fixed in the release notes is not actually fixed
  • You are having IDE or system issues related to something new in this update
  • You are having issues with new features introduced in this version
  • You are having issues updating to this version
  • Everything works and you want to tell us we are great (seriously, let us know if it all works correctly for you)
When reporting issues to the Helpdesk, please try to add as much information as possible, for example:
  • If the issue is with the IDE, then please give a screenshot if you can to help illustrate the problem and always attach the "ui.log" file found via the "Open Log in ..." Help menu command inside GameMaker
  • If it is a code issue, then link to or attach a YYZ showing the most basic project possible which exhibits the behaviour
  • If it is a system issue (like compiling to a specific target or running on a device) then please always include the compiler log we ask for (it's genuinely very important!) and provide details of the machine being used as well as the software versions involved
Again: posting a comment in these release threads is not a replacement for filing a bug!

Release Notes

Runtime Release Notes


Current Release - IDE v2022.1100.0.227 Runtime v2022.1100.0.210 (Oct 20, 2022)


This is a very early look at November’s version, so we can concentrate on the LTS version for October and still introduce some of the newer November (2022.11) changes for your feedback sooner, as you will see there are some quite important changes as soon as you launch this new version!

The 2022.11/1100 release brings the ability for you to pick which bits of your runtimes you wish to download (allowing for smaller install sizes and less time downloading after a new install/update) and a number of other general fixes. It's linked-to in the release notes already, but you can read all about that new dialog here.

On the runtimes side, there are already a number of bug fixes and a selection of new functions, such as for arrays and Spine skeleton attachments - with more to come in future betas.


A reminder that there is no matching Ubuntu IDE just yet - although, that may make its return later in November...

The English manual should be updated soon.
I can't see the current Beta Release Notes on my android phone. It shows V2022.3.
 

TheMagician

Member
The new Beta releases are always like getting a little present - they are always a feel-good moment for me :)

New array functionality (e.g. for each!) looks great. Since this is the last version for 2022 I was silently hoping for the new IDE workflow to be introduced as an early Christmas present. I'm sooo looking forward to it.
 

gnysek

Member
#203839 for Feather returning Any as type of array_create_ext (it should at least return Any*, but prefarable what callback returns, same as normal array_create is capable do that currently)
#203841 for global. code completion not working if any letter is put after dot
 

gnysek

Member
#203860 debugger "watch" panel is not working in beta
#203861 "GM2047 Unreachable code" isn't reported by Feather at all in any case
#202616 While manual says that date_current_datetime result depends on local timezone, it doesn't - this function always returns UTC time. Either manual issue, or runtime error.
 

rwkay

GameMaker Staff
GameMaker Dev.
#203860 debugger "watch" panel is not working in beta
#203861 "GM2047 Unreachable code" isn't reported by Feather at all in any case
#202616 While manual says that date_current_datetime result depends on local timezone, it doesn't - this function always returns UTC time. Either manual issue, or runtime error.
date_current_datetime uses the current local timezone to ensure that the value is UTC - all datetimes are stored as UTC (they are converted then to the current timezone) - This is intentional and the manual is not wrong, though we could perhaps change the wording... it does depend on local timezone to ensure the value is UTC

Russell
 

gnysek

Member
they are converted then to the current timezone
Yeah, all other functions display date depending on time zone (which can be changed by proper finction), so I believe this one should b describes i manual that it returns UTC time which then can be used to display date depending to time zone settings (it's important info if someone want to save this integer to file, as "depending on time zone" could mean it may leads to some errors if daylight saving time changes, while value returned by this function is really safe to save or even send in multiplayer games). I've reported that one as issue with manual not a bug in IDE/runtime, as I've got feeling that this is intentional.
 
@Dan @rwkay Hello, any news on why the audio is broken on the Nintendo Switch ? We can't send an update of the game due to this. Is broken completely in the latest beta 1100 and partially in the stable.
There is a bug opened with a project linked from October 7th
#203356

Thanks
 

gnysek

Member
Maybe it's cause they are preparing for audio effects? I found that in latest beta, in fnames file, there are new functions/constants:

GML:
audio_bus_main#^audio-fx

bypass?
gain?
effects?

audio_bus_create()^audio-fx
audio_effect_create(type)^audio-fx
audio_emitter_bus(emitter_idx, bus)^audio-fx
audio_emitter_get_bus(emitter_idx)^audio-fx
^audio-fx means they will only work if that flag is enabled in IDE, and seems it's not yet (probably because this feature isn't done yet).
 

xDGameStudios

GameMaker Staff
GameMaker Dev.
Error return of array_filter_ext
GML:
    a = [1,2,3];
    b = array_filter_ext(a,function(e,v){
        //show_debug_message([e,v])
        return v;
    })
    show_message(b); //2
    show_message(a); //error [2,3,3], should be [2,3]
also the "array_unique_ext" has abnormal length~~


And I think each function should has the 3rd argument of callback which is the reference of the array。。although we have array_map~
Let's take this for a ride:

GML:
a = [1,2,3];

b = array_filter_ext(a,function(value, index){
   return index; // select values that return true here!!
})

// offset = 0 (default), length = infinity (default)
// this means "start from zero and walk forward until the end"

show_message(b); // 2 <- number of valid filtered entries (padded to offset in direction of length)

show_message(a); // [2, 3, 3] this is actually correct!!

//The "ext" version of the function mutates the array but never resizes it.
//This is used for code that needs higher performance and less memory usage/allocation.

// Lets go through the iterations (we are using index as our selection logic - replicating your example):
// On first iteration index is 0, we are returning 0 (false) we don't select this entry
// On second iteration we return 1 (true) we select this entry and move it to offset (0)
// On the third iteration we return 2 (true) we also select this entry moving it to the next spot (1)

// The return value is 2 meaning only the first 2 elements starting from offset are valid!

// This is usefull when trying to "chain" multiple methods

a = [ 1, 2, 3 ]
count = array_filter_ext(a, function(value, index){ return index; }) // a == [ 2, 3, 3 ], count = 2
count = array_reverse_ext(a, 0, count): // a = [ 3, 2, 3 ], count = 2
b = array_copy_while(a, function(value, index) { return value > 2; } 0, count); // b == [ 3 ]
[IMPORTANT] All new array functions allow negative offsets (-1, is the last element) and allow negative length (traverse the array in reverse order)!
If you want to go from the end to the begining you can use offset = -1 and length = -infinity
If you want to go through the last 3 elements in reverse order offset = -1 and length = -3
 
Last edited:

Alice

Darts addict
Forum Staff
Moderator
//The "ext" version of the function mutates the array but never resizes it.
//This is used for code that needs higher performance and less memory usage/allocation.
While I understand the rationale behind it, it's very counter-intuitive to me that the end state of the array modified by array_filter_ext isn't the same as the result of matching array_filter call.

I imagine in lots of scenarios people will want their array resized anyway, and the performance gains from avoiding deallocation would be marginal compared to filtering itself; especially if "deallocation" means changing some internal array "length" variable to the new length, and leaving the rest alone. C# list, for instance, isn't all very eager to deallocate its list even after all elements have been removed from it, as it can be seen on this fiddle, yet it still makes sure to only present the corresponding length. Now, the implementation of dynamic size arrays is likely different than C# list, but I think separating allocated capacity from presented array length will generally make things more performant in the long run, anyway - like avoiding all those physical reallocations on every array_push as found in this thread.

Overall, I'd strongly prefer array_filter_ext final array state to match the result of similar array_filter call - I believe way more time would be wasted by users not understanding array_filter_ext behaviour than needing to optimise array allocation.
Alternatively include an optional parameter for keeping the later elements to prevent deallocation, though I can hardly imagine a scenario where array resizing on mutate-filtering would be anywhere near as significant as filtering itself (unless the array we're filtering on has very few elements in the first place).

(I might do a little performance testing later to back my words once I switch to PC with beta installed)
 

xDGameStudios

GameMaker Staff
GameMaker Dev.
While I understand the rationale behind it, it's very counter-intuitive to me that the end state of the array modified by array_filter_ext isn't the same as the result of matching array_filter call.

I imagine in lots of scenarios people will want their array resized anyway, and the performance gains from avoiding deallocation would be marginal compared to filtering itself; especially if "deallocation" means changing some internal array "length" variable to the new length, and leaving the rest alone. C# list, for instance, isn't all very eager to deallocate its list even after all elements have been removed from it, as it can be seen on this fiddle, yet it still makes sure to only present the corresponding length. Now, the implementation of dynamic size arrays is likely different than C# list, but I think separating allocated capacity from presented array length will generally make things more performant in the long run, anyway - like avoiding all those physical reallocations on every array_push as found in this thread.

Overall, I'd strongly prefer array_filter_ext final array state to match the result of similar array_filter call - I believe way more time would be wasted by users not understanding array_filter_ext behaviour than needing to optimise array allocation.
Alternatively include an optional parameter for keeping the later elements to prevent deallocation, though I can hardly imagine a scenario where array resizing on mutate-filtering would be anywhere near as significant as filtering itself (unless the array we're filtering on has very few elements in the first place).

(I might do a little performance testing later to back my words once I switch to PC with beta installed)
I think that you can just ignore the ext version and only use the normal ones.. if it does what you want ;) or you can resize the output using the array_resize function
 

xDGameStudios

GameMaker Staff
GameMaker Dev.
especially if "deallocation" means changing some internal array "length" variable to the new length, and leaving the rest alone. C# list, for instance, isn't all very eager to deallocate its list even after all elements have been removed from it
We could have a whole other talk about that, probably, but I would putting it simple that is the main difference between (ds_)lists and arrays and why it is still faster to add/remove elements from ds_list than it is to/from a array.


Overall, I'd strongly prefer array_filter_ext final array state to match the result of similar array_filter call - I believe way more time would be wasted by users not understanding array_filter_ext behaviour than needing to optimise array allocation.
keeping in mind that we do allow reverse traversing the array. How would that work using your approach? we would need to allocate a temporary array in the backstage to do the computations and then fill the GML array back with the results and then resize it by deallocating all the entries in the original array and finally getting rid of the temporary array. That would be slow and promote memory fragmentation. Since we would be allocating a new array in the backend you would be probably better suited with the normal array_filter version.
 
Last edited:

hxyy

Member
string_split is not an array function ;)
This is saying that a large string is converted into an array by a delimiter.
There are two cases,
One: don't know the number of delimiters, find the delimiter position, intercept the character by position, and push it into the array
This causes the array to be constantly rebuilt, which is inefficient
Second: get the number of delimiters first, and create the array according to the number of delimiters, so that the array is not constantly rebuilt
The problem is that the built-in string_count is very inefficient, even much less efficient than byte by byte traversal
Refer to this post, speed on the difference dozens of times

In many text editors, the count is instantaneous
I have feedback this problem, no exact answer, up to now the efficiency is still not as good as byte by byte traversal
(But surprisingly, the same file now takes one-tenth as long to test.)
(Machine Translation)
 

fujj

🎵🎶
GameMaker Dev.
@Dan @rwkay Hello, any news on why the audio is broken on the Nintendo Switch ? We can't send an update of the game due to this. Is broken completely in the latest beta 1100 and partially in the stable.
There is a bug opened with a project linked from October 7th
#203356

Thanks
We're looking at this issue at the moment
 
Status
Not open for further replies.
Top