1. #1

    Help with skillgame please

    Hi.

    I have been wanting to build a Shmup bullet hell style skillgame for a while now. started it the other day and got some stuff working, but i was wondering if anyone would be able to point me in a direction to get collision to work between the bullets and the player.

    http://xboxclips.com/Hairy+Cabbage/0...7-800b464bac3a

    The bullets are fired by emitters. They shoot physical particles, but i cant use default collision otherwise they will collide with each other and i cant have that. The player is also physics turned on and can be on default. Also, If this isnt possible with emitters, could someone possibly point me in a new direction?

    ty
    Share this post

  2. #2
    Waistless's Avatar Member
    Join Date
    Nov 2014
    Location
    Australia
    Posts
    137
    Try setting the advanced physics of the bullets to "no contact response"? This will get rid of their collisions, but you can still use on hit triggers to register collisions between the bullets and the player.
    Share this post

  3. #3
    Since you are viewing the field from the top, you could stack the bullet types in layers and make the player either thicker, or add a collision box around them. Even if the bullets did collide with each other, the only game-breaking flaw would be them bouncing off. Though perhaps a boss could create spheres that did this, just to make things more dicey for the player .

    Another way would be to make everything visible on the main layer with no collisions, then use invisible bullets fired at the same time at different layers against an invisible ship that records the hits. The player and bullets seen would be the visuals, and the invisible collisions would be the actual code working behind the scenes.

    Share this post

  4. #4
    Bullet bouncing is out of the question. It removes 99% of possible patterns and would just create a random mess. Thats not what im looking for. And no collision doesnt send an impulse on collision.

    Originally Posted by JolanXBL Go to original post
    Another way would be to make everything visible on the main layer with no collisions, then use invisible bullets fired at the same time at different layers against an invisible ship that records the hits. The player and bullets seen would be the visuals, and the invisible collisions would be the actual code working behind the scenes.


    Wouldnt this be exactly the same as just using the regular bullets. i mean surely the invisible bullets would just bounce off each other and thus wouldn't actually be following the original pattern and then you would be dying in random places without knowing why?
    Share this post

  5. #5
    Originally Posted by Waistless Go to original post
    Try setting the advanced physics of the bullets to "no contact response"? This will get rid of their collisions, but you can still use on hit triggers to register collisions between the bullets and the player.
    Vantier told me you made your boss fight without using emitters. is this true? and if yes, how complicated was it to do?

    Edit: so it turns out, no contact response with custom colissions does actually work, so i could possibly fire those underneath the visible bullets

    Edit2: ok u cant fire custom cilissions from emitters. rip
    Share this post

  6. #6
    Waistless's Avatar Member
    Join Date
    Nov 2014
    Location
    Australia
    Posts
    137
    He's correct, I didn't use emitters, I used OPEs.

    http://steamcommunity.com/id/Waistle...31175189567841
    http://steamcommunity.com/id/Waistle...31175194807859

    And yes, it was complicated (relatively, but with programming experience its something I knew how to build).

    For a single attack phase: it involves setting up 3 arrays to 32 copies of a logic chain to control an individual OPE for every single projectile (so effectively 32 virtual functions). The projectiles themselves are in an array of 128 them. There is also a main control loop to loop through the virtual functions to fire each projectile.

    Pretty scalable solution though, for more attack phases, just copy and paste the whole page of logic and projectiles, and change what goes on in the main loop to make a different attack phase. The limit of 32 OPEs active at once I can increase just by copying and pasting more of those logic chains etc.

    (also note, to send impulses through an array, attach a variable data source to enable/disable on a single-impulse interval trigger, set value to 1 on array > data source)
    Share this post

  7. #7
    Any chance of you being able to talk me through it possibly if i were to start a stream up or something? <3
    Share this post

  8. #8
    Waistless's Avatar Member
    Join Date
    Nov 2014
    Location
    Australia
    Posts
    137
    Maybe, but trying to talk someone through replicating this would be an absolute nightmare I think. If you have the game on PC I could send you the I wanna kill the syndi track file though, so you can look at the entire thing that way. (track needs season pass dlc).

    Still the way it looks like you have it set up using emitters is just as good, surely you can register collisions on your own using on hit triggers? (so on hit object 1 player object *type* 2 bullet > lose HP etc.) Those triggers should work even while using no contact response in advanced physics on the bullet that emitter is set to emit.
    Share this post

  9. #9
    Originally Posted by Waistless Go to original post
    Maybe, but trying to talk someone through replicating this would be an absolute nightmare I think. If you have the game on PC I could send you the I wanna kill the syndi track file though, so you can look at the entire thing that way. (track needs season pass dlc).

    Still the way it looks like you have it set up using emitters is just as good, surely you can register collisions on your own using on hit triggers? (so on hit object 1 player object *type* 2 bullet > lose HP etc.) Those triggers should work even while using no contact response in advanced physics on the bullet that emitter is set to emit.
    I cant seem to get this working, and its really annoying that it doesnt because it would make my life soo much easier...
    Share this post

  10. #10
    Waistless's Avatar Member
    Join Date
    Nov 2014
    Location
    Australia
    Posts
    137
    ok I see the problem. "will still send impulses on collision" BAD LYING EDITOR >.<

    Here's what you can try, with the original bullet still on no contact response, glue it to the SMALLEST OBJECT YOU CAN FIND that has physics set to default/contact response on, have it *inside* your bullets so that your bullets wont collide with each other unless they get right on top with each other, but will still make contact with your player of which the physics is the full size. Set your emitters to that new glued object.

    Effectively you want to create an ultra-tiny hitbox on the bullets.

    Oh, to compensate you'll want to have a proportionally bigger custom hitbox for the player character, so use a contact response on invisible object around the player character, and that will be what you want to use your on hit triggers for the tiny bullet hitboxes with.
    Share this post