• 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 GameMaker Now Supports Firebase

rmanthorp

GameMaker Staff
Admin
GameMaker Dev.
GameMaker Studio 2 now supports various Firebase services such as Analytics, Cloud Storage & Databases through new extensions available on the Marketplace. You can download the extensions and read the provided manuals to easily implement Firebase features into your Android, iOS & Web apps (through SDKs) and other platforms (through a REST API for extensions that provide one).

The following extensions are now available to download for free:
  1. Firebase Analytics
  2. Firebase Authentication
  3. Firebase Cloud Functions
  4. Firebase Cloud Messaging
  5. Firebase Cloud Storage
  6. Firebase Crashlytics
  7. Firebase Firestore
  8. Firebase Realtime Database
  9. Firebase Remote Config
Let's now look at what functionality each extension provides. https://www.yoyogames.com/en/blog/gamemaker-now-supports-firebase
 

Evanski

Raccoon Lord
Forum Staff
Moderator
Okay but why through extensions tho??
same with the GXC Api, why suddenly this support only through marketplace items?
 

O.Stogden

Member
Okay but why through extensions tho??
same with the GXC Api, why suddenly this support only through marketplace items?
Likely adopting a modular approach like other engines do, so if you don't want Opera API or Firebase, you don't need to bloat your project with it being enforced.

In certain other 3D engines, plugins such as water, animation and VR are all supported, but are separate libraries that must be enabled and downloaded in the engine per project.
 

Evanski

Raccoon Lord
Forum Staff
Moderator
Likely adopting a modular approach like other engines do, so if you don't want Opera API or Firebase, you don't need to bloat your project with it being enforced.

In certain other 3D engines, plugins such as water, animation and VR are all supported, but are separate libraries that must be enabled and downloaded in the engine per project.
True, but they could just as easily have this stuff under the game options, and include/enable the api that way, rather then relying on the buggy marketplace (before the v2 on the roadmap)
 

Alice

Darts addict
Forum Staff
Moderator
True, but they could just as easily have this stuff under the game options, and include/enable the api that way, rather then relying on the buggy marketplace (before the v2 on the roadmap)
But adding it to the game options requires adding more UI, compiling and whatnot to the core GameMaker, which needs IDE testing and adds another point of failure to the core GM:S.

And I guess they're betting on Marketplace not being so buggy soon? I'd rather have them spend, say, a month developing a set of Marketplace extensions and another 2 weeks working on Marketplace on the side, instead of them spending 6 weeks of making both the extension as a built-in functionality and the in-IDE system to enable/disable that functionality.

In general, I approve of them reusing the Marketplace tools to deliver Firebase functionality - even if Marketplace itself is bug-prone - instead of setting up some new toggle-able built-in features functionality which in all likelyhood wouldn't be any less bug-prone; quite the opposite. ^^'
 

Mool

Member
@jzavala

Dont forget this here:

1639770716637.png

I tried nativeSymbolUploadEnabled true in the past, without symbols of libyoyo.so its not working.
I also sent a feature request via helpdesk.


Thanks :)
 

jzavala

GameMaker Staff
GameMaker Dev.
Will extensions like this be available as open source (https://github.com/YoYoGames) so we can add important fixes to them if we find a bug, or we still need to count that YYG team will not put them into oblivion for few years?
Hi @gnysek

We are taking in consideration GitHub.
But I'm new here please give me a chance to change you opinion about extensions support

Regards
 
We are taking in consideration GitHub.
But I'm new here please give me a chance to change you opinion about extensions support
That would be nice.
I'm sure what @gnysek said was nothing personal, it's just that some things have been relatively archaic in the past, a lot of us are still a little 'yeah, right...😒' until proven wrong. Chance given, tho! 🙂
Congrats on your new gig, and best of luck.
 

jzavala

GameMaker Staff
GameMaker Dev.
Why no auth for Opera in that version of the extension? Patreon would be nice as well...
Unfortunately Firebase does not have specific support for these platforms, but you can use Custom Logins to associate with any unique identifier.
 

Mert

Member
Just wondering if these extensions will get kept updated since Google introduces a lot of updates to these sdks. I use my own Firebase extensions, but would love to switch to these.

My suggestion is to also implement the App-Check to prevent unauthorised access to the sdks.
 

gnysek

Member
But I'm new here please give me a chance to change you opinion about extensions support
I'm keeping my fingers crossed then, as for last 10 years there were periods when everything was updated and then forgot for many months, but as I understand there is now dedicated team to continuously work on all extensions like this, and there should be no periodical interruptions in maintenance anymore 🤩
Good work, we've got updates and new versions for dozens of extensions in last weeks!
 
Last edited:

breakmt

Member
For some reason I can't build for iOS with this extension ("TEST FAILED"). I installed CocoaPods as described here.
Don't know if that important, but my path is not like "/Users/<username>/..." (as in article)

gem which cocoapods
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.2/lib/cocoapods.rb


in a .profile file I add this line
export PATH=/Library/Ruby/Gems/2.6.0/bin:$PATH

Could it be a problem? Is it okay that I see no "bin" folder in "/Library/Ruby/Gems/2.6.0/"?


(Macbook Air M1 2020.)
 
Last edited:

jzavala

GameMaker Staff
GameMaker Dev.
Hi @breakmt
We are aware of the problem with Cocoapods and Mac M1,
I'm Mac M1 user too, this is what i do to build on iOS with cocoapods:

First time:
  1. Go to GameOptions - iOS click Podfile and Podfile.lock
  2. Click Build, this will result in fail but will create a Podfile in the root of the Xcode project
  3. Close Xcode and back to GM:S 2
  4. Go to $YourProject\options\ios and delete Podfile and Podfile.lock
  5. Click Build, this will generate a Xcode project
  6. Open the root the project
  7. Close xCode
  8. Open Terminal
  9. Move to xCode project root folder-> cd $yourPathToXcodeProjectFolder
  10. Run this script -> sudo arch -x86_64 gem install ffi (will request password)
  11. Run this script -> arch -x86_64 pod install
  12. Now open the new Xcode project generated $YourProjectName.xcworkspace (is white)
  13. Done try build on Xcode
After First Time
  1. Build without Podfile and Podfile.lock
  2. Open Terminal (step 8)
  3. move to xCode project root folder-> cd $yourPathToXcodeProjectFolder (step 9)
  4. Run this script -> arch -x86_64 pod install --repo-update
  5. Now open the new Xcode project generated $YourProjectName.xcworkspace (is white) (step 12)
  6. Done try build on Xcode (step 13)

13 steps!, Good luck 😅
 
Last edited:

breakmt

Member
Hi @breakmt
We are aware of the problem with Cocoapods and Mac M1,
I'm Mac M1 user too, this is what i do to build on iOS with cocoapods:

First time:
  1. Go to GameOptions - iOS click Podfile and Podfile.lock
  2. Click Build, this will result in fail but will create a Podfile in the root of the Xcode project
  3. Close Xcode and back to GM:S 2
  4. Go to $YourProject\options\ios and delete Podfile and Podfile.lock
  5. Click Build, this will generate a Xcode project
  6. Open the root the project
  7. Close xCode
  8. Open Terminal
  9. Move to xCode project root folder-> cd $yourPathToXcodeProjectFolder
  10. Run this script -> sudo arch -x86_64 gem install ffi (will request password)
  11. Run this script -> arch -x86_64 pod install
  12. Now open the new Xcode project generated $YourProjectName.xcworkspace (is white)
  13. Done try build on Xcode
After First Time
  1. Build without Podfile and Podfile.lock
  2. Open Terminal (step 8)
  3. move to xCode project root folder-> cd $yourPathToXcodeProjectFolder (step 9)
  4. Run this script -> arch -x86_64 pod install --repo-update
  5. Now open the new Xcode project generated $YourProjectName.xcworkspace (is white) (step 12)
  6. Done try build on Xcode (step 13)

13 steps!, Good luck 😅
Thank you! Wow, a lot of steps. Sadly, but when I do step 11 I get:

Code:
breakmt@MacBook-Air-Pavel adventure % sudo arch -x86_64 gem install ffi
Password:
Building native extensions. This could take a while...
Successfully installed ffi-1.15.4
Parsing documentation for ffi-1.15.4
Done installing documentation for ffi after 3 seconds
1 gem installed
breakmt@MacBook-Air-Pavel adventure % arch -x86_64 pod install
[!] No `Podfile' found in the project directory.
But in the project root I can see files Podfile and Podfile.lock 🧐

Also, I don't know if this important or not, when I did step 2 I saw in GM output console:

Code:
Pod install result: [33mWARNING: CocoaPods requires your terminal to be using UTF-8 encoding.

Consider adding the following to ~/.profile:

export LANG=en_US.UTF-8
And building hangs forever with
Code:
About to execute:/bin/bash -l -c "cd /Users/breakmt/gamemakerstudio2/GMS2IOS/adventure/adventure; open  -a '/Applications/Xcode.app' adventure.xcworkspace; while [ ! -d  /Users/breakmt/gamemakerstudio2/GMS2IOS/adventure/adventure/adventure.xcworkspace/xc*data ]; do sleep 2; done; "
 
with this extension its possible make a multiplayer game using the realtime database?
Only if a delay of several seconds would be acceptable, and relatively little data needs to be exchanged (otherwise it will quickly become very expensive). Pokemon-style battles and trading would probably be perfectly doable, but not a real-time shooter.
 
Remote Config + Web is crashing the game!

runner.js:1 Failed to load resource: the server responded with a status of 404 (Not Found)
Firebase.js:1 Failed to load resource: the server responded with a status of 404 (Not Found)
index.html:117 Uncaught ReferenceError: GameMaker_Init is not defined
at index.html:117:33
 
Firebase FireStore: A Simple bug Making unable to use the Extension!

GML:
var json = json_stringify({ name: "Hero", level: 100 });
listenerId = FirebaseFirestore("myCollection/newDoc").Set(json);
The error I'm Getting:

"target exception: java.lang.boolean cannot be cast to java.lang.double. Cause: null. stack trace:"
 

xCarras

Member
Hi i have a problem with listeners. When i set a listener from a database path to read changes the social event always execute the code from this listener without update the values from the database. its normal?
 

jzavala

GameMaker Staff
GameMaker Dev.
Hi i have a problem with listeners. When i set a listener from a database path to read changes the social event always execute the code from this listener without update the values from the database. its normal?
You will get a callback the first time yes and each update
 

xCarras

Member
You will get a callback the first time yes and each update
then always i get a callback the first time without any update?
if i have a listener for a path that does not exist i receive a undefined value. Then how i can use and if stament for this value? because when i store this undefined value on a variable and i call if variable == "undefined"{
execute code
}

the code dont do nothing.
 

jzavala

GameMaker Staff
GameMaker Dev.
@xCarras Try something like this:

GML:
if(async_load[?"type"] == "FirebaseRealTime_Listener")
{
        if(async_load[?"status"] != 200)
        {
            //Bad request
            exit
        }
      
        if(ds_map_exists(async_load,"value"))//value can not exists (this is what are you searching)
        {
            //Exists!! :)
            var value = async_load[?"value"]
        }
        else
        {
            //Doesn't Exists :(
        }
}
 
Top