Author Topic: draw line, rectangle into panel  (Read 4857 times)

eliascanaza

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 25
    • View Profile
draw line, rectangle into panel
« on: September 15, 2014, 12:27:10 PM »
Hi everyone,

I need draw line, rectangle and others into panel, this panel is will moving, Please help me.

Nicki

  • Global Moderator
  • Hero Member
  • *****
  • Thank You
  • -Given: 33
  • -Receive: 141
  • Posts: 1,768
    • View Profile
Re: draw line, rectangle into panel
« Reply #1 on: September 15, 2014, 06:42:24 PM »
Make a line, rectangle and others images, put them into a UIAtlas and draw them as UISprites.
Draw them inside a UIpanel that has the Offset checked, so you can move it and its children with the panel.transform's localposition.

If you want anything more detailed, you're gonna have to ask in more detail. For now, look inside the examples folder that comes with NGUI, there's examples of most of the basic stuff.

eliascanaza

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 25
    • View Profile
Re: draw line, rectangle into panel
« Reply #2 on: September 15, 2014, 10:06:44 PM »
hi, i dont see this examples in the examples folder, there are many examples but with images and dont with draw line, rectangle with code... i need examples how draw line, rectangle and others with code c# and that will is into panel for moving, thnks

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: draw line, rectangle into panel
« Reply #3 on: September 16, 2014, 09:30:15 AM »
NGUI is a UI library, not a line drawing library.

If you need a line drawing library, look at Vectrosity.

eliascanaza

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 25
    • View Profile
Re: draw line, rectangle into panel
« Reply #4 on: September 17, 2014, 10:24:15 AM »
ok, the other option would be it shows a line image ... thanks