Spriter/C2 - (9-16-2019 - bug fix)

From the Asset Store
Rotate & Animation for 16 Direction & Mouse Direction
  • Awesome. Thanks for the info. I was wondering how much of a difference it'd make in real world examples.

  • lucid Seems like my initialization time is also faster, and I don't even have a lot of instances (yet), though I didn't measure it or anything

    Unfortunately I did come across a bit of an issue if you will... though I'm not sure this is something you'll want to solve.

    Down to it: if you mirror the scml object, the width does not change to negative: what changes are the widths of the attached sprite objects. Thus if you try to use line of sight on the scml object, it will not work properly because the LoS behavior will not update the angle to reflect the mirroring. In other words, it will always detect line of sight in one direction, but not the other.

    My expected response to this is "why are you using line of sight directly on the scml object? you should be mapping the scml object to a sprite first and doing everything on that"... or something, but let's just say I'm not for whatever reasons, since such an answer wouldn't really tackle the issue as I'd like (and I don't want to argue about the alleged usefulness of abstracting every scml object with a sprite object).

    I'm going to think about how I can fix this—preferably without modding the line of sight plugin itself, since it's not really at fault here (I think I'll just change my general approach instead) but in the mean time, I thought I'd let you know to see what you think.

  • BBaller1337, I came across the exact issue you describe and many others because I was applying my logic to directly to C2 sprites or SCML objects. I made the painful decision to redo everything and pin my sprite/spriter objects to a C2 sprite first and it makes everything much cleaner and eliminates many, many issues like this.

    Trust me, the further you go down this route the more painful it will become.

  • BBaller1337, I came across the exact issue you describe and many others because I was applying my logic to directly to C2 sprites or SCML objects. I made the painful decision to redo everything and pin my sprite/spriter objects to a C2 sprite first and it makes everything much cleaner and eliminates many, many issues like this.

    Trust me, the further you go down this route the more painful it will become.

    Hmm. Interesting response. And I am grateful for your post/indirect advice, but do you mind if I ask some questions?

    By "directly to C2 sprites", you mean to the objects that Spriter creates?

    Are you pinning every spriter/sprite object to a single Sprite object that you create? (Just trying to clarify what you meant)

    Is having more objects as a result not a concern for you/is it just better than the alternative? What about the complications in logic and handling objects caused by abstraction?

    Probably most importantly: what other issues do you have?

    My current project is very far into development, the code works and it works well, and after some recent (much-needed) polish/optimizations/clean-up is at a point it's easy to understand, makes sense, is flexible, etc.

    I quickly fixed the issue I shared above by making a mod of line of sight as I kind of needed to anyway because the default line of sight doesn't have all the functionality I would like anyway (e.g. sorry Ashley, but why can't we have line of sight in a direction different than the object angle? ). I could have maybe done something about it on the SCML side but I'm a little bit more intimidated by that code (i.e. afraid of breaking it) and I needed the LoS Mod anyway

    But I'm curious what other concerns/issues there could be. Over 6 months back I did run into issues with things like... for instance, picking the hurtboxes (collision boxes) belonging to an SCML object when both objects are encapsulated by families, i.e.

    PICK SCMLFAMILY | DO THING WITH HURTBOXES FAMILY

    would not know to pick the hurtbox(es) that are in the container of the SCML object picked in the SCML family, but I resolved this ages ago as well. And I don't think abstraction through a sprite object would fix this anyway...

    In other words, if you're willing to help, more information would help me make a more informed decision. Time is money and all that and trying to recode things would be an extreme setback that would kill both progress and motivation, but based on what you say it may be worth it anyway, haha. I guess I'm just skeptical because I've managed to get everything working pretty well so far, even if it took some working around things, and I don't think the abstraction would have helped with anything anyway--with the exception of this issue, but I can also see a lot of cons to it when I draft it up in my head...

  • 12/26/2016 Download new version

    • Fixed a bug that would cause a javascript error when using the transitional old style version of the plugin (doesn't apply to most. If you have no idea what this means, it probably didn't/won't affect you)
    • Fixed a bug that would cause a javascript error when attempting to start a layout where scml objects had no scon or scml file set.

    BBaller1337 - so are you saying if scml returned negative width when it was set to mirror that would solve our issues? Or is it something more. If that's it, I'll see what I can do - I need to make sure that there aren't any unforeseen issues with changing that, but nothing immediately comes to mind.

  • hi lucid,

    thank you for this amazing plugin, its makes development much easier.

    i have an issue where i have 2 scml objects and i want to attach them together.

    obj 1 is a character.

    obj 2 is a fireball.

    each has a scml file.

    i want to attach the fireball to the arm of the character.

    i need actions that given a name of a spriter-object, it will be able to get / pin this properties:

    x/y/angle/scaleX/scaleY/alpha/Visible(+which frames pin visible to)/z-order.

    this way i can say: fireball.scml set (x,y) to the (x,y) of the character.scml "arm" spriter-object (+ some offset)

    and then i can say: fireball.scml pin to character.scml spriter-object "arm" - properties: All.

    if there is a better way to this, i would love to hear it.

    another possible solution is to use the new Point system inside spriter (yet to try it).

    (i already changed the javascript, and made pin for the visible,x,y,angle, it has some minor bugs and its far from perfect)

  • 12/26/2016 Download new version

    • Fixed a bug that would cause a javascript error when using the transitional old style version of the plugin (doesn't apply to most. If you have no idea what this means, it probably didn't/won't affect you)
    • Fixed a bug that would cause a javascript error when attempting to start a layout where scml objects had no scon or scml file set.

    BBaller1337 - so are you saying if scml returned negative width when it was set to mirror that would solve our issues? Or is it something more. If that's it, I'll see what I can do - I need to make sure that there aren't any unforeseen issues with changing that, but nothing immediately comes to mind.

    Yes, it almost certainly would (unless stricky knows of something else/some complications)

    sagispin I think objectX/Y and objectAngle would come in handy here? I'm not sure for the other properties though, and I'm guessing there's some reason you want the fireball as its own SCML object and not as an object within the character project, huh? I guess I'm just having a hard time seeing what you're trying to do.

    As far as attaching an object (e.g. a sprite) to one of an SCML's object though, it's possible, as I've done it: but I put the actual sprites/collision boxes I want to attach stuff to into their own family, then basically pin effects to that sprite family, and I know which sprites to pick because each one is associated with the SCML object that owns it... but it's a little complicated and my situation is a bit different I think, so eh. But a lot is possible with a bit of creativity

    ---

    P.S.: I got a new error recently but I haven't been able to replicate it

    Since the game works even with it, I can't replicate it, and I don't have any real info besides the above (that it's trying to set the sound volume of a triggered Spriter sound to a float before returning it, I think, and somehow that's causing an error), I'm not going to worry about it too much, but if anyone somehow knows anything, feel free to let me know~

  • BBaller1337

    fireball has looping animation that moves sprites around.

    making a looping animation in spriter is a nightmare because the feature that puts spriter animation inside spirter animation - is still work in progress.

    the new pin action plugin should also work with anytype of object. not just scml (also sprite and tiled background...)

    the problem that you cannot directly "talk" to a sprite that is a part of the scml.

    this is bad practice, because you have no control of how spriter exports.

    as i understand it, you found a workaround using familys like charcterSpritesFamily.

    now you can say fireBall pin to charcterSpritesFamily that has the tag "arm"

    if the sprite gets deleted you just have to give another spirte the tag "arm"

    thats a nice workaround, but you have to maintain it and keep it organized after each change scml change.

  • I see I see. yeah, being able to completely manipulate every object could be useful/helpful here.

    there's a tiny bit of maintenance work for me, but very little. I basically just import an object once, add it to a family, and I'm set, so long as the object names stay the same. It ultimately depends on your system and what you're trying to do though.

    anyway, sorry I can't be of any help.

  • Hey Guys. I just saw Spriter Pro available in Steam:

    For those who can't afford it, you can buy it here for a $1.00:

    https://www.humblebundle.com/game-devel ... ero_image0

  • Hey Guys. I just saw Spriter Pro available in Steam:

    For those who can't afford it, you can buy it here for a $1.00:

    https://www.humblebundle.com/game-devel ... ero_image0

    Sweet deal, thanks!

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hey Guys. I just saw Spriter Pro available in Steam:

    For those who can't afford it, you can buy it here for a $1.00:

    https://www.humblebundle.com/game-devel ... ero_image0

    This is pretty cool but it's a shame it's Steam only, I've had serious issues in the past with using software through Steam (namely Construct 2 itself with the weird opt-in/opt-out of beta policy). Price is a steal though so I bought a bundle anyway.

  • Hi, thanks for the recent updates.

    I have a problem with my SCML object disappearing as soon as it gets outside of layout (during a layout zoom-in). To be more clear, it's the small scml box object which gets out of layout bounds, but my whole (much bigger) object which disappears, so it is very visible.

    Is there any solution to this?

    Thanks a lot!

  • Hi, thanks for the recent updates.

    I have a problem with my SCML object disappearing as soon as it gets outside of layout (during a layout zoom-in). To be more clear, it's the small scml box object which gets out of layout bounds, but my whole (much bigger) object which disappears, so it is very visible.

    Is there any solution to this?

    Thanks a lot!

    Have you set the animation bounding box for your animations in Spriter? (We only recently added this to our tutorial)

    Saving it after doing this will give the plugin the bounding box information it needs.

  • Hi lucid ,

    I have a little question/request.

    I like Spriter, and it is a good alternative to frame-by-frame sequences, especially for big/long animations and in a download-weight-size aspect.

    But I noticed that .scml and .scon files tend to become big, sometimes more than a 1mb in size even for small animations (My record is 7mb in weight)

    Also I noticed that those files are text based, and easily compressed by zip.

    For example, 1mb .scml file compressed by 7z to 23kb(!!!) in size.

    Windows zip compress to 45kb...

    RAR should be somewhere in between...

    So, is it possible to make those files smaller to download?

    Please include in the Spriter option to export and read compressed text files, there are many compression+uncompress algorithms out there to use, even for JavaScript.

    I know that those files will become unredable, but it is a good option for export, additionaly in some aspects a more secure one (like minified/uglified script, but unlike minifier, it could be a total gibberish if comressed).

    Thank you.

Jump to:
Active Users
There are 2 visitors browsing this topic (0 users and 2 guests)