At 1/11/18 05:54 PM, Diki wrote: So that's how my day at work was today. :(
PHP? Do you take a time machine to work? ;)
At 1/11/18 05:54 PM, Diki wrote: So that's how my day at work was today. :(
PHP? Do you take a time machine to work? ;)
At 1/11/18 08:19 PM, MSGhero wrote: I spent my day at work doing some work but also learning that OpenFL is on its way to plug n play swfs. That’s not the actual goal, more of a side effect: js and typescript users can now use OpenFL as a library and can embed swfs as assets. Pretty much AS3 for js. But with a bit more bytecode work, it’s possible to also get the code out of the swf. With the AS3 to Haxe conversion library and all of that, maybe just maybe that could be a swf -> native js pipeline.
I kinda want to play around with that idea, but I also don’t want to deal with bytecode.
A swf -> native js pipeline was the holy grail 5 or so years ago when Flash was falling apart and HTML5 was taking over. The industry I'm in has (and still does) spend literally millions porting old Flash content to HTML5.
The swf to js thing has been tried so many times and it has never worked. If you did get it working perfectly (which would take a long time) then you'd have made millions back then :)
At 1/12/18 06:05 AM, Rustygames wrote: A swf -> native js pipeline was the holy grail 5 or so years ago when Flash was falling apart and HTML5 was taking over. The industry I'm in has (and still does) spend literally millions porting old Flash content to HTML5.
The swf to js thing has been tried so many times and it has never worked. If you did get it working perfectly (which would take a long time) then you'd have made millions back then :)
Swf to as3, as3 to haxe, haxe to js. Swf bundled assets to js is already working, so it seems feasible. I guess everyone you described said that though.
Been looking at using web3 for making a DApp, wondering if I should port it to Haxe, or if I should just do it in AS3 and use ExternalInterface instead.
At 1/11/18 05:54 PM, Diki wrote: You know what's fun? Having a function that essentially just basic math by subtracting 0.1 from 1.0 down to 0.0 completely break for no apparent reason, when it has worked for months without issue. After several headaches and god knows how long of confusingly tinkering with code, I found out that PHP is just fucked. God dammit do I ever fucking hate PHP.
So that's how my day at work was today. :(
Moral of the lesson: never trust floating-point arithmetic to always be correct? It doesn't seem like it's only a PHP issue, given that 0.1 is a rather pesky number in floating-point representation.
Slint approves of me! | "This is Newgrounds.com, not Disney.com" - WadeFulp
"Sit look rub panda" - Alan Davies
Yeet.
Finally my first game using Haxe. I don't know anything about JS and I got an HTML5 build (and it works on android someone told me) for free.
Is anyone here from the US and could use a $35 new egg gift card?
I got it for Christmas 2016 but it's been sat in my inbox for more than a year now. It was a gift from a US company I was working for at the time, but I'm pretty sure it's only valid on newegg.com and not in the UK.
Anyway, if anyone needs it I can send them it
At 1/20/18 03:59 AM, Rustygames wrote: Is anyone here from the US and could use a $35 new egg gift card?
I got it for Christmas 2016 but it's been sat in my inbox for more than a year now. It was a gift from a US company I was working for at the time, but I'm pretty sure it's only valid on newegg.com and not in the UK.
Anyway, if anyone needs it I can send them it
Would using a VPN work? For software, or something digital. I know it did for me for ordering MP3s from Amazon.com when not in the US.
Slint approves of me! | "This is Newgrounds.com, not Disney.com" - WadeFulp
"Sit look rub panda" - Alan Davies
At 1/20/18 07:37 AM, Gimmick wrote:At 1/20/18 03:59 AM, Rustygames wrote: Is anyone here from the US and could use a $35 new egg gift card?Would using a VPN work? For software, or something digital. I know it did for me for ordering MP3s from Amazon.com when not in the US.
I got it for Christmas 2016 but it's been sat in my inbox for more than a year now. It was a gift from a US company I was working for at the time, but I'm pretty sure it's only valid on newegg.com and not in the UK.
Anyway, if anyone needs it I can send them it
Buying MP3s? Never heard of that before ;)
Seriously though, I have no use for it, so if anyone wants it I'd rather it go to good use than just sit in my inbox unused
At 1/21/18 09:56 PM, GeoKureli wrote: @MsgHero I'm trying to test your NG.hx API and I have no idea where format.amf3.Writer/Reader/Tools.hx is found. I tried amf3haxe but that didn't have it. I have Haxe 3.4.4.
Probably `format` haxelib, but the AMF3 one had huge changes since I last messed with this code. I have one more flixel PR to finish before I start on this again. I'd like to minimize external dependencies, and it's not like AMF3 is the only serialization that works here. I do need AES-128 which I've only found in haxe-crypto. And it might have to be tied down to OpenFL unless I do a bunch of (annoying) bitmap abstractions.
Edit: other thing was that Haxe by default only loads GET data as strings, and NG's data had a bunch of 0 bytes that null terminated ("corrupted") the data. I need to see if there are any headers I can add to fix that for now.
At 1/21/18 10:36 PM, MSGhero wrote:At 1/21/18 09:56 PM, GeoKureli wrote: @MsgHero I'm trying to test your NG.hx API and I have no idea where format.amf3.Writer/Reader/Tools.hx is found. I tried amf3haxe but that didn't have it. I have Haxe 3.4.4.I'd like to minimize external dependencies, and it's not like AMF3 is the only serialization that works here.
I'm not seeing any compression or null terms in v3's responses and I don't see save files mentioned anywhere in the doc. I don't think this is needed anymore.
I do need AES-128 which I've only found in haxe-crypto.
I fucking hate dealing with encryption but I did come across this lib and started looking into it. at least rc4 is pretty straight forward (Note: no idea what I'm talking about)
And it might have to be tied down to OpenFL unless I do a bunch of (annoying) bitmap abstractions.
Do this really need to deal with Bitmaps at all? why not hold the url strings and leave displaying up to utilizing devs?
Edit: maybe once a barebones API is made there can be some OpenFL wrapper, or component that does handles any kind of display utils
Edit2: Save files v3 appears to be in progress
At 1/23/18 11:24 PM, GeoKureli wrote:At 1/21/18 10:36 PM, MSGhero wrote:I'm not seeing any compression or null terms in v3's responses and I don't see save files mentioned anywhere in the doc. I don't think this is needed anymore.At 1/21/18 09:56 PM, GeoKureli wrote: @MsgHero I'm trying to test your NG.hx API and I have no idea where format.amf3.Writer/Reader/Tools.hx is found. I tried amf3haxe but that didn't have it. I have Haxe 3.4.4.I'd like to minimize external dependencies, and it's not like AMF3 is the only serialization that works here.
I do need AES-128 which I've only found in haxe-crypto.I fucking hate dealing with encryption but I did come across this lib and started looking into it. at least rc4 is pretty straight forward (Note: no idea what I'm talking about)
And it might have to be tied down to OpenFL unless I do a bunch of (annoying) bitmap abstractions.Do this really need to deal with Bitmaps at all? why not hold the url strings and leave displaying up to utilizing devs?
Edit: maybe once a barebones API is made there can be some OpenFL wrapper, or component that does handles any kind of display utils
Edit2: Save files v3 appears to be in progress
Oh, the other thing was local storage. If the API can't connect, all events like medal unlocks get stored locally and batch upload upon connecting. SharedObject is pretty easy, but there'd have to be wrappers or something for the other libs. It wouldn't be platform-agnostic so much as #ifdefing every lib individually. Not impossible or anything, just annoying.
At 1/12/18 06:05 AM, Rustygames wrote: The swf to js thing has been tried so many times and it has never worked. If you did get it working perfectly (which would take a long time) then you'd have made millions back then :)
my c++/opengl* game engine (loads swfs for graphics) has about 30% of what you'd need to do that already done and it was just me working on it, a good team could probably get a js/webgl flash player implementation like 99% working with a year or two of dedicated work on it. I think its more of a matter that nobody really cares enough to do that than it being impossible or something
*c++/opengl can be compiled to js/webgl with the emscripten compiler
in fact if adobe wanted to they could probably just literally compile flash player with emscripten and get a pluginless flash that way
At 1/26/18 09:44 PM, Glaiel-Gamer wrote: in fact if adobe wanted to they could probably just literally compile flash player with emscripten and get a pluginless flash that way
I like to think they're working on it, and it'll be revealed after 2020 when they Flash Player officially reaches EOL...but maybe that's asking a bit much.
Slint approves of me! | "This is Newgrounds.com, not Disney.com" - WadeFulp
"Sit look rub panda" - Alan Davies
At 1/24/18 07:29 PM, MSGhero wrote: Oh, the other thing was local storage. If the API can't connect, all events like medal unlocks get stored locally and batch upload upon connecting. SharedObject is pretty easy, but there'd have to be wrappers or something for the other libs. It wouldn't be platform-agnostic so much as #ifdefing every lib individually. Not impossible or anything, just annoying.
So, I got it mostly working, I based it off of the Unity version, only thing left is some session stuff and encryption. I notice that NG.io Unity appends its AES-128 initialization vector into the secure string, but haxe-crypto doesn't really offer that info. Though keep in mind encryption both angers and confuses me, greatly.
I've been having to test my changes via mac builds rather than flash because of this security sandbox crap. As far as I know everything is setup correctly(see pic below). My work macbook is set up the same way and that doesn't have any security sandbox issues...
oh well, I guess I just can't use breakpoints for the time being
At 1/27/18 01:03 PM, GeoKureli wrote: So, I got it mostly working, I based it off of the Unity version, only thing left is some session stuff and encryption. I notice that NG.io Unity appends its AES-128 initialization vector into the secure string, but haxe-crypto doesn't really offer that info. Though keep in mind encryption both angers and confuses me, greatly.
Feel free to PR anything to mine or start your own if it's significantly different (I'd be surprised if it was that different). I'm gonna knock out the flixel junk today.
Edit: isn't the init vector the just key you pass into AES?
At 1/27/18 01:22 PM, MSGhero wrote: Feel free to PR anything to mine or start your own if it's significantly different (I'd be surprised if it was that different). I'm gonna knock out the flixel junk today.
It's honestly pretty different, the API itself has changed structure a lot.
Edit: isn't the init vector the just key you pass into AES?
no thats the encryption key, The unity version creates a random IV, encrypts the data with the iv and key and appends the IV to the byte array before converting to base64
At 1/27/18 02:35 PM, GeoKureli wrote: It's honestly pretty different, the API itself has changed structure a lot.
K I guess...
no thats the encryption key, The unity version creates a random IV, encrypts the data with the iv and key and appends the IV to the byte array before converting to base64
I never implemented AES, but I did all that manually for whichever encryption I was using. The guy isn't actively maintaining the crypto lib, and there are ppl saying security issues and AES doesn't work issues, so maybe it's not the best to use anyway. It's not hard to find a legit implementation and translate it to haxe, for AES-128 and RC4.
At 1/27/18 04:38 PM, MSGhero wrote: It's not hard to find a legit implementation and translate it to haxe, for AES-128 and RC4.
That sounds like a pretty good idea
At 1/27/18 05:59 PM, GeoKureli wrote: That sounds like a pretty good idea
I don’t think I have time, especially for monotonous testing like I did back then. I can help out, like if you need a translated aes or advice or whatever, but you’re point man on this now. At least until I need the api.
At 1/27/18 04:38 PM, MSGhero wrote: It's not hard to find a legit implementation and translate it to haxe, for AES-128 and RC4.
No knowledge of crypto here, so I'm confused - what's the problem with the existing implementation that requires another implementation of AES-128 to be ported instead?
Slint approves of me! | "This is Newgrounds.com, not Disney.com" - WadeFulp
"Sit look rub panda" - Alan Davies
At 1/31/18 08:18 AM, Gimmick wrote:At 1/27/18 04:38 PM, MSGhero wrote: It's not hard to find a legit implementation and translate it to haxe, for AES-128 and RC4.No knowledge of crypto here, so I'm confused - what's the problem with the existing implementation that requires another implementation of AES-128 to be ported instead?
People have raised issues on github that it doesn’t work with certain sizes of data and other things. Plus it doesn’t seem like it gives you access to a piece of data the NGAPI needs.
At 1/30/18 09:09 PM, MSGhero wrote:At 1/27/18 05:59 PM, GeoKureli wrote: That sounds like a pretty good ideaI don’t think I have time, especially for monotonous testing like I did back then. I can help out, like if you need a translated aes or advice or whatever, but you’re point man on this now. At least until I need the api.
Oh, I wasn't suggesting anything, any help is appreciated but things are going pretty smoothly. I'm fine with only allowing RC4 - base64 in the initial implementation. I'm about to wrap up most of it. I'll post it here before I start the tertiary features.
Quick poll: How many y'all still use Flash? I'd assume the majority of you have shifted to Haxe, Unity or some combination thereof. Personally, I'm thinking of moving to Haxe once I finish whatever things I have remaining in AS3 (which, fwiw are more in the AIR category rather than "web" flash).
On a side note, I found out that the maximum number of nested DisplayObjects in the display list is about ~799, give or take. I'm not sure if it's machine dependent or not, but I was scratching my head for a long time on how to allow more than 800 nested displayobjects in my library - I thought this was a stack overflow-related issue since I was using recursion for certain parts, including rendering, but apparently 799's the maximum that the player could handle, on my system anyways. Higher values would still work, but the moment you tried to do anything (click, press a button, etc) the player would crash.
private function maxDepthTest():void
{
cosnt max:int = 797; //last known stable value
var a:Sprite = new Sprite();
var d:Sprite = a;
for (var i:int = 0, g:int = 2; i < max; ++i, ++g)
{
var c:Sprite = new Sprite();
d.addChild(c);
d = c;
}
trace(g);
addChild(a);
}
It's worth noting that you wouldn't find any foreshadowing memory- or cpu-wise. It's not like there's a slow rise to the max memory that it can take (~1GB) and then it crashes; when I tested with render-heavy sprites, it remained at around 45-55 (with the GC running every now and then) and then it crashed once I clicked anywhere (even the window title-bar).
Slint approves of me! | "This is Newgrounds.com, not Disney.com" - WadeFulp
"Sit look rub panda" - Alan Davies
At 2/15/18 11:32 AM, Gimmick wrote: Quick poll: How many y'all still use Flash? I'd assume the majority of you have shifted to Haxe, Unity or some combination thereof. Personally, I'm thinking of moving to Haxe once I finish whatever things I have remaining in AS3 (which, fwiw are more in the AIR category rather than "web" flash).
I'm still employed as a flash developer, but they've allotted half my work week to learning Unity, I'll probably switch over for good in a couple months if the Unity WebGL port of the game makes enough money. I'm also porting all of my old unfinished projects over to haxe
On a side note, I found out that the maximum number of nested DisplayObjects in the display list is about ~799, give or take. I'm not sure if it's machine dependent or not
I tried going up to 5500 and it's still working. I'm on a MacBook Pro 17. if it's crashing for you at 799 try setting mouseChildren and mouseEnabled to false. I wonder if the bubbling events is what's killing it.
None
At 2/15/18 02:52 PM, Luis wrote: i still make all my art in flash
Flash will always have it's uses for artists and animators
mx
Wait... what
@MSGHero + anyone interested in haxe
I've got the haxe newgrounds.io API in a showable state. and here's the NG project preview I use to test the features.
If anyone has any "This is dumb, do it like this, instead" suggestions, I'm down to hear them
of course as soon as I put it up I start getting "You have been making too many calls to the API and have been temporarily blocked."
nothing with call frequency has changed lately...
At 2/15/18 01:44 PM, GeoKureli wrote: I'm also porting all of my old unfinished projects over to haxe
I see, are existing projects going to be ported to Haxe too, or is it going to be left as abandonware?
On a side note, I found out that the maximum number of nested DisplayObjects in the display list is about ~799, give or take. I'm not sure if it's machine dependent or notI tried going up to 5500 and it's still working. I'm on a MacBook Pro 17. if it's crashing for you at 799 try setting mouseChildren and mouseEnabled to false. I wonder if the bubbling events is what's killing it.
Was it 5500 because of disabling mouseChildren and mouseEnabled? Also, that's a huge difference, dang. Is it because of memory, or something else? (My system = 1Ghz, 1.5Gb RAM AMD)
Slint approves of me! | "This is Newgrounds.com, not Disney.com" - WadeFulp
"Sit look rub panda" - Alan Davies
At 2/15/18 07:19 PM, Gimmick wrote: I see, are existing projects going to be ported to Haxe too, or is it going to be left as abandonware?
I'm ported Gassy Rick Astley over to haxe, but only because it's the simplest game that uses my old flash "engine". it's probably better left as abandonware.
Was it 5500 because of disabling mouseChildren and mouseEnabled? Also, that's a huge difference, dang. Is it because of memory, or something else? (My system = 1Ghz, 1.5Gb RAM AMD)
No other changes were made to the code, I just never crashed, so I kept raising it.