КОМЕНТАРІ •

  • @specialeddgames5668
    @specialeddgames5668 5 років тому +67

    Great Tutorials, the best ones I can find on UA-cam.

    • @CodeWithTom
      @CodeWithTom 5 років тому +4

      Thank you so much!

    • @sergeiorlov5096
      @sergeiorlov5096 4 роки тому +5

      I know that I'm a bit late with my reply, but heck - it might help someone reading this in the future.
      I LOVE Tom's tutorials, but you must know that theres quite a lot of quality tutors beside Tom.
      My personal favourites:
      "Game Development Center" - aimed at Diablo style rpg's and networking
      "Garbaj" - Just like Tom, he's mainly into FPS
      'Rungeon" - a fairly new channel, but damn that guy is a gem. THE best platformer tutorials I've seen so far!
      "Heartbeast" - zelda-like (or ratherHyper light Drifter- like) arpg tutorials, and much more!
      "KidsCanCode" - This guy is a Wikipedia of Godot. Quality stuff!
      And these guys are just my top pics- I'm sure there's even more quality content out there.
      Hope that these references will help someone, as these tutors (Including Tom, obviously) helped me )

    • @anotherrandominternetguy404
      @anotherrandominternetguy404 2 роки тому

      @@sergeiorlov5096 u r talking only about godot?

    • @alishehryar4099
      @alishehryar4099 2 роки тому

      @@sergeiorlov5096 for us hes the best so stfu

  • @321357w
    @321357w 5 років тому +26

    Definitely hooked on these tutorials.

    • @CodeWithTom
      @CodeWithTom 5 років тому +4

      Thanks Jeff that means a lot

  • @KyleHarmieson
    @KyleHarmieson 4 роки тому +1

    The class/inheritance solution to multiple weapons has totally revolutionised the way I design weapons in my game. Thank you so, so much for explaining how to define and inherit classes! I've even gone a step further and inherited from weapon to create three specialised classes: raycast_weapon, projectile_weapon and melee_weapon!

    • @CodeWithTom
      @CodeWithTom 4 роки тому +1

      Glad I could help! That sounds like a perfect solution to varying weapon types.😁

    • @KyleHarmieson
      @KyleHarmieson 4 роки тому

      @@CodeWithTom It's working beautifully! It also makes it much easier to organise the weapons in my project, and to refer to them and use their stats in the game. This "template" approach is perfect for my game's modular weapon system. Thanks again for the idea! :D

  • @zacharyschiffner2859
    @zacharyschiffner2859 5 років тому +8

    You're a great teacher I can't believe you only have 501 subscribers

  • @Kura.tf2
    @Kura.tf2 3 роки тому +1

    best free tutorials on youtube for sure

  • @lucavlase6993
    @lucavlase6993 2 роки тому +1

    Tom, how do you only have 0.1% of the subscribers you deserve? The video quality is great, and your content is helping me a lot rn

  • @anintruder2586
    @anintruder2586 4 роки тому +1

    I honestly can't believe you only got 2k subs! You deserve more for your hard work and quality tutorials!!

  • @the_dogey
    @the_dogey 3 роки тому +1

    Really amazing tutorial. This videos are so good to learn GDScript for those who already know a different language already.

  • @DuranMetalWolf
    @DuranMetalWolf 4 роки тому +2

    Amazing tutorial, your content is simply great!
    I have been messing arroung with Godot and you have helped me a lot to work my way out.
    Thanks for the great videos!

  • @dxrkst8623
    @dxrkst8623 3 роки тому +2

    You have the most helpful channel for Godot. Thanks man.

  • @titustech7219
    @titustech7219 2 роки тому

    combining this with the amazing garbaj weapon switching tutorial thank you soo much

  • @Kura.tf2
    @Kura.tf2 3 роки тому +5

    (always make sure you check your CAPS while spelling RayCast in GDscript so you don't get a Null_Instance on null instance error)

    • @wasyouamv7773
      @wasyouamv7773 2 роки тому

      Hello someone could help me every time I pull its me but the error
      code 'raycast.is_colliding () null instence so here is my
      script tell me the error that I made please
      extends Node
      class_name Weapon
      export var fire_rate = 0.5
      export var clip_size = 5
      export var reload_rate = 1
      onready var raycast = $"../Head/Camera/RayCast"
      var current_ammo = clip_size
      var can_fire = true
      var reloading = false
      func _process(delta):
      if Input.is_action_just_pressed("primary_fire") and can_fire:
      # fire the weapon
      if current_ammo > 0 and not reloading:
      print ("Fired weapon")
      can_fire = false
      current_ammo -= 1
      check_collision()
      yield(get_tree().create_timer(fire_rate), "timeout")

      can_fire = true
      elif not reloading:
      print("reloading")
      reloading = true
      yield(get_tree().create_timer(reload_rate), "timeout")
      current_ammo = clip_size
      reloading = false
      print ("reload complete")
      func check_collision():
      if raycast.is_colliding():
      var collider = raycast.get_collider()
      if collider.is_in_group("Enemies"):
      collider.queue_free()
      print("Killed" + collider.name)

    • @wasyouamv7773
      @wasyouamv7773 2 роки тому

      not understand how to check her?

  • @frankoesavage8314
    @frankoesavage8314 4 роки тому +1

    Thanks Tom, for making such a detailed explained video , your helping us all understand alot better.

    • @CodeWithTom
      @CodeWithTom 4 роки тому

      You're very welcome Frankoe

  • @pascalcasier959
    @pascalcasier959 4 роки тому +3

    Thank you so much. Would love to see a tutorial on how to code arrows with gravity.

    • @CodeWithTom
      @CodeWithTom 4 роки тому +1

      Thanks for the suggestion 👍

  • @ash.n51
    @ash.n51 4 роки тому +6

    Go to 1:34 if you already watched part 1 :)

  • @devdurros3676
    @devdurros3676 4 роки тому +1

    Thank you so much for these tutorials, really helping me with my 3D Godot game dev! Great tutorials

  • @고강준-p7s
    @고강준-p7s 5 років тому +2

    Best godot tutorial on UA-cam

    • @CodeWithTom
      @CodeWithTom 5 років тому

      Wow thank you for the kind words. :)

  • @Theinvalidmusic
    @Theinvalidmusic 4 роки тому

    Adding to the chorus here that these are great tutorials you're doing. Really looking forward to more!

  • @holomode1357
    @holomode1357 3 роки тому

    best godot tutorials in the whole internet

  • @lumenwrites
    @lumenwrites 5 років тому +2

    Absolutely amazing tutorial! Please make more!

    • @CodeWithTom
      @CodeWithTom 4 роки тому +1

      Thank you Ray that means a lot!

  • @bca_Amandeep_Singh
    @bca_Amandeep_Singh 5 років тому +5

    The " is_colliding()" and "get_collider()" are not working i've been searching the web and can't find the replacement. Please let me know the solution.

    • @anarchy3508
      @anarchy3508 4 роки тому

      @@dominicuss please help me, i copied the code directly but there is NOTHING about the the enemy dissapearing and the raycast wont collide

  • @starfrog1
    @starfrog1 4 роки тому +1

    Many thanks! Much better than expected! Very well explained. :)

    • @CodeWithTom
      @CodeWithTom 4 роки тому

      Thanks I appreciate the feedback 😊

  • @NeZversSounds
    @NeZversSounds 5 років тому +4

    Thank you for the awesome tutorials!

    • @CodeWithTom
      @CodeWithTom 5 років тому +1

      Thank you for watching! 😁

  • @kornflakes8983
    @kornflakes8983 3 роки тому

    Dude, this was the best fucking tutorial ever for raycasting. Thank you so much dude!

  • @KellenChase
    @KellenChase 4 роки тому +3

    wow, so appreciated. this is a great tutorial series. learning a lot, and excited to have a character that can already run around and kill enemies. thank you!
    got a question that I will try and research if I don't see it covered. Ill edit this comment when I find an answer... when my mouse is not in the screen area when starting, any click, clicks me out of the game again as if Id hit the escape key. is there a way to grab the mouse cursor, center it, then run the capture process? it's not an issue if I hit play and then get my mouse into the window area before it's fully loaded.
    oooh... you pulled a sneaky around 13:50 ... added the class_name without telling us. when we create shotgun.gd, gives a little error when trying to extend without the class_name in Weapon.gd
    ... dangit... should have just played another 5 seconds of the video... ;)
    alright, so I added the ready process that was put in shotgun.gd to the ready process in weapon.gd (so the shotgun can inherit the generic fire_range, and that can be brought into all future weapons as well). I feel like one change that I am going to work on as well is that the reload should be able to happen right after the last shot... at current, it is waiting for a timeout to allow another shot, and then that shot turns into a reload... really enjoying this. thanks again! What I would like to see next... (don't know if its in the playlist from where I am sitting now) is an inventory system, weapon selection, etc.... I like the idea of an FPS RPG, and I think that those two combinations for a game covers so many concepts and ideas of game design, that it could be a great teaching series in itself.

  • @Скорпикор
    @Скорпикор 5 років тому +3

    Great tutorials, subscribed!

  • @victr3d
    @victr3d 4 роки тому +1

    Great video! By the way, what computer do you have?

  • @geckopg3d394
    @geckopg3d394 2 роки тому

    For those of you who want to reload when your ammo is at 0, simply put:
    if current_ammo < 1 and not reloading:
    reload()
    in the func _process(delta) function so you don't have to press r or shoot

  • @hobbesthebrainslug12
    @hobbesthebrainslug12 2 роки тому +4

    Well here I am running into another problem.
    I'm at the point where we're coding the raycast to delete/kill enemies. I have everything set up as you put it. But nothing happens when I 'fire' on an enemy. It just prints 'fired weapon'. The enemy doesn't disappear. With 'Visible collision shapes' turned on I can see that the game knows something is there when I mouse over it. But wont do anything when I fire.

    • @MrTobbeman22
      @MrTobbeman22 2 роки тому

      Sounds like you missed "collider.queue_free()"

  • @JacobKinsley
    @JacobKinsley 2 роки тому +1

    Is it better to create a raycast in code or to create a raycasts object in the scene and just hiding/unhiding? I'm assuming in the scene because then you don't have to create and delete it every time, but it only works if it's always from the center of the camera to the middle of the screen

  • @AleksandarPopovic
    @AleksandarPopovic 4 роки тому +1

    Great tutorial, pls continue to work i love you work!!!!!and good luck for your work......

  • @nuki_yt
    @nuki_yt 5 років тому +5

    Thank you dude.
    I expect great things from you. :)
    Google Translate...

    • @CodeWithTom
      @CodeWithTom 5 років тому

      You're very welcome! Thank you!

  • @vickylance
    @vickylance 4 роки тому +1

    @26:16 I think the solution to directly access the label and change it every process frame is not a good practise in terms of both performance and single responsibility principle. The weapon class should not handle the UI elements. Instead what I think is that it should simply emit a signal and then the UI node should have a script that should capture that signal and then act upon it

    • @CodeWithTom
      @CodeWithTom 4 роки тому +1

      Very good recommendation, you're absolutely right. I will cover signals in a future video.

  • @anarchy3508
    @anarchy3508 4 роки тому +2

    hold on i tried this but cant get the shoot collision or enemy vanishing here. have i missed something because ive followed exactly

  • @retrocademedia-announcements
    @retrocademedia-announcements 4 роки тому

    At 25:04 you can just use onready before current_ammo rather than using the ready function

  • @AlphaToast27
    @AlphaToast27 3 роки тому +1

    everything works perfectly except the check_collision function, i shoot at the enemies but it doesn’t seem to detect it. do you know what would cause it?

  • @andypandy-py1zc
    @andypandy-py1zc Рік тому +1

    Great tutorial I look forward to completing the whole series. I am having trouble with the function check_collision(): My Godot_v3.5.1 throws an error "Attempt to call function 'is_colliding' in base 'nul instance' on a null instance." Does anyone know to fix this. I have tried prefixing raycast with a $ sign without success. would like to move on cause the tutorials are great & easy to understand, big thanks to Tom for making the video's.

  • @YTrandomusr24
    @YTrandomusr24 3 роки тому

    Thanks, excellent tutorial! Done!

  • @iamelite20
    @iamelite20 3 роки тому +1

    bro u are a legend i subscribed right awat

  • @buyrcsp2
    @buyrcsp2 2 роки тому

    I dunno if he told this in future video and if anyone is still watching this video, but if you want to make a gun thats keeps shooting when the shoot button is pressed (or an *automatic gun*), change Input.is_action_just_pressed to Input.is_action_pressed in the func fire()

  • @Wasa-qo7vn
    @Wasa-qo7vn 2 роки тому

    Thanks for base script!!! I will credit you in my indev game called Simulaning! ❤❤❤

  • @Buli0n
    @Buli0n 4 роки тому +1

    Please show us how to make enviromental hazards such as water or lava or fire or smoke or fog, scripts of things that appear and dissapear and physics of ropes! 🙏

    • @CodeWithTom
      @CodeWithTom 4 роки тому

      Great suggestion! I'll add it to the list

  • @aharonxxl2564
    @aharonxxl2564 3 роки тому

    Thank you so much, you are a very good teacher.

  • @specialeddgames5668
    @specialeddgames5668 5 років тому +2

    Could you show us in the next video how to make it to where we can see where the bullet goes and have it shoot out of a gun

    • @CodeWithTom
      @CodeWithTom 5 років тому +1

      I'll add it to the list for sure. I'd like to add a decal system at some point for bullet holes etc

  • @LockStockNBarrel
    @LockStockNBarrel 5 років тому +1

    Is yield() a non blocking wait? What happens to other code in the same function during that time? Does it actually block further code execution but only for the _process() function which runs on every frame? What if I want to do other things in the _process() function in the mean time?

    • @CodeWithTom
      @CodeWithTom 5 років тому

      Good question. Yields are complicated to explain in a single response. But they are effectively a way of initiating coroutines, freezing the current state of execution and resuming once they receive a completed signal. You can read more here: docs.godotengine.org/en/3.0/getting_started/scripting/gdscript/gdscript_basics.html#coroutines-with-yield

  • @octosional
    @octosional 4 роки тому +1

    I need some help. The game was working fine until I added the exact same lines of code from line 33-38 at 17:35 and then every time I clicked to fire the weapon it brings up an error message saying “Attempt to call function ‘is_colliding’ in base ‘null instance’ on a null instance” as well as “get_node: Node not found: ../Head/Camera/Raycast.”

    • @JusGodden
      @JusGodden 4 роки тому +3

      RayCast has a capital C, about line 9 is meant to be: onready var raycast = $"../Head/Camera/RayCast"

  • @RaiderJake
    @RaiderJake 4 роки тому +1

    How would I set it to an automatic fire, like just holding the left click button? Great tutorials thank you.

    • @Dogman_35
      @Dogman_35 4 роки тому +2

      Remove the "just" is is_action_just_pressed. The "just" means it only checks the first time you click, and if you remove it then it will constantly fire every time the firerate timer is up as long as you're holding down the button.

    • @RaiderJake
      @RaiderJake 4 роки тому +1

      @@Dogman_35 awesome thx

  • @alialramadhan4748
    @alialramadhan4748 5 років тому +2

    hello mister Tom i hope you are having a great day, I appreciate your tutorial. I need help with something though if I want to have no reload weapon can i just skip the steps of 8:00 - 12:00 min mark?

    • @CodeWithTom
      @CodeWithTom 4 роки тому +2

      Hi Ali, absolutely! If you don't want reloading feel free to skip that entirely.

    • @alialramadhan4748
      @alialramadhan4748 4 роки тому +1

      @@CodeWithTom thnks for the reply

  • @davidheadley8589
    @davidheadley8589 3 роки тому

    Amazing series thank you

  • @krasnavin
    @krasnavin 2 роки тому

    Tom I always depend on your instructions. For next step how do I show my laser bullet firing? Thanks,

  • @juliandavidgarciagonzalez3209
    @juliandavidgarciagonzalez3209 3 роки тому

    it's great! these videos help me a lot!this is very interesting👍🏻

  • @presleyknox9884
    @presleyknox9884 3 роки тому +1

    how many videos are there in this series

  • @RexieRacer
    @RexieRacer Рік тому

    For anyone wondering, at the time im at in the video you dont need the export infront of the var (var fire_rate etc.) it made my code not work so i wanted to put this out so you know the problem.

  • @IGamer609
    @IGamer609 2 роки тому +1

    please help, idk why but the shotgun script doesn't work at all and i think the scripts don't connect even when i put the correct class id

    • @geckopg3d394
      @geckopg3d394 2 роки тому

      if you click on the weapon node in the player scene that should help

  • @gregorioespindola7171
    @gregorioespindola7171 4 роки тому +1

    que bueno el mejor que vi 3d asta a hora muchas gracias!!

  • @jojojoejoe9977
    @jojojoejoe9977 3 роки тому

    Pls help. It says check_collision isnt declared in the current class. For the fire button

  • @onurcatalgol8132
    @onurcatalgol8132 3 роки тому

    Youre pretty good, justed wished you were a bit slower. and explained some of the codes a little bit more. but youre the best, thanks for the help

    • @bbgamingplay1511
      @bbgamingplay1511 3 роки тому

      He is going fast because he thinks we have watched other tutorial series.

  • @עידוברנע
    @עידוברנע 4 роки тому +1

    Great video! Could you tell me how to show the bullet moving?

    • @CodeWithTom
      @CodeWithTom 4 роки тому +1

      Thanks! Projectile bullets are definitely on my todo list.

  • @dafellachallam7384
    @dafellachallam7384 2 роки тому +2

    I have a little problem
    It says *is_colliding is base in null instance* on a null instance

    • @panderz_gg
      @panderz_gg 2 роки тому

      Same. Did you find a solution in the meantime?

  • @Mriganka2S
    @Mriganka2S 4 роки тому

    I've been following your tutorial, but I'm getting this problem:
    func check_collision():
    print("in_collider fn")
    if bullet.is_colliding():
    print("is_colliding")
    var collider = bullet.get_collider()
    if collider.is_in_group("Enemies"):
    print("Killed" + collider.name)
    collider.queue_free()
    In the code, for some reason, isn't entering -- if collider.is_in_group("Enemies"):
    Any idea why? It's detecting the collisions but not identifying the group.

  • @nicoservin2870
    @nicoservin2870 2 роки тому

    I don't get the if with the can_fire part, because it can't happend can_fire =true and current_ammo>0 at the same time. Unless you mean to use can_fire for another purpose like if sprinting=true or cutscene=true: can_fire=false and then it can't shoot

  • @maricelugsod4770
    @maricelugsod4770 4 роки тому

    11 out if 10 Tutorial

  • @bkaunghtet8425
    @bkaunghtet8425 4 роки тому

    Thank You for this tutorial sir.

  • @thomaseubank1503
    @thomaseubank1503 3 роки тому

    Thanks for the tutorial

  • @azuolas5673
    @azuolas5673 4 роки тому +1

    Great Tutorials THX

  • @matrixchronic8542
    @matrixchronic8542 4 роки тому +1

    Is there a way to show the Bullets coming out the gun

  • @volcanicember
    @volcanicember 3 роки тому +1

    I know this is a kind of old video, but i did all the code right for this one i followed step by step but the raycast will not collide with anything? everytime i fire at one of the spheres it doesn't print or do anything. Halp

    • @panskibinski
      @panskibinski 3 роки тому +2

      In my case rebuilding enemy as: [ MeshInstance with Statitc body with CollisionShape ] helped. Same as ground in video part 1

    • @volcanicember
      @volcanicember 3 роки тому +1

      @@panskibinski Thank you! This fixed my problem pretty quickly

  • @crdt2779
    @crdt2779 3 роки тому +1

    17:55 ive checked that i wrote everything exactly as you wrote it countless times, yet upon firing, the game closes and says:
    "Attempt to call function 'is_colliding' in base 'null instance' on a null instance."
    can you help with this?

    • @Kura.tf2
      @Kura.tf2 3 роки тому

      i had the same issue

    • @paytonluther3356
      @paytonluther3356 3 роки тому

      How do you fix it

    • @dradex9562
      @dradex9562 2 роки тому +2

      change raycast to RayCast

    • @killerqueen951
      @killerqueen951 2 роки тому

      @@dradex9562 which raycast All of them? Because I changed the /RayCast” and it’s still not working

    • @dradex9562
      @dradex9562 2 роки тому

      @@killerqueen951 i have 0 clue i stopped using unity a while ago

  • @yrnteao
    @yrnteao 2 роки тому

    is the info in this tutorial series still applicable in 3.4?

  • @michaelwilson814
    @michaelwilson814 4 роки тому

    this is my code is anything wrong because when i go to fire i get an error
    extends Node
    class_name Weapon
    export var fire_rate = 0.5
    export var clip_size = 5
    export var reload_rate = 1
    onready var raycast = $"../Head/Camera/RayCast"
    var current_ammo = clip_size
    var can_fire = true
    var reloading = false
    func _process(delta):
    if Input.is_action_just_pressed("primary_fire") and can_fire:
    # fire the weapon
    if current_ammo > 0 and not reloading:
    print("Fired weapon")
    can_fire = false
    current_ammo -= 1
    check_collision()
    yield(get_tree().create_timer(fire_rate), "timeout")
    can_fire = true
    elif not reloading:
    print("Reloading")
    reloading = true
    yield(get_tree().create_timer(reload_rate), "timeout")
    current_ammo = clip_size
    reloading = false
    print("Reload complete")
    func check_collision():
    if raycast.is_colliding():
    var collider = raycast.get_collider()
    if collider.is_in_group("Enemies"):
    collider.queue_free()
    print("Killed " + collider.name)

  • @innocentcat2
    @innocentcat2 2 роки тому

    Yes a great tutorials

  • @nathangames8744
    @nathangames8744 3 роки тому

    When I'm doing the ammo label it says "get_node: node not found: /root/Player/UI/Label." Please help

  • @gamerukn4231
    @gamerukn4231 2 роки тому

    Can you make a tutorial on wall running and vaulting for a 3d parkour game

  • @Fox-1502
    @Fox-1502 5 років тому +1

    18:00 when i try to fire, this message appears. "Failed to call function 'is colliding' in base 'null instance' on a null instance"... please can you help me?

    • @bca_Amandeep_Singh
      @bca_Amandeep_Singh 5 років тому

      yes, same issue with me. apparently with the latest update of godot these are replaced by something else and i am trying to find that out myself

    • @skaruts
      @skaruts 5 років тому +3

      That means your raycast variable is null and so it doesn't have the RayCast functions. Probably you typed the path wrong or you have your hierarchy arranged differently. The path is case-sensitive, btw.

    • @Fox-1502
      @Fox-1502 5 років тому

      @@skaruts ok thank you :D you solved my problem

    • @skaruts
      @skaruts 5 років тому

      @@Fox-1502 np :)

    • @CodeWithTom
      @CodeWithTom 4 роки тому +1

      Glad to hear you were able to solve your problem!

  • @jackv7614
    @jackv7614 4 роки тому

    how would you switch between two different weapons? when I try to change the script while it's running it crashes

  • @aurelien_le_fou
    @aurelien_le_fou 2 роки тому

    Hi, at 24:45 my code say that rhe fonction set_text attempt to call in base null instance

  • @matrixchronic8542
    @matrixchronic8542 4 роки тому +1

    Do u need the second script or not

  • @Jaydenbb5
    @Jaydenbb5 4 роки тому

    for some reason my camera isn't working and I'm stuck on a grey screen instead of the camera that was working in ep 1

  • @CelineSZN
    @CelineSZN 3 роки тому

    I keep getting a is_colliding in base null instance on a null instance pls help if you can

  • @DoriftoDA
    @DoriftoDA 4 роки тому +1

    i love your tutorial. but, why my enemies doesn't disappear when i shoot them? how to solve it?

  • @paytonluther3356
    @paytonluther3356 3 роки тому

    get_node: node not found: ../Head/Camera/RayCast
    Please help

  • @FurryTerminator
    @FurryTerminator 4 роки тому

    When I call check_collision()
    it says Breakpoint what does that mean?

  • @ryanmanville6883
    @ryanmanville6883 4 роки тому

    thanks for the help!

  • @Lantern_Light
    @Lantern_Light 4 роки тому

    So.. The weapon never fired.. I never got the output saying "weapon fired" despite my script being identical to yours..

    • @CodeWithTom
      @CodeWithTom 4 роки тому

      Hi there, sounds like you may be missing a call to the function that fires the weapon. Can you double check your file against my script.

  • @bubblzjamse1599
    @bubblzjamse1599 2 роки тому

    it did not work for me, the first tut was fine but it does not say "fired weapon" when i click

    • @geckopg3d394
      @geckopg3d394 2 роки тому

      does your print statement look like this:
      print("Fired weapon")?

  • @JOKER-pi1qr
    @JOKER-pi1qr 5 років тому

    I have a mistake: wehn i try to reload or shoot, it is not going down the ammo bar... and when I press r it isn't als reloading also if i look at the output screen where everything is written... I don't understand pls help me. And I very like this project...

    • @CodeWithTom
      @CodeWithTom 5 років тому

      Hey there, if you're able to join the discord and send me your Player.gd script I can take a look. discord.gg/nzq9ZKT

  • @krishnawinner6935
    @krishnawinner6935 4 роки тому

    When i write fire()its says fire in the scope isnt declared what to do

  • @uhfan22
    @uhfan22 5 років тому +1

    Nice! I subbed in order to be guided by your brilliant ideas, as game development might be really difficult for a newbie! Btw.. i'm a linux developer and i want to upload my games for android platform later in the future but i have some problems with a program called adb.. Please if you can help me, then I would like from you to make a video on how to solve this kind of issue.. Thx for reading my comment!

    • @CodeWithTom
      @CodeWithTom 4 роки тому

      Hey I'm so glad you're finding this content useful! I will try and cover android deployments in a later video.

  • @lilpreso200
    @lilpreso200 2 роки тому

    on the can fire its says that the indent isnt needed

  • @flatboi5116
    @flatboi5116 4 роки тому

    Gained my sub... amazing trutorials

  • @avgchoobafan
    @avgchoobafan 5 років тому

    really good video, but i have a problem, suddenly the camera clamp in my Player.gd no longer works, but everything else works fine, what could be?

    • @CodeWithTom
      @CodeWithTom 5 років тому

      interesting, can you head over to our discord and post your Player.gd file? discord.gg/nzq9ZKT

  • @Alternalo
    @Alternalo 4 роки тому

    How can i make a visual feedback on the point of impact?

  • @Painple
    @Painple 2 роки тому

    Nice video.

  • @ruptbolt8032
    @ruptbolt8032 4 роки тому +2

    It won't let me do "set_text"

    • @Glyc01
      @Glyc01 4 роки тому +1

      i have to this error "Attemt to call function 'set_text' in base "null instanse" on a null instanse
      and this stroke error - raycast.cast_to = Vector3(0, 0, -fire_range)

  • @beanie.weanie
    @beanie.weanie 2 роки тому

    how do i make it so when i hold the mouse key the gun keeps shooting by itself

    • @matapavosgamer
      @matapavosgamer 2 роки тому

      Use "Input.is_action_pressed" instead of "Input.is_action_just_pressed"

  • @ronak3813
    @ronak3813 2 роки тому +2

    Enemies are not dying pls help me😭😭😭😭😭😭😭😭🙏🙏

  • @ahhhlex2
    @ahhhlex2 4 роки тому

    hello i know i'm late to the comments but i really need help i cant figure it out why wont they die it doesn't say they died and they don't disappear

    • @CodeWithTom
      @CodeWithTom 4 роки тому

      Hi apologies for the delay in response. Please feel free to join the discord and I'll try and help as best I can.

  • @rishianands8472
    @rishianands8472 5 років тому

    Thanks a lot TOM...

    • @CodeWithTom
      @CodeWithTom 5 років тому

      You're very welcome Rishi!

  • @interweebs7408
    @interweebs7408 4 роки тому

    17:50 When I test the game and fire the weapon anywhere, the debug stops working and I get the following error:
    *"Attempt to call function 'is_colliding' in base 'null instance' on a null instance."*
    Is anything wrong with my script?
    Here it is:
    extends Node
    class_name Weapon
    export var fire_rate = .5
    export var clip_size = 5
    export var reload_rate = 1
    onready var raycast = $"../Head/Camera/Raycast"
    var current_ammo = clip_size
    var can_fire = true
    var reloading = false
    func _process(delta):
    if Input.is_action_just_pressed("primary_fire") and can_fire:
    # fire the weapon
    if current_ammo > 0 and not reloading:
    print("Fired weapon")
    can_fire = false
    current_ammo -= 1
    check_collision()
    yield(get_tree().create_timer(fire_rate), "timeout")
    can_fire = true
    elif not reloading:
    print("Reloading...")
    reloading = true
    yield(get_tree().create_timer(reload_rate), "timeout")
    current_ammo = clip_size
    reloading = false
    print("Reload complete.")
    func check_collision():
    if raycast.is_colliding():
    var collider = raycast.get_collider()
    if collider.is_in_group("Enemies"):
    collider.queue_free()
    print("Killed " + collider.name)

    • @interweebs7408
      @interweebs7408 4 роки тому +2

      Nevermind! I wrote "Raycast" instead of "RayCast" not knowing it was capital sensitive. Sorry!

    • @michaelwilson814
      @michaelwilson814 4 роки тому +1

      @@interweebs7408 im having the same problem but when i changed the capital it still doesnt work

    • @codingkam1252
      @codingkam1252 4 роки тому

      @@michaelwilson814 chack the name of the actual raycast

    • @UmaShankar-ke3hm
      @UmaShankar-ke3hm 4 роки тому

      @@interweebs7408 Thanks that really helped👍

  • @nissyyybeatz
    @nissyyybeatz 3 роки тому

    i cannot find the raycast for some reason