i have no experience in unity and this is my first game so please be a bit patient with me, thankyou
so in the game im making the picture in the middle is covered in 20 pices of black square and the dagger is thrown and it removes the part that was hit, how do i spawn the 20 black squares in equal size and how do i make the hit boxes and damage system?
#how do i spawn assets equaly in different positions?
1 messages · Page 1 of 1 (latest)
what you asking has a lot of moving parts, perhaps you might need to start with a simpler project if this is your first time
for starters you'd need to make black squares , they'd either have to be Tiles from the Tilemap and use that system to remove them
or use GameObjects individually then place them through code via looping a 2D grid or similar type
i desided to just put only 10 squares and put em in manually
but i still need help on how to move em
what do you mean "move em" what pretty vague, movement can have different meanings in unity
mb
move as in the dagger moves and damages the block when you hit the left click
so
each of the blue boxes will change color each round , and the one that changed color must be hit by the dagger that is floating up and down , my questions are
1.how do i make it so that the box changes color every round
2.how do i make the dagger throwable
- if the color is meant to be fixed create an array or a field for as meny colors as you need then swap the index accordingly each round
- this is pretty vague, thrown how and from where ?
typically you would find the target position - currentPosition then you can normalize it to get your direction of travel, then perhaps youd use a collider or something to detect hits.
There are methods with raycasts too, many ways to solve the same problem