Prominent's Forum Posts

  • I want to be able to create an object, specifying whether to add the instance to the front of the instance array or the back.

  • Instances are identical. Unless you know something we don't.

    No they aren't, that's why there is an array of instances, to hold all the different ones. When there is no SOL, it references the type.instance[] array. Pick Nth Instance would pick based on the index of that array.

    I'm looking to see if I can create a plugin that can reorder the type.instance[] array. Not sure if it can, but even so, would be nice to have this implemented without needing a plugin.

  • 99Instances2Go ,

    An object type has an array:

    type.instances[]

    This holds essentially a list of instances, and when you create a new instance, it gets added to the end of it.

    What I want is an option to add to the beginning of that Array.

  • What sort of collisions do you have in mind, mxwring ? Will you be using a tilemap?

    You could for example use a tilemap to represent colideable areas, and have a regular Sprite, to collide with the tilemap. Then you could position the q3dsprite to the Sprite's position. It also would get more complicated if you want to be able to jump ontop of stuff or walk underneath things- in which case, a tilemap may not be enough. If that's the case, I'd probably create my own collision checks using the q3draycaster against a 3d model that represents the colideable area.

    But yea.. depends what you have in mind I guess.

  • I'm not sure what is so difficult to understand here. You have a list of instances. You create one, and it is added to the end of that list by default.

    Now, if I have an event to Pick Nth Instance, it picks based on the order of that list.

    For example:

    I create 5 instances, and they are ordered in succession. I can Pick Nth Instance with Instance.count-1 to choose the last one that was created. Or I could pick 0, the first instance created. I don't care when they were created, because I know which one I can pick because I know the order they are in.

    Now, these 5 instances- their order is important, but I need to destroy the first instance and create a new instance in its' place. Destroying the first instance is simple. But now, my code, which can easily just pick instance with iid=0, will pick the second instance that was originally created- not the new one I'm creating.

    So, instead of it being easy and allowing me to create the instance at the front of the list, I have to create at the end of the list and now use a second piece of data to represent its' order. Or I have to reposition the previous ones, transfer their properties to each other if they have any, etc..

    If I could just create instance and choose to create it at front of list, I can avoid all the extra stuff. It should be pretty obvious the benefits?

    So yeah, I know it can be done other ways, but the point here is to make things better/easier/quicker/etc. When you start making complicated programs, these little things can be extremely useful.

  • It wouldn't replace any object. I want to create an object at the front of the list, prepend it to the list.

    This is something I think would be easy to implement, Ashley?

  • Ashley , would be nice to have a choice to either push to back or to the front of the list when creating objects. I know it may seem like a rare case that a person would want to do this, but it would make certain things easier and require less events/etc.

    As it is now, I can't accomplish what I want without having to create variables to record UIDs, and then extra events to pick them appropriately. I am forced to create more clutter due to the instance list being ordered only one way, and having to recreate that order differently through variables,events.

  • I want to create an instance by pushing it onto the beginning of the instance list instead of the end. So if I have 5 instances and I add another, how do I get it so the new instance has IID = 0.

    How do I accomplish this!?

  • If you need to change all instances regardless of which instances get picked or don't get picked, you can add a Pick All after the Or condition in a sub-event.

    I've been confused like you regarding how Or events work, but it is manageable once you understand them.

  • 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 publish the game on Greenlight, please support this game

    https://youtu.be/mdhajVFIMeo

    Looks good, I voted

  • Looks and feels great so far!

  • This one has a good introduction:

    https://thebookofshaders.com/

  • Problem Description

    If tilemap is on a rotated layer with solid behavior, and sprite on another non-rotated layer with platform behavior, it doesn't collide correctly.

    Something weird with collisions/layers- not just platform/tilemap?

    Attach a Capx

    https://1drv.ms/u/s!AhHSZHEulqh_gTc7qP-MQXv-igxG

    Description of Capx

    tilemap and sprite collision

    Steps to Reproduce Bug

    • run layout

    Observed Result

    sprite doesn't move

    Expected Result

    sprite should fall and collide with tilemap

    Affected Browsers

    • Chrome: (YES)
    • FireFox: (YES)
    • Internet Explorer: (YES)

    Operating System and Service Pack

    vista sp2

    Construct 2 Version ID

    r227

  • I know, you probably don't have much time to fix stuff with this plugin R0J0hound , but thought I would mention that if I have chipmunk objects on two separate layers, and one layer has a different angle set, objects only use the angle of the layer they are currently on.

    So when colliding, the layer angle isn't taken into account if the object they're colliding with is on a different layer.

    Hope that makes sense.

    I test this with tilemap on a rotated layer, and an object on another non-rotated layer. Object acts as if tilemap isn't rotated. If the object is put on same layer as tilemap, then it acts as if it is rotated.

    Maybe it is a C2 issue?

    edit:

  • alright, I'll do that- thanks <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

    edit: https://github.com/nwjs/nw.js/issues/5011