ID:265419
 
For my Megaman Game I have always used dense objects that bump for damage. Theres a few flaws in that, as the Gravity System I created...doesn' work as well as I would like it.

I was trying to think of some more ideas..but the only thing I can think of is check if the Bullet Enter() the player, or the player Enter() the Bullet... Think that would work? Or maybe some new ideas?
For my Megaman Game I have always used dense objects that bump for damage. Theres a few flaws in that, as the Gravity System I created...doesn' work as well as I would like it.

You're going to need to actually list the flaws and problems so people can help come up with solutions to them.
In response to Theodis
Flaws of bullets that bump
Its possible to jump and land on them. Just for a sec, to avoid them, becuase they are moving and you just fall of. etc...
In response to Sniper Joe
So set it up where if a mob bumps into a bullet they are hit (unless they are going the same way as the bullet, in which case it should be assumed that they are going around it).
In response to Nick231
Enter() the mob is the best possible way. you can't land on them, you can't shoot them back, and most importantly it delivers the same "damage" effect as Bump().
In response to Hiddeknight
Hiddeknight wrote:
Enter() the mob is the best possible way. you can't land on them, you can't shoot them back, and most importantly it delivers the same "damage" effect as Bump().

Enter() is called when an atom tries to enter another atom's contents. In the case of turfs that would be everything in the turfs location. For mobs and objs it isn't called unless you actually have it Move() into the mob/obj, or change around other procs.
In response to Nick231
In any case, you'd want Entered(), not Enter(). There is a subtle but highly important difference between their uses. (Namely, no side-effects - e.g. changes to the game world - should occur during Enter(). This is because it's often called by libraries, especially pathfinding libraries, to determine whether or not an object could enter the tile.)

As Nick nearly mentions, you'd have to implement it at the turf level, and then check for mobs inside the turf. =)
In response to Crispy
So, we are talking about the Bullet Entered() the mob. The So I would set the mobs layer or Bullets layer to TURF_LAYER?
In response to Sniper Joe
Layers? Who's talking about layers? I said turf level, not layer. Difference.

By "turf level", I meant as in turf/Entered() as opposed to mob/Entered(). The bullet is not entering the mob; it's entering the turf that the mob is in. Very important distinction. If it was entering the mob, it would show up in the mob's inventory (assuming you have inventory in your game). =P