System-wide object comparisons by instance variabl

0 favourites
  • 7 posts
From the Asset Store
Hand-painted tiles, objects, animated objects, and background to build a colorful Mayan civilization environment.
  • How could I go about writing an event that queries whether object_A has collided with *any* object that contains a certain instance variable that is equal to a particular value?

    The only way I can think of right now is to write a bunch of individual events each one comparing against a specific type of object (which would result in a massive event comparison) and than doing a sub-event condition querying for the variable value.

    Is there another way to do this? I couldn't find a global "parent" object class. Is this something that I could only do with the premium version which supports 'Families'?

    Thanks,

    cacotigon

  • It will be possible indeed.

    Atm you can check in a single event about the collision with object types belonging with the family.

    For the instance variable filtering, it's not yet implemented, it will be in the next releases.

    If this is something you're going to need, I'd stronlgy advise you to take an early adopter license today (it is the last day at the discount price).

    It is a matter of time/releases before the feature is implemented and stable.

  • Awesome! This is a really excellent program to tinker around with. After spending a few hours with it, I've already been able to mock up some simple platformer gameplay. In fact, so far, the majority of my time goes into using Paint Shop Pro and hand-editing my animated sprites to make sure that the walking/movement animations are smooth. I was experimenting with adding some enemies and I thought, why not set them to Platform behavior and use Simulate control events and invisible information sprites to trigger certain things within the level such as boundaries, etc. Works SOOOO WELL. I've got a pretty aged computer, and the framerate is actually not half-bad, which is amazing for a web app (Of course I'm not doing any rotations or anything fancy at the moment, so that could change).) though I also can't wait for other types of output such as standard windows executables.

    also thanks for the heads up about the early adopter license!

  • Good luck and welcome to C2. Also the rotation shouldn't do anything to your fps, I'm using interpolation on mine and it works nicely :)

  • Thanks! That's good to know about rotations. I'm so worried about performance that rather than doing opacity/transparency/etc in real-time for example for particle type effects, I was considering just creating individual frames in Paint Shop Pro using various effect filters and exporting as a tile-set. :)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • For the performances check this article out at "Canvas renderers" section. (the whole read is usefull as usual though ^^)

    As long as your browser can handle webgl and that graphic card drivers are up to date, you should be fine.

    In the case of rotations of sprites and stuff, all this should be handled by the GC and so free the UC for more computations.

    You just have to figure out where you at in the "technology map". <img src="smileys/smiley1.gif" border="0" align="middle">

  • Kyatric thanks for that link; just finished reading it. I didn't realize that the Javascript garbage collection could be such a performance killer, provided I followed proper disposal practices, I never really had to worry about something like that before in C#.

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