# Kinemetics jittering issues with bullets(SOLVED)

**URL:** <https://forum.defold.com/t/kinemetics-jittering-issues-with-bullets-solved/68635>\
**Category:** Questions\
**Created:** [June 14, 2021, 8:16am UTC](https://forum.defold.com/t/kinemetics-jittering-issues-with-bullets-solved/68635 "2021-06-14T08:16:47Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![vikash](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/vikash/32/22674_2.png) [@vikash](https://forum.defold.com/u/vikash)\
**Post date:** [June 14, 2021, 8:16am UTC](https://forum.defold.com/t/kinemetics-jittering-issues-with-bullets-solved/68635/1 "2021-06-14T08:16:47Z")

</div>

After resolving kinemetic collisions of bullet with walls by following code

```
function handle_obstacle_contact(self, normal, distance)
	local proj = vmath.dot(self.correction, normal)
	local comp = (distance - proj) * normal
	self.correction = self.correction + comp
	go.set_position(go.get_position() + comp)

	if normal.y > 0.7 then
		self.ground_contact = true
	end

	proj = vmath.dot(self.velocity, normal)
	if proj < 0 then
		self.velocity = self.velocity - proj * normal
	end
end

```

jittering issues with walls fixed but in case of enemies/bricks its not sometime scollisions issues happen when bullet collide inbetween of two enemies with collision shape

---

<div class="post-metadata">

**Author:** ![vikash](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/vikash/32/22674_2.png) [@vikash](https://forum.defold.com/u/vikash)\
**Post date:** [June 14, 2021, 3:42pm UTC](https://forum.defold.com/t/kinemetics-jittering-issues-with-bullets-solved/68635/2 "2021-06-14T15:42:52Z")

</div>

After doing lots of reading I have found solution that I have to use raycast.
