Advertisement
Serafim

Untitled

Oct 8th, 2013
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.     apply: (parser) ->
  2.       y1 = 52
  3.       y2 = 70
  4.  
  5.       parser.parse [
  6.         {Rect:  x: 0, y: 0, width: 320, height: 100, color: '#900'}
  7.         {HLine: x: 0, y: 100, width: 320, color: '#000'}
  8.  
  9.         # HEADER PANEL
  10.         {Rect:  x: 0, y: 0, width: 320, height: 31, color: '#550406'}
  11.         {HLine: x: 0, y: 31, width: 320, color: '#3d0305'}
  12.         {HLine: x: 0, y: 32, width: 320, color: '#9e070c'}
  13.  
  14.         {Rect:  x: 0, y: 0, width: 31, height: 31, color: '#3d0305'}
  15.         {Image: src: 'assets/images/layout/menu.png', x: 0, y: 0, width: 31, height: 31},
  16.         {Label: text: "КОРРУПЦИЯ", x: 124, y: 21, shadow: '#000', color: '#fff', font: 'bold 16px Arial'}
  17.  
  18.         # Текст банк
  19.         {Image: src: 'assets/images/icons/header/ruble.png', x: 8, y: y1 - 10, width: 20, height: 17}
  20.         {Label: text: '1 124', color: '#fff', font: 'bold 12px Arial', y: y1+2, x: 33, shadow: '#790509'}
  21.         {Label: text: '(999 в банке)', color: '#fff', font: '10px Arial', y: y1, x: 66, shadow: '#790509'}
  22.         {Label: text: '+ 6 512 через 19:52', color: '#dcf372', font: '10px Arial', y: y1, x: 133, shadow: '#790509'}
  23.  
  24.         # КЦ
  25.         {Image: src: 'assets/images/icons/header/chain.png', width: 17, height: 17, y: y1 - 12, x: 270}
  26.         {Label: text: '32', color: '#fff', font: 'bold 12px Arial', y: y1+2, x: 294, shadow: '#790509'}
  27.  
  28.         # Уровень
  29.         {Image: src: 'assets/images/header/level-bar.png', x: 8, y: y2, part: [0, 0, 36, 25], width: 36, height: 25}
  30.         {Image: src: 'assets/images/header/level-bar.png', x: 8+36, y: y2, part: [0, 50, 36, 25], width: 251, height: 25}
  31.         {Image: src: 'assets/images/header/level-bar.png', x: 240+36, y: y2, part: [0, 25, 36, 25], width: 36, height: 25}
  32.  
  33.         {Label: text: '25', color: '#fff', shadow: '#000', font: '11px Arial', x: 16, y: y2 + 17}
  34.         {Label: text: '26', color: '#fff', shadow: '#000', font: '11px Arial', x: 304, y: y2 + 17, align: 'right'}
  35.       ]
  36.  
  37.       # анимация
  38.       img = new JSRender.Primitives.Image src: 'assets/images/header/exp.png', width: 5, height: 15, x: 8+36, y: 75
  39.       img.before @render
  40.  
  41.       int = 3
  42.       setInterval =>
  43.         if img.width() > 220 then int = -3
  44.         if img.width() < 1 then int = 3
  45.         img.width(img.width() + int)
  46.       , 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement