[PLUGIN]Unique Sprite(no anim,uniqe image per inst

Post and try out addons that are currently in development.

Post » Sun Jun 19, 2011 4:50 pm

as for adding animations, I had a look, and even started the basics, and it's not difficult, but it is time consuming, and I'm afraid I don't have the time right now afterall. I might at some later time, but I'm trying to meet a deadline with my current project, and it's going to take a little while.
Spriter Dev
B
88
S
21
G
12
Posts: 3,240
Reputation: 16,486

Post » Thu Jul 07, 2011 2:59 pm

Fantastic! Its better than tiledBG, since it allows for changing angles (you'd have to have lots of empty space around the edge of everything for tiledbg to change angle).
B
134
S
65
G
16
Posts: 1,766
Reputation: 19,190

Post » Sun Jul 10, 2011 8:53 pm

It appears that pixel-perfect collisions are not working correctly.

Is this right? Or is my mind not right?
Follow me on Twitter @evgLabs
B
33
S
14
G
4
Posts: 251
Reputation: 4,049

Post » Wed Sep 12, 2012 11:04 am

i just wanted to say - thank you.
You propably just saved my game with this plugin.
When i am done you are going into the credits. actualy i think ill just inject you into the game as something.
ImageImageImageImage
B
26
S
7
G
7
Posts: 572
Reputation: 6,097

Post » Sun Oct 14, 2012 6:00 pm

The plugin seems to be compatible for Construct classic, do u have equivalent .js plugin that i can use ?
B
16
S
4
Posts: 248
Reputation: 2,267

Post » Sun Oct 14, 2012 9:40 pm

I tried it in debug mode and Destroying the UniqueSprite doesnt decreases VRAM usage
B
14
S
2
G
1
Posts: 46
Reputation: 1,144

Post » Mon Oct 15, 2012 6:42 pm

[QUOTE=blackstr] I tried it in debug mode and Destroying the UniqueSprite doesnt decreases VRAM usage[/QUOTE]

Actualy i have to take back what i have said a while ago.
My game gone very advanced and this plugin is now a crucial element of it. and yeah, i just noticed that for some reason the textures arent unload. EVER. And if i wont find a way to kick them out of the damn VRAM my game is ruined. 6months of hard work gone down the tube. And i am at point where rebuilding the game without this plugin is just out of the question.

now what.
ImageImageImageImage
B
26
S
7
G
7
Posts: 572
Reputation: 6,097

Post » Mon Oct 15, 2012 7:00 pm

Hi,
   Unfortunately I don't have anything setup to work on CC plugins anymore. I don't even have Visual Studio installed, and won't until it's time to make the Spriter plugin for Construct Classic, which is a ways off. It's barely changed from the vanilla sprite plugin, so anyone with basic plugin knowledge should be able to work something out.
Here's the source code:
https://dl.dropbox.com/u/1013446/UniqueSprite.rar
Spriter Dev
B
88
S
21
G
12
Posts: 3,240
Reputation: 16,486

Post » Mon Oct 15, 2012 9:52 pm

Here is an update that releases textures when you destroy the object or load another texture.
http://dl.dropbox.com/u/5426011/plugins/UniqueSpriteFixed.zip

Hopefully my build setup doesn't cause any issues.

@lucid here is what changed
The destructor in Runtime.cpp:
[code]ExtObject::~ExtObject()
{
     // No longer using this animation
     pRuntime->ReleaseAnimation(pRoot);
     renderer->ReleaseTexture(localTex);
}[/code]
and the load frame action in Actions.cpp:
[code]long ExtObject::aLoadFrameFromFile(LPVAL params)
{
     TextureHandle newTex;
     try
     {
          //localTex
          newTex=renderer->CreateTextureFromFile(params[0].GetString());
          //pAnimFrame->th=localTex;
     }
     catch (...)
     {
          return 0;
     }
     renderer->ReleaseTexture(localTex);
     localTex=newTex;
...[/code]
B
79
S
24
G
54
Posts: 4,751
Reputation: 40,765

Post » Mon Oct 15, 2012 10:12 pm

thanks rojo
Spriter Dev
B
88
S
21
G
12
Posts: 3,240
Reputation: 16,486

PreviousNext

Return to Work-in-progress addons

Who is online

Users browsing this forum: No registered users and 0 guests