1
\$\begingroup\$

I am working on a game that has words as obstacles, i.e. the player needs to climb over and around them. There will be hundreds of words in the game therefore I need a way to automate the placement. I figured out how to create an object with a TextMesh in Unity but I can't figure out how to automatically generate a collider so that I can have the player interact with it. I know that there is a way to edit the verticies of Edge and Polygon colliders but I don't have a source for editing them. What would be useful is a getPoints method of the TextRender but it seems like there is no way to get that. Am I going about this the right way? Thanks in advance.

\$\endgroup\$
4
  • \$\begingroup\$ I cant seem to find this TextRenderer. Do you mean Text Mesh ? Please share your code where you generate the words. \$\endgroup\$ Commented May 18, 2016 at 7:47
  • \$\begingroup\$ Yes I did, I just edited the post to fix that. I don't have any code for generation yet, right now I'm working on just creating any text with a fitted collider attached. \$\endgroup\$ Commented May 18, 2016 at 11:28
  • \$\begingroup\$ so why doesn't attaching a box collider work? Or do you require more precision than the humble box collider ? \$\endgroup\$ Commented May 18, 2016 at 11:31
  • \$\begingroup\$ I require more precision. I need the player to be able to interact with each part of each letter. \$\endgroup\$ Commented May 18, 2016 at 11:46

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.