Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

drawing lines with different angles/ c# help please :(

Discussion in 'Scripting' started by verderveremem, May 31, 2014.

  1. verderveremem

    verderveremem

    Joined:
    May 11, 2014
    Posts:
    52
    i want to make draw heart beating by using script and i want to make this with different angles and randomly.

    basically i just want to give one pixel image to the script and then i want it to make it like just like in the picture which is


    $kalp-ritmi-bozukluklari.jpg
     
  2. verderveremem

    verderveremem

    Joined:
    May 11, 2014
    Posts:
    52
    help me please :(
     
  3. Graham-Dunnett

    Graham-Dunnett

    Unity Technologies

    Joined:
    Jun 2, 2009
    Posts:
    4,287
    What help do you need? Do you have an equation for the heart beat signal? Do you have problems drawing the lines?
     
  4. exiguous

    exiguous

    Joined:
    Nov 21, 2010
    Posts:
    1,749
    Albeit i don't like the impatient ones (2 hours bump!) some ideas from me.
    Displaying any kind of lines or dots is done best with the Vectrosity package from Eric Haines (Eric5h5) which you can purchase in the asset store.
    You could also fake the effect by drawing the heart line in a graphics program (gimp, paint.net) and then display it on a quad and "scroll" it. The free unity space shooter tutorial (asset store) shows how to seamlessly scroll the background. so you could get some hints and examples there.
     
  5. renman3000

    renman3000

    Joined:
    Nov 7, 2011
    Posts:
    6,680
  6. verderveremem

    verderveremem

    Joined:
    May 11, 2014
    Posts:
    52
    the user will be not draw the lines, it will be drawn on run time, how can i do this?

    thanks
     
  7. verderveremem

    verderveremem

    Joined:
    May 11, 2014
    Posts:
    52
  8. renman3000

    renman3000

    Joined:
    Nov 7, 2011
    Posts:
    6,680
    So if its not constantly updated, or even it it is, you can set the number of verticies, in the line and thier positioning.

    So, verticie 0, pos 00, verticie 1, pos 1,10 etc.