BBaller1337's Forum Posts

  • 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.

  • 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.

  • 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~

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • 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...

  • Ditto, I think complete search functionality really helps with workflow. If you wanted a stretch goal after, find/replace can be useful too, in certain contexts. XP

  • 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.

  • It's hard to say. You haven't said what the complete mechanic is supposed to do.

    I can tell you that the for each is probably not needed, and that it will definitely cause a slow down with a lot of instances.

    btw, didn't mean to ignore you earlier, just kinda slipped my mind

    the complete mechanic is irrelevant IMO since the problem is only "how to detect line of sight between two objects in the same family based on instance variables", not "what to do once line of sight has been detected"

    and the for each is needed logically as mentioned (but not picking-wise since C2 does that already), and generally there won't be more than 5 instances of a "Fighter" object at once so I don't think scaling is an issue: even at 10 instances it should be fine, and the code and other such things are generally optimized throughout.

    I have a problem with the logic of the assumption.

    Say, the goal is to minimise lines of code.

    Starting from 1 object. Addressing is no problem.

    Need many, use instances.

    Need many objects and there instances, use a family.

    Next logical step would be a group containing 2 family's. Cant have a group of family's, but can use 2 family's.

    unfortunately I did not understand the last sentence. what do you mean by a "group"? and what is the "problem" that you are trying to solve as you see it?

  • Thanks for the update! That should prove helpful.

    Thanks also for the details, I'll look into what you said when I have a chance. =)

  • 99Instances2Go haha sorry, I knew that code would not work, I just wanted to illustrate the logical conundrum, since I came to the same conclusion that you did... but did not have a solution besides my hacky one.

    As for your solution, thanks a lot, it looks cool... but it does kind of defeat the premise of the problem, which as the topic states, is that they are in the same family, not different ones. I could arbitrarily create another family, but it feels more like avoiding the problem. Still, it's basically a solution, so thanks.

  • Hey, so I've looked up a bunch of threads online (most of which were old) but could not find something to solve this issue of mine. Take a look:

    In short, I need to test for line of sight between an object in the "Fighter" family (e.g. a fighter in a fighting game) to another object in the "Fighter" family... but then the code "Fighter Type =/= Fighter.Type" is supposed to represent checking if the Fighter whose line of sight I am checking (codename "Bird") is the same type as the Fighter that was spotted--for example, if they are both Player, then the events won't do anything, but if one is Player and one is Enemy, then it should proceed with the next action.

    Solutions that won't work:

    • individual objects - this defeats the entire purpose of having families. I originally referenced the "Bird" object in the Fighter family manually, but this causes its own issues in the code, and is also inefficient, because then I have to manually attach line of sight behaviors for each enemy, and then write separate events for each as well (rather than writing a system for everything where I only need to specify LoS values and what to do when line of sight is detected).
    • what you see here - basically, the fighter being selected from the line of sight is different from the fighter checking the line of sight, but there's no apparent way for me to distinguish the two, and I'm not sure how C2 is coded to handle such things. (Similar question: what if two objects in the same family collide with each other? How do you pick each specific instance?)

    I'm not looking for exact code, but any tips/suggestions would help.

    The hacky solution would be to check against positions because I'm not actually using any instance variables on the "seen" fighter, but then I would need a for each loop to record the X and Y coordinates of every "player" fighter (usually 1, mind, but still) and then check line of sight against each of those... it might work, but it'd be less than pretty IMO, and I'd like to learn how I should approach this kind of problem anyway.

    Thanks~

  • lucid All good, I wrote that post before I e-mailed you and you fixed a bunch of issues. I ended up just trashing and remaking the animations (though I won't lie, since the animations in my game are kinda complicated and there were a lot, it was super tedious lol) and everything worked after that, so from now on it's just a matter of being super, super careful about updating.

    Honestly I think I just have bad luck with upgrading in general: it just took me an entire day to upgrade to Windows 10 and my computer nearly broke in the process, and I've had many issues with other things too, haha.

    But I know a little trouble comes with any program, so I apologize if I came off as impatient, I truly am hoping the benefits of Spriter in the long-run will outweigh any issues... with your help/support on occasion . Thanks~

    EDIT: Is there doc on all the variables/attributes/fields/whatever they're called of an SCML object? What about actions? Some of them don't have entirely clear purposes or distinctions and it would help to have such doc just to be sure (and so I can make the most out of all the features). For instance, what is objectx and objecty vs. x and y, does BBox____ return the bounding box of the SCML object or the actual animation frame, what are the different sound events for, etc.

    Also, for clarification, how exactly does the volume change in Spriter affect C2? Like how is a decrease in volume in Spriter ultimately reflected in C2? Through the audio itself, events, or something else I can't think of?

    Just want to make sure that my own volume controls don't end up say, overriding the sound volume of clips... not to mention if an audio file is played at different volumes and the volume change is somehow embedded into the audio (seems unlikely though) this would result in conflicts without having multiple audio files.

  • Hey lucid, how are you doing?

    So... to the point, I tried updating the scml plugin to version 7-9-16 from an older verison and it gave a probably not-very-helpful error (https://i.gyazo.com/dd9ec35330569c7afa6 ... 0d0684.png)

    I don't want the edittime error problem you had before but didn't see anything about it being fixed, and I also don't want to update to the new performance mode.

    So... is it safe to update to the latest plugin even if we were using an older version? Is there anything I should be concerned about? Trying to find out why an older version of a plugin doesn't work seems like a poor use of effort/time, but I also don't want to unknowingly incur some issues by upgrading (which I tested and SEEMS to work, but... I like to play it safe, haha).

    Thanks in advance.

    EDIT: Aaaand right after this I tried updating an animation (using the latest version of Spriter and the plugin) and got anotherr error

    Again, trying to decipher why this is happening seems like a futile task given how many variables there are, though I also can't afford to like, start over. Any ideas I should try or any specific info I can give to help get this sorted out?

    EDIT2:

    [quote:oddlytf0]So... while the C2 implementation of Spriter has never really worked well for me, after updating Spriter to r9 and the SCML plugin to version 7-9 and later the latest version, it's straight stopped working.

    So I tried different versions of the plugins, looked for an older version of Spriter (to no avail), tried resaving the CAPX, tried deleting the old object in C2 and re-inserting it, tried creating a new Spriter project and importing the old one into it, tried inserting into the example CAPX you created (since it doesn't have as much going on), and finally, tried creating a new Spriter project and inserting it into the CAPX, which is the only thing that actually works, but I really don't want to have to recreate all my animations. (I tried an older animation and just dropping it straight into the project works fine, but it seems like trying to update anything basically bricks it.)

  • > Found yet another bug with this program. If you have triggers such as sound triggers or event triggers and keyframes (presumably during the same time as a trigger) with the easing curve set to "instant" the triggers will activate many times. You can test this by just making a CAPX with a sound real quick and trying it, but if you really need a CAPX we'll try to get one over when we can

    >

    > I really just wanted to warn the public of this because it caused us endless amounts of grief, I debugged the game, plugin, SCON file, and SCML file, possibly in that order, I don't even remember anymore, and I only found the issue by using super-old-fashioned debugging methods I've been using for almost half my life, lol. It should have been much more obvious, but sometimes when you assume two things are unrelated, or make changes you *think* are small, surprises come up. XP

    >

    Just to be sure, this is a bug with the plugin, not the program, right?

    Yeah, presumably so, as it only happens in C2 and the SCML/SCON files look fine.

  • Found yet another bug with this program. If you have triggers such as sound triggers or event triggers and keyframes (presumably during the same time as a trigger) with the easing curve set to "instant" the triggers will activate many times. You can test this by just making a CAPX with a sound real quick and trying it, but if you really need a CAPX we'll try to get one over when we can

    I really just wanted to warn the public of this because it caused us endless amounts of grief, I debugged the game, plugin, SCON file, and SCML file, possibly in that order, I don't even remember anymore, and I only found the issue by using super-old-fashioned debugging methods I've been using for almost half my life, lol. It should have been much more obvious, but sometimes when you assume two things are unrelated, or make changes you *think* are small, surprises come up. XP

  • Ahhhh, ok, now I understand what you meant. Once I saw the code it made sense. I think I can get it to work now, thanks.