keepee's Forum Posts

  • Just realised, if you use:

    'For each chain order by distance(chain.x,chain.y,red.x,red.y) ascending'

    then it will order the chains going from red, regardless of direction.. so you can have it going up right down etc.

  • sorry, I don't have an answer but i am compelled to ask why you'd want to set the timescale so high?

  • One way to do it would be to add an instance variable to the object (Can't think of a good name so I just used 'B') and an event with the system condition:

    "for each object by order of Object.RandomValue ascending"

                 --> set object.B to loopindex

    This will number each object.B by the order in which it was picked. going from 0,1,2,3 .. etc

    Then in a separate event, to pick the highest, you can do

    Object.loopID = object.count-1

          -->set scale to... etc

    the -1 is necessary because the 'loopindex' expression is 0 based (0,1,2,3..), but the 'count' expression isn't (1,2,3,4..)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • you're right, it seems to detect overlap when it's simply against. Maybe it's supposed to work that way? I'm not sure.

    Anyway here's a cap with a few changes:

    capx

    The main thing is I just made the collision polygon a slighly smaller square.

    I thought i saw some picking problems so i just instinctively added the 'for each' condition, it might not be necessary though.

    The detect variable is so it doesn't have to check for overlaps every single tick.. collision detection is relatively more cpu heavy than most actions..apparently

    and the set x to (int(self.x/16))*16 is just to add snapping.

  • If you are using the physics behaviour, then i'd see if enabling 'bullet' mode in the properties would help. I don't know the details of it, but it basically gives the object more precise collision detection.

  • Firstly, it may not be id'ing them correctly from left to right..

    if you leave "order by: " blank, then I assume it will pick them based on the order they were created within the layout editor.

    so either make a system that creates the chain objects on startup inbetween 'Red' and 'wall', or for now you can simply do "order by chain.x ascending", this will pick them from left to right.. (so bare in mind that this wont work if you want the chain to go in other directions)

    next there are some picking problems with chain and link..

    Im not sure if you just followed example, or you figured out for yourself, but the reason it's good to use a family here is to help make it clear what instances your action is referring to.

    For example having "chain: create joint to chain" will make it confused as to what chains to pick

    but having "chain: create joint to link" means that, in the conditions, you can specify what chain, and specify what link. Even though a link is just a chain, it allows you to pick two seperate chains. It's awkward, yes :)

    so anyway..

    link: id ? 3

    should be

    chain: id ? 3

    and for the last two events you just need to be consistent with whether your choosing link or chain.

    the "link:id=0" event i think is fine, but the "link:id=3" event then goes on to refer to a chain instead.

    for simplicity and ease of reading the sheet i'd replace all occurences of 'link' in those last two events with 'chain' instead

  • You'll get a better response if you explain in more detail, and maybe post the .capx file.

  • I don't know if it's been fixed -but i'm pretty sure having groups underneath a For each condition used to break it.

    See if placing one as the first event in each group fixes it

  • This probably isn't the solution to the problem, but you should use *dt instead of /60.

    dt stands for delta time and is the amount of time (in seconds) since the last tick... so it'll change with any frame rate dipping.

    Micro-jitter of 1 pixel makes me think of the 'pixel-rounding' project property. Other than that I'd suggest posting your capx

  • sqiddster, It sounds like I have a similar problem, where, for lighting, I have a black layer with the blend mode 'multiply' which basically darkens everything that's not lit up, however I want the background layer to be unaffected by this darken effect and to retain it's own brightness (due to it being in the far distance)

    You said 'source atop' works? What did you apply this to? I've tried a few things but nothing seems to be working.. thanks

  • 7Soul, reread what you quoted.. E creates an event and opens the conditions window, if you close that then it deletes the space. I can't speak for everyone but frequently all I want is the blank event to copy and modify existing conditions into the space.

  • Global and instance variables grouping would be very useful.

    this is what currently takes up an entire screen on my current project

    https://dl.dropbox.com/u/53374990/Forum/GlobalVars.png

    For storing objects though.. it seems what you described you can already do that with UID's

    for example:

    For each character

    create HPbar

    set instance variable character.HPBarUID to HPBar.UID

    And then when you need to pick that HPBar you just need "pick by UID character.HPBarUID"

  • Rory

    I think for saving dev time, the ability to select and edit properties of multiple layouts is the most important thing on the list. Handling a 20+ layout project and wanting to change one thing is such a pain in the ass.

    by the way I feel like this reads as one massive moan, but really I love c2's interface.. it's much better than stencyl and gamemaker.

  • You could either leave the origin in the centre and have it snap to a 16x16 grid

    or set it's position alongside rotating it like:

    set angle to 90

    set x to self.x+self.width

    but of course a different position would be needed for each angle.

    If you need them to rotate more than once, so it works regardless of their current angle, you could have an imagepoint in each corner.

    So for rotating 90 degrees:

    set position to self.imagepoint(TopRight)

    set angle to self.angle+90

    and for rotating 180 degrees

    set position to self.imagepoint(BottomRight)

    set angle to self.angle+180

    etc

    ps: this should have been posted in the 'how do i' forum

  • Yep that's right

    but why not just try it yourself?