YouTube2Text

[NEW]How to make A Pet Simulator X Game on Roblox - Part 3 — Transcript

by polarisprog · 1,411 words · 246 segments · language en · Watch on YouTube

Full transcript

  1. 0:00hello everyone and welcome back to a new
  2. 0:02video on the how to make epistle lyrics
  3. 0:04for game series in this video I'm going
  4. 0:06to be showing you how to make the how to
  5. 0:09finish the attacking system so now we'll
  6. 0:11show the damage and it will also despawn
  7. 0:14the drop and after four seconds it will
  8. 0:18respawn it
  9. 0:19also if you guys want to support me and
  10. 0:21want to have access to all of my project
  11. 0:23files including the one you're watching
  12. 0:25right now that will all be available on
  13. 0:27my patreon in Nintendo 2. the link will
  14. 0:30be in the description with that being
  15. 0:31said let's start
  16. 0:33all right so what I'm gonna do is start
  17. 0:35working on the dimension system so when
  18. 0:37I enter our main client script and right
  19. 0:40here what we're gonna do is firstly get
  20. 0:42our damage variable which is right here
  21. 0:44and we're gonna put it right here
  22. 0:49and then
  23. 0:50when we do this when we change the
  24. 0:53Descent value
  25. 0:54what I'm gonna do is if player
  26. 0:58dot values
  27. 1:00dot send to dot value DOT health
  28. 1:04dot value is equal equal to zero then
  29. 1:08what we're going to do is we're going to
  30. 1:10create the function right here
  31. 1:13and I'm going to call it so local
  32. 1:15function and it's going to be called
  33. 1:17this Troy drop it's going to take a drop
  34. 1:22as an argument and in this function what
  35. 1:25we're going to do is task that weight
  36. 1:270.5
  37. 1:28and local old parent is equal to drop
  38. 1:32dot parent
  39. 1:34and drop the parent is equal to uh
  40. 1:38replicator storage actually what I'm
  41. 1:40going to do is I'm going to add a folder
  42. 1:42inside of replicated storage and I'm
  43. 1:43going to call it these pond so D spawned
  44. 1:47drops
  45. 1:49and so uh local
  46. 1:53g-spawn drops is equal to replicated
  47. 1:57storage going with the child despawn
  48. 1:58drops and so drops of parents is equal
  49. 2:01to replicator storage or uh is equal to
  50. 2:04g-spawn drops now we're gonna wait uh
  51. 2:07I'll respawn time so I want my part my
  52. 2:10drop to respawn every four seconds and
  53. 2:13after four seconds uh drop DOT health
  54. 2:16dot value
  55. 2:19is equal to drop dot Max health
  56. 2:23dot value and drop
  57. 2:26parent
  58. 2:28is equal to Old parent
  59. 2:30now what I'm going to do down here is
  60. 2:32we're going to call the destroy drop
  61. 2:34function
  62. 2:35and we're going to send the player.send
  63. 2:38to dot value
  64. 2:40and after that
  65. 2:42okay so I'm going to Fire error mode
  66. 2:44event before this and it's going to be
  67. 2:46cold okay so I'm going to add the remote
  68. 2:47event inside of this remotes folder and
  69. 2:51it's oh
  70. 2:53okay sorry remote event and we will call
  71. 2:56it
  72. 2:57stop damaging and what I'm going to do
  73. 2:59in here is remove stop damaging cone uh
  74. 3:02fire server
  75. 3:04okay so now I'm gonna enter my main
  76. 3:07server script
  77. 3:08and what I'm gonna do
  78. 3:11is okay so
  79. 3:13in here
  80. 3:16I'm going to put in
  81. 3:17remotes or game or where is it game the
  82. 3:22replica storage.remotes the remotes oh
  83. 3:25replica replicated storage but remotes
  84. 3:30[Music]
  85. 3:30um
  86. 3:31don't stop damaging dot on server event
  87. 3:34command connect function and that's
  88. 3:36going to take the player
  89. 3:38and when we fire this we're going to
  90. 3:40declare the uh values dot sent to the
  91. 3:45value
  92. 3:47is equal to nil
  93. 3:49and after that
  94. 3:52local player pets
  95. 3:54is equal to player oh okay so we already
  96. 3:57have available variable called flare
  97. 4:00pads
  98. 4:02so what I'm going to do is a little cold
  99. 4:04current
  100. 4:05layer of pets
  101. 4:07because you go to player pets square
  102. 4:10brackets player don't name and if
  103. 4:13hashtag current player best come and get
  104. 4:16children
  105. 4:19is greater than zero
  106. 4:22then
  107. 4:23uh local pet okay so local pet is equal
  108. 4:26to current player pets gonna find first
  109. 4:29child my first child okay so my first
  110. 4:33child of class
  111. 4:36model so when I get the first model
  112. 4:38which is the pet and Pat top attack not
  113. 4:42value is equal to false all right so now
  114. 4:45what I'm going to do is enter my main
  115. 4:47client script again so main client and
  116. 4:51down here what I'm gonna do is
  117. 4:55um around service okay so we don't have
  118. 4:57a reference for that so local run
  119. 5:00service is equal to game Conquest
  120. 5:02service run service
  121. 5:05and in here I'm going to do run service
  122. 5:07so hard okay so run service dot
  123. 5:10heartbeat.com connect function
  124. 5:13and for underscore comma drop and
  125. 5:17players drops
  126. 5:18okay so in pairs uh
  127. 5:21main where is it okay so do we have a
  128. 5:24reference to that
  129. 5:26now we don't workspace can wait for
  130. 5:28child's main folder on score workspace
  131. 5:32for child uh drops can get descendants
  132. 5:39do and what I'm gonna do is drop cone is
  133. 5:44a model then
  134. 5:47so if it is a model then local Health
  135. 5:50display is equal to drop coming with
  136. 5:53your child calling weight
  137. 5:56or find first child
  138. 5:59and let's see what we called it so I'm
  139. 6:01pretty sure it's called okay drops area
  140. 6:05one red drop Health display
  141. 6:10and local bar is equal to health display
  142. 6:12Health display uh dot background
  143. 6:16bar
  144. 6:19and local
  145. 6:21health
  146. 6:22display text
  147. 6:25is equal to help display
  148. 6:28background
  149. 6:31DOT health
  150. 6:33display text
  151. 6:37and
  152. 6:38actually it's called
  153. 6:40it's called Health display label sorry
  154. 6:42Health display label
  155. 6:45and after that help display
  156. 6:49text Dot text
  157. 6:52is equal to and drop DOT health
  158. 6:55the value
  159. 6:58and the bar contain
  160. 7:02size
  161. 7:05and I'm going to put in use them to Dot
  162. 7:08from scale
  163. 7:09uh jobs.health
  164. 7:12dot value
  165. 7:13divided by drop dot Max health
  166. 7:19value
  167. 7:21uh comma one
  168. 7:23and then in the easy style so again I'm
  169. 7:28not using Style
  170. 7:29dot actually is in direction is in
  171. 7:32Direction so out and in the easing style
  172. 7:35DOT sign then 0.3 for the 20 speeds now
  173. 7:41I'm going to play the game and see if
  174. 7:43this works
  175. 7:46okay
  176. 7:48so I'm going to show the output and I'm
  177. 7:50going okay so as you can see this
  178. 7:52does work but what I'm going to do is
  179. 7:54uh go to replicate the storage pets and
  180. 7:57I'm going to get a maybe a cat and I'm
  181. 8:01going to go here uh player pads players
  182. 8:03prank cat paste it in now I should get
  183. 8:06my cat and if I press this it should
  184. 8:09start damaging this and as you can see
  185. 8:12it does work now it might look like it's
  186. 8:14not twinning it but it actually don't
  187. 8:16it's actually 20 minutes so I can go
  188. 8:19ahead and set the uh damage value
  189. 8:24to a higher number so I can just go to
  190. 8:27my main client
  191. 8:28right here damage I'm going to put put
  192. 8:31it to 10.
  193. 8:33and this should be a lot quicker
  194. 8:36so I'm going to go ahead and get my pet
  195. 8:38again that's count
  196. 8:42erpets Polaris prog based into
  197. 8:46and I should go ahead and click this
  198. 8:49and as you can see now it does
  199. 8:52uh
  200. 8:53to Win It smoothly and if it gets to
  201. 8:56zero it should despawn it no it doesn't
  202. 9:00so Center is not a valid member oh
  203. 9:02that's very very simple to fix we just
  204. 9:05need to do player dot values
  205. 9:07not sent to the value
  206. 9:11and that should work now I'm also going
  207. 9:14to change the damage value to something
  208. 9:15a lot bigger like 20.
  209. 9:19and now if I give myself a pet
  210. 9:23then that should be
  211. 9:28that should work
  212. 9:30past flowers blog and
  213. 9:34click
  214. 9:36works okay now if it gets down to zero
  215. 9:39unable to assign property value
  216. 9:42object expected oh
  217. 9:47player.tag.value oh it should me it
  218. 9:49should be nil sorry
  219. 9:52let me double check okay so it should be
  220. 9:54nil
  221. 9:56now it should work
  222. 10:00cat copy it paste it inside of the
  223. 10:04Polaris proc folder
  224. 10:06now that I have a cat I can go ahead and
  225. 10:08click this and this time
  226. 10:11it should work
  227. 10:12and it does and it should respawn after
  228. 10:15four seconds
  229. 10:17and it doesn't
  230. 10:18okay
  231. 10:21job.max Health okay so I spelled Health
  232. 10:24wrong but now it should work
  233. 10:29I know I said that like
  234. 10:3110 times
  235. 10:33but I really hope it will work this time
  236. 10:40okay so click
  237. 10:45and let's see if this works
  238. 10:48these Pawns
  239. 10:50and
  240. 10:51a response and a full health great and I
  241. 10:55can switch between these and everything
  242. 10:57works fine no bugs alright so this is
  243. 11:01going to be it for today's tutorial this
  244. 11:03helped Please Subscribe click the video
  245. 11:04share it with your friends and I'll see
  246. 11:06you all in the next video bye

About this transcript

This page contains the full transcript of [NEW]How to make A Pet Simulator X Game on Roblox - Part 3 by polarisprog, generated from the public captions YouTube serves with the video. The transcript has 1,411 words across 246 segments, with the original timestamps preserved so you can click any line to jump to that moment in the embedded player.

What you can do with it

Use the transcript to take notes, quote the speaker, build a study guide, generate a summary with ChatGPT or Claude via the YouTube Summary tool, or export it as a timed subtitle file with YouTube to SRT. You can also re-open it in the transcriber to choose a caption track available on the video.

Free YouTube transcript tool

YouTube2Text is a free YouTube transcript generator — no signup, no daily limit. Paste any YouTube link and get the full transcript instantly, with timestamps, click-to-jump, caption language selection, AI prompts for ChatGPT, Claude, and Gemini, and exports to TXT, SRT, VTT, or Markdown.