saiyadjin's Forum Posts

  • yes, that's exactly what i needed, didn't think of it before (different animations ),

    thnx a lot!

  • i have a weapon that shoots canonballs

    now since i have different collisions with different objects i had to make events for each on collision differently.

    (some are hit differently from the others)

    anyway now i want to add another type of bullet (let's say fireball for example), and i want everything else to work

    exactly as it is, but i don't want to duplicate code.

    so if i put events like this:

    cannonball  on collision with object
    or
    fireball on collision with object           -  do something.. blah blah, and then... destroy fireball, destroy cannonball[/code:3vi72xa8]
    
    is this a good practice? will it bug out when there's no cannonball ?
  • [quote:2kkzvvzt]hey somebody i'd love you to make a fireball effect. - takin' a round object and applying fire to it. also when that object moves (with bullet or such behaviour) to show a little trail

    i've searched up and down for this effect but couldn't find any :/

    let me rephrase this - there would be nice if we got an effect of fire burning, when applied to object - make that object burn in upwards direction (when rotated flame should also change it's direction) - would be usefull for static fire effects, fireballs, and more.

  • this is a math problem more less..

    now i have a boat - it has 6 weapon levels.

    level 1 - shoot forward

    level 2 - shoot forward and left at the same time

    level 3 - shoot forward left and right at the same time

    level 4 - shoot forward different bullets

    level 5 - shoot forward and left different bullets

    level 6 - forward left and right different bullets.

    now i'm tryin' to optimize this code as much as i can and i've already reduced code from 6 subevents to 3,

    but i can't figure how to translate weapon level (1,2,3,4,5,6) to number of bullets (1,2,3,1,2,3). any ideas?

    also how would i use the 1,2,3,1,2,3 for shooting in angles (1 - forward, 2 - forward and left, 3 - forward left and right)?

  • yes there is:

    you can join microsoft academy (Free) - and then watch this -

    http://www.microsoftvirtualacademy.com/ ... evelopment

    they showed in part 3 (I think) how to export to windows phone.

  • Don't go away yet! From top of my head, here are mine!

    Behaviours:

    RTS Plus - Moving objects can avoid each other, too not to bump or overlap each other.

    Array Plus - you can name columns and rows for ease of requesting data.

    Plugins:

    2d pathfinding - Pathfinding for 2d games, includes following other object.

    these are already here - pathfinding can make sure you don't bump or overlay stuff depending on your grid size. if you use too small they will, bigger - they won't.

    also following is simple - use "every x sec - > find path to (objectyouwantofollow.x, objectyouwanttofollow.y), move along path)" also set x to something like 0.2 sec or 1 sec. if you have a changeable space - use regenerate obstable map somewhere before also each 0.2 sec or 1 sec (it's good enough once for static objects)

    array plus - not sure if it can be done. C# has datatable that has datarows that can use "COLUMN" names for getting data from a column, or cell, but i think JavaScript has nothing like this that would support it easily.

  • oh, then i saw it somewhere else probably, i was pretty sure i saw pow in here, guess i didn't after all

  • you need a glow effect, check in effects for it, i think someone made it already.

  • umm crimsonland.

  • i'd always use math.pow (pow in events), using ^ sometimes gives wrong results because in javascript ^ is not pow really.

  • something like this:

    set position y = time , X = (pick a number of pixels) * Math.POW( Math.E, -(pick a small number for absorption)*time) * sin (any number * time - any number to 90)

    though this is just simplified version. you will still have to play with it. try x = width /2 and y= time and see what happens. your sprite should travel on the midscreen from pixel 0 downwards until it leaves layout without wobbling.

    then play with X value and you have your solution. if you want wobbling exactly as on picture, you will have to do some math - calculting the point of 70% of sinus where you will start changing your y value for a sec so it rotates back, and then disabling it until it hits next 70% but with reduced amplitude... and repeat until amplitude is ~0 then you stop it.

    it's kinda hard truly, needs at least 2 subevents, maybe there is some kind of plugin that does that already, but i don't know really any.

  • if blob is included in the family then he gets all families instance vars.

  • external arrays work the best.

    you define them and load into c2 and that's pretty much it. ancillary said it all

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • do the layer thing. also you could apply effect on that layer with opacity around 20-40 - darken or overlay. will change colors of items and all. play with it

  • is your rendering mode Linear? do you use pixel rounding property? (select your PROJECT and check your properties)