- Home /
dragging objects horizontally in a grid or in increments
Hi Just to clarify.. I am a complete rookie at programming. I want to make a simple puzzle. For this I need the player to be able to click and drag a gameobject horizontally. It is important that the gameobject (which is a cube in this case) moves in a grid.. or in increments so it seems like a grid. I found the script below... however I cant seem to get it to move in increments. How should I go about doing this? Pseudo-code or actual code will be greatly appreciated!
http://www.unifycommunity.com/wiki/index.php?title=DragObject
Really no one? Hmm
Answer by Meltdown · Apr 04, 2012 at 09:00 PM
Use the search feature.. This has been asked many times...
http://answers.unity3d.com/search.html?redirect=search%2Fsearch&q=cube+snap
Answer by effix · Apr 04, 2012 at 10:17 PM
I have used it. And i havnt a answer that i could use...so therefor i post this question.
This isn't an answer to the question. Use the Comments section, it's not as if it isn't there.
Your answer
![](https://koobas.hobune.stream/wayback/20220613065757im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Drag to grid script help? 1 Answer
Grid and or Tile System 0 Answers
Grids for begginers? 0 Answers
Unity Grid Drag Implementation 0 Answers