[Behavior] Inject base64 string as Sprite Image

Forum Home Forum Home > Construct 2 Development > Plugins for Construct 2
 Post Reply Post Reply Page  <1234>
Author
1,351 Rep
Post Options Post Options   Quote tnewhook Quote  Post ReplyReply Direct Link To This Post Posted: 23 Apr 2012 at 4:53pm
Is there a way to put base64 text in the sprite (or text at all :P)
Back to Top
1,351 Rep
Post Options Post Options   Quote tnewhook Quote  Post ReplyReply Direct Link To This Post Posted: 23 Apr 2012 at 4:53pm
BTW, thanks for the plugin...It's a big help! God bless :)
Back to Top
16,358 Rep
Post Options Post Options   Quote newt Quote  Post ReplyReply Direct Link To This Post Posted: 24 Apr 2012 at 3:39am
Just had an epiphany. Rojo's canvas has the ability to create a base64 url...
Draw to, or paste to canvas, inject canvas into sprite....nice.
Only works without webgl atm though.
Back to Top
4,678 Rep
Post Options Post Options   Quote Mulkaccino Quote  Post ReplyReply Direct Link To This Post Posted: 03 May 2012 at 3:46am
This behavior is awesome, but I had to disable webGL to get it to work in Firefox and Chrome. Opera and IE handle it unconditionally, no problem.
Back to Top
5,295 Rep
Post Options Post Options   Quote Pode Quote  Post ReplyReply Direct Link To This Post Posted: 03 May 2012 at 8:03am
@Mulkaccino : it doesn't work with WebGL for the moment (as a lot of behaviors/plugins here) because I don't know how to force C2 to load an image as a WebGL texture after the framework was loaded...
Back to Top
1,351 Rep
Post Options Post Options   Quote tnewhook Quote  Post ReplyReply Direct Link To This Post Posted: 07 May 2012 at 3:46pm
@Pode - Again, thanks for this behavior. However, I'm having one problem with it - it doesn't seem to load the image when the game is initially loaded (sometimes) Sometimes it's fine. However, if you refresh the browser, the first image will load properly. If someone could look at it, I'd appreciate it!

Thanks a ton

Here's a link to the .capx
http://dl.dropbox.com/u/12722403/3dcardModify.0.9.3.noJSON.capx

and the images (you'll have to change the path to the images on the New Question event sheet, event 2)
http://dl.dropbox.com/u/12722403/images.zip
Back to Top
494 Rep
Post Options Post Options   Quote curtischan Quote  Post ReplyReply Direct Link To This Post Posted: 20 May 2012 at 2:12am
Is it possible to have multi instance sprite image with different Inject base64 string ?
Back to Top
5,295 Rep
Post Options Post Options   Quote Pode Quote  Post ReplyReply Direct Link To This Post Posted: 20 May 2012 at 10:18am
@curtischa, : if I understand well your question, on the same Sprite you can inject different base64 string one after the other (provided you saved them before in their own var, of course).
Back to Top
494 Rep
Post Options Post Options   Quote curtischan Quote  Post ReplyReply Direct Link To This Post Posted: 20 May 2012 at 12:18pm
Exactly what I want is to create many instances of single sprite image with different inject strings. Would you mind teaching how can I do it?


Edited by curtischan - 20 May 2012 at 2:33pm
Back to Top
494 Rep
Post Options Post Options   Quote curtischan Quote  Post ReplyReply Direct Link To This Post Posted: 21 May 2012 at 1:56pm
This plugin seems unstable in mobile devices, such as android or ipad. The sprite image doesn't show itself occasionally. [solved]

Edited by curtischan - 22 May 2012 at 9:07am
Back to Top
 Post Reply Post Reply Page  <1234>

Forum Jump Forum Permissions View Drop Down