Question by
lrslssk · Mar 17, 2018 at 12:12 AM ·
2dscripting problemsprites
Drawing Sprite between 2 points at runtime
Hello, I want to make a simple game in which you have to catch flys with a frogs tongue. The frog is sitting on the ground while the flys are flying above him. To catch the flys you have to swipe/fling. The frog will then stretch his tongue in the direction of the swipe.
Here you can see the basic setup, hopefully it will make the idea of the game clear: https://i.imgur.com/SJsg9jp.png
My initial idea was to shoot a ball (which you can see on the frog's mouth) by swiping and then drawing his tongue at runtime between his mouth and the current ball position. I have yet struggled to write any code which works that way. Are there any more elegant ways to implement this?
Comment
Your answer
![](https://koobas.hobune.stream/wayback/20220612154742im_/https://answers.unity.com/themes/thub/images/avi.jpg)