Advertisement
Guest User

Untitled

a guest
Jan 13th, 2017
122
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.59 KB | None | 0 0
  1. include('shared.lua')
  2.  
  3. function ENT:Draw()
  4. self:DrawModel()
  5. end
  6.  
  7. // Realised by HamsterOh
  8. // Please do not say: "I'm the creator of Rndows"
  9.  
  10.  
  11. surface.CreateFont( "Username", {
  12. font = "Arial",
  13. extended = false,
  14. size = 25,
  15. weight = 500,
  16. blursize = 0,
  17. scanlines = 0,
  18. antialias = true,
  19. underline = false,
  20. italic = false,
  21. strikeout = false,
  22. symbol = false,
  23. rotary = false,
  24. shadow = false,
  25. additive = false,
  26. outline = false,
  27. } )
  28.  
  29. surface.CreateFont( "Password", {
  30. font = "Arial",
  31. extended = false,
  32. size = 40,
  33. weight = 500,
  34. blursize = 0,
  35. scanlines = 0,
  36. antialias = true,
  37. underline = false,
  38. italic = false,
  39. strikeout = false,
  40. symbol = false,
  41. rotary = false,
  42. shadow = false,
  43. additive = false,
  44. outline = false,
  45. } )
  46.  
  47. surface.CreateFont( "Connect", {
  48. font = "Arial",
  49. extended = false,
  50. size = 25,
  51. weight = 500,
  52. blursize = 0,
  53. scanlines = 0,
  54. antialias = true,
  55. underline = false,
  56. italic = false,
  57. strikeout = false,
  58. symbol = false,
  59. rotary = false,
  60. shadow = false,
  61. additive = false,
  62. outline = false,
  63. } )
  64.  
  65. surface.CreateFont( "Info", {
  66. font = "Arial",
  67. extended = false,
  68. size = 20,
  69. weight = 500,
  70. blursize = 0,
  71. scanlines = 0,
  72. antialias = true,
  73. underline = false,
  74. italic = false,
  75. strikeout = false,
  76. symbol = false,
  77. rotary = false,
  78. shadow = false,
  79. additive = false,
  80. outline = false,
  81. } )
  82.  
  83. function ComputerPanel ()
  84.  
  85.  
  86. local LS_invisiblebackground = vgui.Create("DFrame") // Don't delete this frame !
  87. LS_invisiblebackground:SetTitle("")
  88. LS_invisiblebackground:SetZPos(2)
  89. LS_invisiblebackground:SetPos(ScrW()/2-400, ScrH()/2-300)
  90. LS_invisiblebackground:SetSize(800,600)
  91. LS_invisiblebackground:SetVisible(true)
  92. LS_invisiblebackground:SetDraggable(false)
  93. LS_invisiblebackground:ShowCloseButton(false)
  94. LS_invisiblebackground:MakePopup()
  95. LS_invisiblebackground:SetDeleteOnClose(true)
  96. LS_invisiblebackground:SetScreenLock(true)
  97. LS_invisiblebackground.Paint = function(s , w , h)
  98. draw.RoundedBox(0,0,0,w,h,Color(0, 144, 255, 0))
  99. surface.SetDrawColor( Color( 0, 0, 0, 255 ) )
  100. surface.DrawOutlinedRect( 0, 0, 800, 600 )
  101. end
  102.  
  103. local LS_usernamebar = vgui.Create("DPanel", LS_invisiblebackground)
  104. LS_usernamebar:SetZPos(3)
  105. LS_usernamebar:SetPos(300, 300)
  106. LS_usernamebar:SetSize(250,25)
  107. LS_usernamebar:SetVisible(true)
  108.  
  109. LS_usernamebar.Paint = function(s , w , h)
  110. draw.RoundedBox(0,0,0,w,h,Color(255,255,255,255))
  111. surface.SetDrawColor( Color( 0, 0, 0, 255 ) )
  112. surface.DrawOutlinedRect( 0, 0, 800, 600 )
  113. end
  114.  
  115. local LS_passwordbar = vgui.Create("DPanel", LS_invisiblebackground)
  116. LS_passwordbar:SetZPos(3)
  117. LS_passwordbar:SetPos(300, 260)
  118. LS_passwordbar:SetSize(250,25)
  119. LS_passwordbar:SetVisible(true)
  120. LS_passwordbar.Paint = function(s , w , h)
  121. draw.RoundedBox(0,0,0,w,h,Color(255,255,255,255))
  122. surface.SetDrawColor( Color( 0, 0, 0, 255 ) )
  123. surface.DrawOutlinedRect( 0, 0, 800, 600 )
  124. end
  125.  
  126. local LS_imageframe = vgui.Create("DPanel", LS_invisiblebackground)
  127. LS_imageframe:SetZPos(3)
  128. LS_imageframe:SetPos(345, 95)
  129. LS_imageframe:SetSize(145,145)
  130. LS_imageframe:SetVisible(true)
  131. LS_imageframe.Paint = function(s , w , h)
  132. draw.RoundedBox(0,0,0,w,h,Color(80, 168, 216, 255))
  133. end
  134.  
  135. local LS_username = vgui.Create("DLabel", LS_invisiblebackground)
  136. LS_username:SetZPos(4)
  137. LS_username:SetFont("Username")
  138. LS_username:SetText("Marius Feno")
  139. LS_username:SetPos(310, 260)
  140. LS_username:SetVisible(true)
  141. LS_username:SizeToContents()
  142. LS_username:SetTextColor( Color( 0, 0, 0, 255 ) )
  143.  
  144. local LS_password = vgui.Create("DLabel", LS_invisiblebackground)
  145. LS_password:SetZPos(4)
  146. LS_password:SetFont("Password")
  147. LS_password:SetText("************")
  148. LS_password:SetPos(310, 300)
  149. LS_password:SetVisible(true)
  150. LS_password:SizeToContents()
  151. LS_password:SetTextColor( Color( 0, 0, 0, 255 ) )
  152.  
  153. local LS_info = vgui.Create("DLabel", LS_invisiblebackground)
  154. LS_info:SetZPos(4)
  155. LS_info:SetFont("Info")
  156. LS_info:SetText("Rndows 7 Entreprise (64-bits)")
  157. LS_info:SetPos(550, 575)
  158. LS_info:SetVisible(true)
  159. LS_info:SizeToContents()
  160. LS_info:SetTextColor( Color( 0, 0, 0, 255 ) )
  161.  
  162. local LS_closebutton = vgui.Create("DButton", LS_invisiblebackground)
  163. LS_closebutton:SetZPos(3)
  164. LS_closebutton:SetFont("Connect")
  165. LS_closebutton:SetText("X")
  166. LS_closebutton:SetPos(780,0)
  167. LS_closebutton:SetSize(20,20)
  168. LS_closebutton.DoClick = function()
  169. LS_invisiblebackground:Close()
  170. end
  171.  
  172. local LS_connectbutton = vgui.Create("DButton", LS_invisiblebackground)
  173. LS_connectbutton:SetText("")
  174. LS_connectbutton:SetFont("Connect")
  175. LS_connectbutton:SetPos(560, 300)
  176. LS_connectbutton:SetSize(25,25)
  177. LS_connectbutton:SetZPos(4)
  178. LS_connectbutton.DoClick = OnClick()
  179. end
  180. LS_connectbutton.Paint = function(s , w , h)
  181. draw.RoundedBox(0,0,0,w,h,Color(0, 148, 255,0))
  182. end
  183.  
  184. OnClick()
  185. LS_invisiblebackground:Close()
  186. WLS_invisiblebackground:SetVisible(true)
  187. end
  188.  
  189. local LS_userimage = vgui.Create( "AvatarImage", LS_invisiblebackground)
  190. LS_userimage:SetSize( 135, 135 )
  191. LS_userimage:SetZPos(4)
  192. LS_userimage:SetPos( 350, 100 )
  193. LS_userimage:SetPlayer( LocalPlayer(), 64 )
  194.  
  195. local LS_background = vgui.Create( "DImage", LS_invisiblebackground )
  196. LS_background:SetPos( 0, 0 )
  197. LS_background:SetZPos(1)
  198. LS_background:SetSize( 800, 600 )
  199. LS_background:SetImage( "addons/rnlife_computer/sessionbg.jpg" )
  200.  
  201. local LS_nextbuttonimage = vgui.Create( "DImage", LS_invisiblebackground )
  202. LS_nextbuttonimage:SetPos( 560, 300 )
  203. LS_nextbuttonimage:SetZPos(3)
  204. LS_nextbuttonimage:SetSize( 25, 25 )
  205. LS_nextbuttonimage:SetImage( "addons/rnlife_computer/nextbutton.png" )
  206.  
  207. local LS_windowslogo = vgui.Create( "DImage", LS_invisiblebackground )
  208. LS_windowslogo:SetPos( 520, 570 )
  209. LS_windowslogo:SetZPos(3)
  210. LS_windowslogo:SetSize( 25, 25 )
  211. LS_windowslogo:SetImage( "addons/rnlife_computer/Windows-logo.png" )
  212.  
  213.  
  214. local WLS_invisiblebackground = vgui.Create("DFrame")
  215. WLS_invisiblebackground:SetTitle("")
  216. WLS_invisiblebackground:SetZPos(2)
  217. WLS_invisiblebackground:SetPos(ScrW()/2-400, ScrH()/2-300)
  218. WLS_invisiblebackground:SetSize(800,600)
  219. WLS_invisiblebackground:SetVisible(false)
  220. WLS_invisiblebackground:MakePopup()
  221. WLS_invisiblebackground:SetDraggable(false)
  222. WLS_invisiblebackground:ShowCloseButton(true)
  223. WLS_invisiblebackground:SetDeleteOnClose(true)
  224. WLS_invisiblebackground:SetScreenLock(true)
  225. WLS_invisiblebackground.Paint = function(s , w , h)
  226. draw.RoundedBox(0,0,0,w,h,Color(0, 144, 255, 0))
  227. surface.SetDrawColor( Color( 0, 0, 0, 255 ) )
  228. surface.DrawOutlinedRect( 0, 0, 800, 600 )
  229. end
  230.  
  231. end
  232.  
  233. usermessage.Hook("ComputerPanel", ComputerPanel)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement