00:00
00:00
Newgrounds Background Image Theme

Vaittus just joined the crew!

We need you on the team, too.

Support Newgrounds and get tons of perks for just $2.99!

Create a Free Account and then..

Become a Supporter!

Use Newgrounds flash API in html5

2,584 Views | 5 Replies
New Topic Respond to this Topic

Use Newgrounds flash API in html5 2017-04-21 10:12:05


Hey Newgrounds, currently trying to get my head around the newgrounds.io api but thought I would try to use the flash api in a html5 game, now I can use the preloader and ad etc just swapping out the contents of the div for the flash preloader with the game file html, but I was wondering if its possible to use the flash api to use its features such as unlocking medals etc in a html5 game?

I know I can just have the swf hidden and contact to and from it using js however when trying this on newgrounds the api does not seem to be recognized unless uploaded as a swf, any one got any ideas? :o


Hi,

go to GIthub and search for Newgrounds API and JavaScript. You will find a library with a linked demo game here that can unlock Medals. Unfortunately, scoreboards aren't implemented.

Does anyone know of a working newgrounds.io v3 example?

Response to Use Newgrounds flash API in html5 2017-06-16 05:42:44


At 6/16/17 04:05 AM, MrStahlfelge wrote: Hi,

go to GIthub and search for Newgrounds API and JavaScript. You will find a library with a linked demo game here that can unlock Medals. Unfortunately, scoreboards aren't implemented.
http://www.newgrounds.com/projects/view/646548
Does anyone know of a working newgrounds.io v3 example?

Hey thanks for the reply, however already figured out the Newgrounds.io api with javascript, used it in the following game

As for scoreboards and a working newgrounds.io v3 example, you can just look at the official javascript API, it comes with an example with a working scoreboard
https://bitbucket.org/newgrounds/newgrounds.io-for-javascript-html5/downloads/

If you need any help with it just send me a pm.

Response to Use Newgrounds flash API in html5 2017-06-16 13:04:51


Hey thanks for the reply, however already figured out the Newgrounds.io api with javascript, used it in the following game
http://www.newgrounds.com/portal/view/692782
As for scoreboards and a working newgrounds.io v3 example, you can just look at the official javascript API, it comes with an example with a working scoreboard
https://bitbucket.org/newgrounds/newgrounds.io-for-javascript-html5/downloads/

If you need any help with it just send me a pm.

Glad you made it with the API, and congrats to the game. I will try to get the API flying this weekend, so thanks for your offer!


Do you know how to generate "aes_encryption_key" for this api https://bitbucket.org/newgrounds/newgrounds.io-for-javascript-html5/downloads/ ?

I try to send score for this game https://www.newgrounds.com/portal/view/714568 but got error
{"success":false,"app_id":"47960:sCyM3bXh","debug_extra":["calls is flat"],"error":{"message":"Secure call could not be decrypted. Verify that you are using the correct encryption key, cipher and encoding format.","code":201},"api_version":"3.0.0","help_url":"http://\/www.newgrounds.com\/wiki\/creator-resources\/newgrounds-apis\/newgrounds-io"}


I managed to put Newgrounds medals and topscores in my game 'Foreign Frugglers' with Game Maker Studio 1.4. (GM2 also works)
Here's the game: https://www.newgrounds.com/portal/view/716161
Here's the GMEZ: https://marketplace.yoyogames.com/assets/7326/newgrounds-api

Good Luck with the integration! Medals and Topscores are GREAT!

-UltimoGames

Use Newgrounds flash API in html5


Blow off some STEAM!

BBS Signature