Map Voting - Tower Defense Tutorial #19

Поделиться
HTML-код
  • Опубликовано: 11 дек 2024

Комментарии • 1,1 тыс.

  • @endofoony4718
    @endofoony4718 4 месяца назад +3

    For anyone who has a problem in Round (or around 41:04 in the video)
    09:41:38.057 ServerScriptService.Main.Round:70: invalid argument #1 to 'insert' (table expected, got nil) - Server - Round:70
    09:41:38.057 Stack Begin - Studio
    09:41:38.057 Script 'ServerScriptService.Main.Round', Line 70 - function ProcessVote - Studio - Round:70
    09:41:38.057 Stack End - Studio
    09:41:38.423 Processed vote for Map - Server - Round:69
    09:41:38.423 ServerScriptService.Main.Round:70: invalid argument #1 to 'insert' (table expected, got nil)
    (this error)
    Make sure your ImageButtons are properly labelled with the name of the maps
    (found in GameGui --> Voting --> Maps)

    • @JoseLynito_OFC
      @JoseLynito_OFC 4 месяца назад

      I have a error in the local mapFolder part

  • @ChrisP-uk
    @ChrisP-uk 2 года назад +15

    Been waiting for this for ages, can be useful for so many more games too

  • @kennethkline7702
    @kennethkline7702 2 года назад +5

    LOVE that this came out so fast!!

  • @fardtist
    @fardtist 2 года назад +11

    great series, this really helped! thanks a lot

  • @safgsafj2685
    @safgsafj2685 7 месяцев назад +2

    went into this with NO lua experience and now i can comfortably edit the scripts on my own
    amazing tutorials gnome!

  • @pothangus1118
    @pothangus1118 2 года назад +14

    Instead of hard coding it to default Grassland, you can make a random selection like this,
    mapFolder = ServerStorage.Maps:GetChildren()[math.random(math.max(1,1), #ServerStorage.Maps:GetChildren())]

    • @Lovear-v2s
      @Lovear-v2s 2 месяца назад

      THANK YOU BRO I NEEDED TO FIX MY ERROR

    • @Harv770
      @Harv770 2 месяца назад +1

      @@Lovear-v2s the fact people still watch this series today like I am is CRAZY!!!!!!!!

    • @SkineurYTB
      @SkineurYTB Месяц назад

      @@Harv770 Yep...

    • @1ceowL
      @1ceowL Месяц назад

      ​@@Harv770hah

    • @GreatPapyrus0606
      @GreatPapyrus0606 16 дней назад

      ​@@Harv770 you right...

  • @venolodaf5599
    @venolodaf5599 2 года назад +5

    Amazing again, can't wait to see the lobby creation. Also I love the new map too!

  • @shahanawahid8797
    @shahanawahid8797 2 года назад +13

    These tutorials are amazing. Do you have any plans on how to add a lobby, Shop and linked Inventory?

  • @redfire826
    @redfire826 2 года назад +3

    Keep it up bro!!! I have been watching you for a while and decided to subscribe! High quality videos!

  • @ethansexton
    @ethansexton 2 года назад +3

    I'm at 40:51 and when i test it it give me an error that says "Argument 1 missing or nil - Server - Round:14" Can anyone help?
    I've also checked and everything that pertains to the voting system is the same

    • @steff2706
      @steff2706 2 года назад

      i have the same error

    • @Kris-fp4ys
      @Kris-fp4ys 2 года назад

      same

    • @OguzhanArda-i4w
      @OguzhanArda-i4w 11 месяцев назад

      same:/

    • @jsmoutdoorsycrew338
      @jsmoutdoorsycrew338 6 месяцев назад

      Same

    • @Babtu78
      @Babtu78 2 месяца назад

      Can i saw your code from: table.insert(votes[vote], player.UserId) to: function round.GetWave(wave, map) becous ei maby know what happend Search for and look if your code is same as 40:16 Check you dont have another player.UserId under: table.insert(votes[vote], player.UserId

  • @marijnschotsman5122
    @marijnschotsman5122 2 года назад +24

    Hey gnomecode! Can you please explain how to make a teleporter to the tower defense game from the hub!

    • @zekkkkkkkk8
      @zekkkkkkkk8 2 года назад

      yeah i have been waiting for it too xd

    • @GnomeCode
      @GnomeCode  2 года назад +20

      That's coming next!

    • @candykid44
      @candykid44 2 года назад

      @@GnomeCode Going to use the TeleportToPrivateServer() function? :) (of teleportservice)

    • @jpkrus
      @jpkrus 2 года назад

      @@GnomeCode Ok well that's nice but when (or will you) do a episode explaining how to make a inventory system for buying towers?

    • @kennethkline7702
      @kennethkline7702 2 года назад

      @@jpkrus gimme gimme gimme gimmie

  • @FlaminFish750
    @FlaminFish750 2 месяца назад

    if you making your own gui and you want to make a whole table of maps so you add a list layout and see that the templates keep on going right, just click wraps true.

  • @bluethedog694
    @bluethedog694 2 года назад +25

    Am I able to change the type of enemies that appear on the different maps?

    • @TheMokeyYT
      @TheMokeyYT 2 года назад +2

      I wish we could

    • @Pealhaha
      @Pealhaha 2 года назад

      Make another game, Model with *Blender* (I use *Photopea*), Simple!

    • @bluethedog694
      @bluethedog694 2 года назад

      @@Pealhaha Yeah thats what I was thinking, but if we have the map voting system then it wouldn't really work.

    • @TheMokeyYT
      @TheMokeyYT 2 года назад

      But he means how do you make different enemies and bosses spawn on different map.

    • @randomreplays
      @randomreplays 2 года назад +1

      @@bluethedog694 Make it like tower defense simulator. Instead of making a map voter just make the main lobby with different maps where u get inside the area and get teleported to the specific map. There you can pretty much copy and paste the code but with different map and enemies.

  • @opakigejmer5072
    @opakigejmer5072 8 месяцев назад +1

    45:15 just saving my spot, best tutorials ever right here tho.

  • @kasf8700
    @kasf8700 Год назад +5

    I'm having this error which happens everytime I click a map to vote (like many others): ServerScriptService.Main.Round:74: invalid argument #1 to 'insert' (table expected, got nil) | Followed by: this error which happens 1 second after the first: Argument 1 missing or nil | I've looked through the comments, tried many different ways people have fixed it, but have had no result. Can someone help resolve this issue?

    • @OguzhanArda-i4w
      @OguzhanArda-i4w 11 месяцев назад

      same:( did u found the fix?

    • @pr0doxz410
      @pr0doxz410 10 месяцев назад

      I am also getting this, did you fix it?

    • @ForgottenGuyReal
      @ForgottenGuyReal 4 месяца назад

      im not sure but it says that like the mapVotes isnt a table and you need the first argument to be a table which it isnt

    • @Ren_piano
      @Ren_piano 3 месяца назад

      i got same can anyone help?

    • @Ren_piano
      @Ren_piano 3 месяца назад

      local ReplicatedStorage = game:GetService("ReplicatedStorage")
      local ServerStorage = game:GetService("ServerStorage")
      local events = ReplicatedStorage:WaitForChild("Events")
      local mob = require(script.Parent.Mob)
      local info = workspace.Info
      local round = {}
      local votes = {}
      function round.LoadMap()
      local votedMap = round.ToggleVoting()
      local mapFolder = ServerStorage.Maps:FindFirstChild(votedMap)
      if not mapFolder then
      mapFolder = ServerStorage.Maps.UbuyashikiHouse
      end

      local newMap = mapFolder:Clone()
      newMap.Parent = workspace.Map

      workspace.SpawnBox.Floor:Destroy()

      newMap.Base.Humanoid.HealthChanged:Connect(function(health)
      if health winScore then
      winScore = #map
      winVote = name
      end
      end

      return winVote
      end
      function round.ProcessVote(player, vote)

      for name, mapVotes in pairs(votes) do
      local oldVote = table.find(mapVotes, player.UserId)
      if oldVote then
      table.remove(mapVotes, oldVote)
      print("Old vote found", oldVote)
      break
      end
      end

      print("Processed vote for", vote)
      table.insert(votes[vote], player.UserId)
      end
      events:WaitForChild("VoteForMap").OnServerEvent:Connect(round.ProcessVote)
      function round.GetWave(wave, map)
      if wave

  • @BBTProductionsArchive
    @BBTProductionsArchive 2 года назад +2

    My tower defense can now have a multiplayer mode! Thanks for the tutorial. Helpful as always. :)

    • @Clash_Studio1
      @Clash_Studio1 2 года назад

      What is the name of your game?

    • @BBTProductionsArchive
      @BBTProductionsArchive 2 года назад

      @@Clash_Studio1 Clash of Arches

    • @Clash_Studio1
      @Clash_Studio1 2 года назад

      @@BBTProductionsArchive yooooo you game very cool, but very ez. If u wanna play my td here is the name (bruh tower defense(pre-alpha))

    • @BBTProductionsArchive
      @BBTProductionsArchive 2 года назад

      @@Clash_Studio1 thank you. The next level is going to be harder... trust me. >:)

    • @Clash_Studio1
      @Clash_Studio1 2 года назад

      @@BBTProductionsArchive Ok I'll wait =)

  • @theoutlaw9759
    @theoutlaw9759 2 года назад +3

    Hey,
    Theres an error in the output(my time rn is 40:52)
    it says:
    ServerScriptService.Main.Mob:49: 1 is not a valid member of Folder "Workspace.Map.Beach.Waypoints" - Server - Mob:49
    line 49 of mob script says "coroutine.wrap(mob.Move)(newMob, map)"
    this only happens on 1 map which is annoying. thanks

    • @mogy6935
      @mogy6935 2 года назад

      it looks like you dont have a waypoint named 1, and the mob is confused double check your waypoints folder?

    • @gotnoja2000
      @gotnoja2000 4 месяца назад

      @@mogy6935 i do have one waypoint named 1

  • @KhalidBro
    @KhalidBro 2 года назад +1

    for people who's voting gui wont load because the character hasnt loaded yet, wrap the round.start() in a function, and connect that function to player.CharacterAdded() inside the checking if there is a player in server .

    • @therock6878
      @therock6878 Год назад +1

      Hey don’t know if you will respawn but he didn’t go over how to make the enemy’s spawn on the other maps and the only map it lets me spawn them on is the basic one how do I fix thsi

  • @MrLazagna
    @MrLazagna 2 года назад +3

    Great tutorial. Keep up the good work!

  • @wallstreetplays
    @wallstreetplays 2 года назад +1

    I love this series, its all coming together

    • @jezzthedevofficial
      @jezzthedevofficial 2 года назад

      I'm getting a error in episode 7 saying ServerScriptService.Main.Tower:67: BodyGryo is not a valid member of Part "Workspace.Towers.SlingerNoob.HumanoidRootPart" - Server - Tower:67 can u pls help you've mad it this far...

    • @danniitv
      @danniitv 2 года назад

      @@jezzthedevofficial just stop spamming this in peoples comments dude, figure it out yourself

    • @jezzthedevofficial
      @jezzthedevofficial 2 года назад

      @@danniitv Be useful

    • @danniitv
      @danniitv 2 года назад

      @@jezzthedevofficial dont be annoying

    • @jezzthedevofficial
      @jezzthedevofficial 2 года назад

      @@danniitv I was only trying to ask for help

  • @bobkerman8930
    @bobkerman8930 2 года назад +4

    Hey gnomecode i found that only you the owner that cant collide with towers and mobs but other named player can how to fix that or is it just me?

  • @toastedtrucker8619
    @toastedtrucker8619 2 года назад +1

    Keep up the good work the main game core is already fantastic

  • @basketball5424
    @basketball5424 2 года назад +4

    Hey gnome code it would be cool if u made a tutorial on how u would if u add a shop gui that allows u to buy the towers
    U start off with starter towers
    And after winning a game u get money
    And then ur be able to buy other towers

    • @EpicgalaxyTOS2
      @EpicgalaxyTOS2 2 года назад +1

      thats prob coming

    • @EpicgalaxyTOS2
      @EpicgalaxyTOS2 2 года назад

      When u make da,lobby u can use the gold script but make it go through the games

  • @greenqz
    @greenqz 3 месяца назад

    could anyone help at 30:00
    where he presses the buttopn and it prints its not coming out
    like when you press the button nothing happens not even a error

  • @dd.ggs0z
    @dd.ggs0z Год назад +4

    I’m at around 45:00, and my towers have stopped attacking. Everything else works, like gui and stuff, but my towers won’t work and it says “unable to index nil with waypoints”. Can someone please help?

    • @Meme_Defenders
      @Meme_Defenders 4 месяца назад

      I am sorry for replying because I don't know how to fix this problem. But did you got a fix for this?

    • @blmsbenas6200
      @blmsbenas6200 3 месяца назад

      @@Meme_Defenders have you found a fix

    • @Meme_Defenders
      @Meme_Defenders 3 месяца назад

      @@blmsbenas6200 If I remember right you have to correct something in the gamecontroller script, but I don't remember exactly what, sorry if I couldn't help

    • @blmsbenas6200
      @blmsbenas6200 3 месяца назад +1

      @@Meme_Defendersit’s fine i found out what it was yesterday

    • @PapiQuack
      @PapiQuack Месяц назад

      @@blmsbenas6200 anyone know the fix for this

  • @pr0doxz410
    @pr0doxz410 10 месяцев назад +2

    I am having the error: invalid argument #1 to 'insert' (table expected, got nil)
    SOLVED!! Make sure that your are sending button.Name in the voteEvent:FireServer and not only button at 30:24. My Error was caused because I sent thorugh the button instance and not the button.Name which is a string.

    • @DantheBeans
      @DantheBeans 10 месяцев назад

      Could you explain this a little bit more cause i am having this same error

    • @iTrulx
      @iTrulx 10 месяцев назад

      @@DantheBeans Inside GameController around Line 353 look for voteEvent:FireServer() ensure button.Name is placed within the ()

    • @justaizee2
      @justaizee2 8 месяцев назад

      @@iTrulx i had done this before i got this error, and it doesn't work for me sadly

    • @WaqyuGames
      @WaqyuGames 3 месяца назад

      Bro tysm ik this is an old comment but still

  • @addisonrowe7403
    @addisonrowe7403 2 года назад +4

    Hey gnomecode love the series could 6ou do some new towers like farms and towers who can only be placed on certain areas like hills?

  • @CornerLurker
    @CornerLurker 2 года назад +2

    A lot of hard work,keep it up!

  • @jezzthedevofficial
    @jezzthedevofficial 2 года назад +7

    I have a idea
    Make towers that have 2 upgrade routs maybe? Who else agrees this would be a good idea?

  • @zoop08_
    @zoop08_ 2 года назад +2

    Gnome build is back

  • @AIO0110
    @AIO0110 2 года назад +26

    You know, I'd really like you to make a final boss system, not only that, but it also has its own music and attacks that stun the towers.
    PD: Almost a year passed and I know a lot of things now, anyways thanks for your help!!! :)

    • @TotallyHighQ
      @TotallyHighQ 2 года назад +2

      Music is easy all you need to do is put in the music into workspace and in the round script all you need to do is game.Workspace.(Music Here).Playing = true same thing for it to no longer play just replace true with false

    • @fuzzythefirefox
      @fuzzythefirefox 2 года назад +1

      and a final boss system is as easy as adding an if statement for the wave it's on and making the Final boss very health-worthy. if you want more than that, then just figure it out I guess. many possibilities from the things you have learned throughout the tutorial, not gonna lie.

    • @tinpothead6586
      @tinpothead6586 2 года назад +1

      Just say if the wave is the last wave then play the music

    • @AIO0110
      @AIO0110 2 года назад +1

      @@tinpothead6586 I realized that a long time ago but anyway thank you for your help

    • @localbreadfan
      @localbreadfan 2 года назад +3

      you could try using a similar system to how towers get targets by giving the boss a range
      then, you could add a bool value to the tower which marks if it's enabled or disabled
      if it's disabled, on the attack function tell it to wait x seconds then re-enable itself
      then just disable all the towers in the range of the boss

  • @bendogvx3073
    @bendogvx3073 2 года назад +1

    Can we just appreciate how much work he spends on there videos

  • @thegamingproyo4417
    @thegamingproyo4417 2 года назад +5

    Suggestion: Can you make a farm tower that gives you more money each round?

    • @wallstreetplays
      @wallstreetplays 2 года назад +3

      This is VERY easy, you need to insert a script and make it give cash to all players whenever the info.Wave.Value changes

    • @nexoshez
      @nexoshez 2 года назад

      make a simple tower, make a function in setupGameGui where it makes the farm give money each round and make it detect the give money value too

    • @fadi172
      @fadi172 Год назад

      @@wallstreetplays Why all players? it should be giving cash to only the owner of the tower right?

    • @monosheshofficial2288
      @monosheshofficial2288 Год назад

      I can make it. It's very very easy

  • @Ambushisme
    @Ambushisme 7 дней назад +1

    @GnomeCode can You help me because my towers dont attack after i did this

  • @ThatDemonicGamer1
    @ThatDemonicGamer1 2 года назад +4

    Tip for map making:
    don't put a border around the map like hills or something cause it can make it feel a bit claustrophobic but if you want to add them make them not too big and just put an invisible wall around the map so they don't jump onto it

  • @candykid44
    @candykid44 2 года назад +1

    I WAS RIGHT, WE'RE GETTING SO MANY TD VIDEOS

  • @ThatDemonicGamer1
    @ThatDemonicGamer1 2 года назад +3

    I have some suggestions for some more episodes on this series:
    1- coding special enemies such as summoners hidden sand mysteries,
    2- coding special towers such as farms and buffing towers,
    3- difficulties,
    4- adding a lobby where you can go to maps and find people there instead of waiting in the game for more people.

    • @jadeholdsworth140
      @jadeholdsworth140 2 года назад

      Extra one
      5-towers with ability's like a airstrike or remove stun
      Summoning towers would fall under 2 ( like a mil base or necromancer )

    • @Kyxxio
      @Kyxxio 2 года назад

      I agree with every idea here lol

    • @ThatDemonicGamer1
      @ThatDemonicGamer1 2 года назад

      @Jade Holdsworth the anti stun and things are what I meant when I said special towers I just gave a few examples, but thx for mentioning those so gnomecode has more clarification that they’re possible tower abilities for a video

    • @SanesytpAnimation
      @SanesytpAnimation 2 года назад

      like tds, cool

    • @ThatDemonicGamer1
      @ThatDemonicGamer1 2 года назад

      @@SanesytpAnimation yeah kind of like the things in tds but I'm mainly looking for the coding so i can make it different but still work the same and not just be a copy of tds

  • @timelinxgames
    @timelinxgames 2 года назад +8

    You should add a veto mode like tower battles does where it resets the maps being shown and shows different one! Maybe in another video

    • @goldengames854
      @goldengames854 2 года назад

      Yes

    • @duck5791
      @duck5791 2 года назад

      that could definitely be possible by using the array system that was used for switching between targeting systems

  • @heitorrauberscussiato1110
    @heitorrauberscussiato1110 2 года назад +1

    AWESOME VIDEO!!!! plz keep like this!!!

  • @ThunderTheLazyGamer
    @ThunderTheLazyGamer 2 года назад +6

    Really cool tutorials. It helps me making a good tower defense game.
    I have some ideas for the series:
    1.Towers with moving vehicle. (Like the military base)
    2.tower shop
    3.skins
    4.support towers. (More dmg, more view, etc)
    That's all i can think of :P

  • @yowalte8006
    @yowalte8006 2 года назад

    TY for pushing these vid so fast

  • @BBTProductionsArchive
    @BBTProductionsArchive 2 года назад +4

    Suggestion: Could you do badge / gamepass towers? I desperately want to make gamepass and badge towers as rewards for beating certain maps, but I don't have the know how to do it! The best I have is moving the models to replicated storage, but then everyone has access to that tower. A tutorial on the subject would be GREATLY appreciated. :)

    • @PHNX_main
      @PHNX_main 2 года назад

      That will most likely be done after implementing the tower store.

    • @BBTProductionsArchive
      @BBTProductionsArchive 2 года назад

      @@PHNX_main I'm not sure if he's doing that though, that's the thing.

    • @Burgzilla
      @Burgzilla Год назад

      bro how did i find you here 💀

  • @ultimatumran3679
    @ultimatumran3679 2 года назад +2

    Im waiting for this series to end so i can start can i ask one question im just wondering if u can do the thing like if theres like 5 maps and its voting can u the shuffle maps like everytime we vote for the map we will see new map
    Like grassland island and wasteland for first voting and for the second voting one or two on the map voting will be replaced by two new maps like iceland and Pixel island this just an example

  • @nill-w2b
    @nill-w2b 2 года назад +3

    Hey Gnomecode! there seams to be a slight issue with the targeting system atm, so say you have a bunch of low-ish hp enemies going down a path, and a high healthed enemy at the back. The towers continue to attack the first in line as its programmed to, but as soon as the high healthed enemy goes within range they all start to target that. This is the case untill the enemies that are first take a turn or reach a new waypoint, and im not really sure on what to do or how to fix it. Thanks!

    • @doinic09
      @doinic09 2 года назад

      I have a different but same problem. Whenever I kill a enemy with a long ranged tower if it is almost out of the range, it just pretty much targets a random enemy

    • @robyn45
      @robyn45 2 года назад

      did you skip the mobile support episode? I'm quite sure he covered this issue in that episode

    • @robyn45
      @robyn45 2 года назад

      @@doinic09 did you skip the mobile support episode? I'm quite sure he covered this issue in that episode

  • @TheMokeyYT
    @TheMokeyYT 2 года назад +2

    When I test with my friends, I see the tower and enemies' animation but my friends don't

    • @frostx9672
      @frostx9672 2 года назад

      Is the game registered on you or on your group

    • @1kairee
      @1kairee 2 года назад

      It's only something that happens in studio, in the actual game that will not occur

    • @SadlekAski
      @SadlekAski Год назад

      if the game registered by group but you registered animations on yourself, only you will see them

  • @AbyssalEmperor
    @AbyssalEmperor 2 года назад +5

    make a shop and a summoner unit next and you can add an evoilve system IT WOULD BE EPIC!

  • @cocostars_37
    @cocostars_37 2 года назад +1

    I'm stuck at 41:15 Whatever i do it keep telling me ---> ServerScriptService.Main.Round:70: invalid argument #1 to 'insert' (table expected, got nil) And I don't find ANY errors inside the scripts.... So why ??? (Btw the vote countdown doesn't work either and i don't see any problems too )
    FIXED : Be sure to say : local votedMap = round.ToggleVoting() ---> my error was that i've forgot to say the ()

    • @Kris-fp4ys
      @Kris-fp4ys 2 года назад +1

      same but i write it right

  • @Adhdreacts
    @Adhdreacts 2 года назад

    And this is the first time I’ve been here within an hour of a video being posted

  • @dheng6813
    @dheng6813 6 месяцев назад +1

    Hmmmmmmmmmmm 0-0 I think-
    Player added function runs every time a player joins. Min player requirement is 3 and when more players joins after the requirement is met, that means it is going to run the function Round.Start multiple times. This would result in multiple maps being cloned and added to workspace.

  • @Babtu78
    @Babtu78 2 месяца назад

    57:50 After i tap other acc tower icant upgrade and sell my tower what should i do?

  • @aidanblakie
    @aidanblakie 2 года назад +2

    When is Chapter 4 Speedbuild???

  • @PioVerdi28
    @PioVerdi28 Год назад +1

    My health isnt setting up at 51:30
    Can someone help me?

  • @leanderking3692
    @leanderking3692 2 года назад +1

    Lol i just finished the previous episode and this just came out :)

  • @exobytesRBLX
    @exobytesRBLX Год назад

    anyone getting the *invalid arguement #1 to 'insert' (table expected, got nil)* error in the *ProcessVote* function, check if the game has started by adding a print just below *function Round.StartGame* - in my case, my Tower module was yielding the Main script (waiting for the map) and it wasn't firing the StartGame function

    • @josefilho5946
      @josefilho5946 Год назад

      make sure the map folder has the same name as the voting icon

  • @goldengames854
    @goldengames854 2 года назад +2

    Can you plz make a tower system so you have to buy the tower and equip it but you only have 5 tower spaces

  • @rrhouseman2856
    @rrhouseman2856 5 месяцев назад

    25:12 the DisplayEndScreen(change) isnt working on mine and just shows a blue line under it please help a brother out man ;-;

  • @endmansans6438
    @endmansans6438 2 года назад +2

    Gnome, can you please add a splash tower and a summon tower before going to the lobby. If you do that, well have an idea on how to make ours

  • @zedsdev1202
    @zedsdev1202 2 года назад +1

    this is almost finished all i want is have a uncopylocked of the game cuz im bad at scripting after this is done will the game be uncopylocked or later?

  • @GamingCadeez
    @GamingCadeez 2 месяца назад

    Tbh, I recommend that the elevator is the one that actually chooses the map just like in tds, it will show the map inside the elevator.

  • @DavitPro
    @DavitPro 11 месяцев назад

    why does the victory screen keep poping up 25:35

  • @ikeraguilar8613
    @ikeraguilar8613 8 месяцев назад +1

    In my output it says ServerScriptService.Main.Mob:30: Attempt to index function with start

  • @kumbadak2726
    @kumbadak2726 2 года назад +2

    Hello sir I want to ask how to make a teleport system from the lobby to the game like in the original tds

  • @TotallyHighQ
    @TotallyHighQ 2 года назад +1

    I decided to delete the other post I made about an error. Bassically I think Gnomecode forgot to move the camera to the workspace. Bassically for anyone who is having an error with something saying Voting isn't a value of workspace.info you need to make a bool value inside it called voting

    • @BlendaCat
      @BlendaCat 2 года назад

      THANK YOU!! YOU LITTERLY JUST SAVED ME FROM NOT BEING ABLE TO CONTINUE!

  • @PopppDev
    @PopppDev 8 месяцев назад +1

    that feeling when u see a bool value that u dont have in your game in the tutorial but then he removes it

  • @RobloxCoding-h9i
    @RobloxCoding-h9i Год назад +1

    if you get a problem with the info folder then you have to make a folder called Voting

    • @tomo_tomato0923
      @tomo_tomato0923 Год назад

      where put folder?

    • @Mr._White404
      @Mr._White404 Год назад

      Where to put folder?

    • @sha1rk
      @sha1rk 10 месяцев назад

      make a BoolValue Called "Voting".
      @@tomo_tomato0923

  • @Polish-Phoenician
    @Polish-Phoenician 2 года назад +1

    Eveything basically works but when i spawn in, it constantly dupes the same template/icon on the tower frame
    h e l p

  • @theuniversalm528
    @theuniversalm528 2 года назад +1

    admin commands would also be cool 0_0
    where you can add multiple accounts as an admin
    and they could cool things like give money, spawn mobs, all of that cool stuff

    • @squigglesz
      @squigglesz 8 месяцев назад

      thats easy just use hd admin custom commands

    • @jinxed-truly
      @jinxed-truly 5 месяцев назад

      @@squigglesz NO EUGH

  • @sniper-rw9bk
    @sniper-rw9bk 6 месяцев назад

    thank you so much :D you are the best teacher in the world!

    • @HowToDoThatYTChannel
      @HowToDoThatYTChannel 4 месяца назад

      Can You Help Me i Did the Tutorial And then Nothing Happens i cant do anything even the voting menu doesn't pop up D:

    • @sniper-rw9bk
      @sniper-rw9bk 4 месяца назад

      @@HowToDoThatYTChannel try adding print statements in each part of ur code that will help in fixing it :)

  • @thewreckingcrew4463
    @thewreckingcrew4463 24 дня назад

    I Know this video is very old by now but just passing on my knowledge, if only Grassland is working and your other maps don't seem to be, make sure your "Base" model has a part named "Head"

  • @Sckee_Real
    @Sckee_Real 2 года назад

    My favorite youtuber at scripting now regrets

  • @HowToName559
    @HowToName559 2 года назад +2

    @GnomeCode Help!! :((( On line 15 of my round script were it says
    local mapFolder = ServerStorage.Maps:FindFirstChild(votedMap)
    it say argument 1 missing or nil
    Can you help me?

    • @Kris-fp4ys
      @Kris-fp4ys 2 года назад

      same

    • @HowToName559
      @HowToName559 2 года назад

      @@Kris-fp4ys in ep.22 he fix this problems​

    • @Kris-fp4ys
      @Kris-fp4ys 2 года назад

      @@HowToName559 YES, THANK YOU SO MUCH

    • @Kris-fp4ys
      @Kris-fp4ys 2 года назад

      @@HowToName559 ya know how to solve the problem ServerScriptService.Main.Round:76: invalid argument #1 to 'insert' (table expected, got nil) - Servidor - Round:76
      i mean, i do it rightly

  • @TRUNKS_T7
    @TRUNKS_T7 5 месяцев назад +1

    gnome can you help me if i put a tower he don't make damage help me please

  • @Condo_SK
    @Condo_SK 2 года назад

    Me seeing episode 1 recently talking bout path finding me checking channel again to see this

  • @callmeghst6542
    @callmeghst6542 2 года назад +1

    For some reason if i have 2 people in the server itll duplicate the map 2 times!!!! Is there any way to fix this pls someone help! ik you dont read comments gnome code but pls i wanna fix this so i can publish the game i made this is the only issue i have left

  • @vivok456
    @vivok456 2 года назад +1

    And how to make a badge for the killed boss?

  • @oofdoof5409
    @oofdoof5409 2 года назад +1

    Awesome series gnome Code i have a idea for a new series simulator games

  • @theplushhead5093
    @theplushhead5093 2 года назад +1

    im getting an error for the "coroutine.wrap(tower.Attack)(newTower, player)", which says ServerScriptService.Main.Tower:221: Argument 1 missing or nil - , this error doesnt make the towers work and it doesnt remove the placeholder tower. Does anyone know how to fix this error?

    • @madrbx1392
      @madrbx1392 2 года назад

      I have the same problem

  • @ImVeg4
    @ImVeg4 2 года назад +1

    thats cool but can you make map selecting in hub too?

  • @ADALYN1993
    @ADALYN1993 2 года назад +1

    hi gnome code can you make some sort of like a placement box or that towers cannot collide with path and any other models?

  • @wawater3022
    @wawater3022 2 года назад +1

    Can anyone help my endscreen doesn't appear when its game over only when its victory what do i do

  • @fictionwojak3595
    @fictionwojak3595 2 года назад

    Man, I am trying to create a Star Wars Tower Defense game (as i've never seen one before) and this is really good.

    • @InternetDweller
      @InternetDweller 2 года назад

      Most of the popular Star Wars games have been taken down for copyright so i would recommend for you to change your topic!

  • @LouisDover-q6b
    @LouisDover-q6b Год назад +1

    i got 2 errors that say
    ServerScriptService.Main.Round:72: invalid argument #1 to 'insert' (table expected, got nil)
    and
    ServerScriptService.Main.Mob:32: attempt to index function with 'Start'
    idk how to fix these ive been trying for 3+ hours. please help
    nvm i fixed because in the main script
    in line 15 (well line 15 for me)
    local map = round.LoadMap
    didnt have the ()
    so i added () at the end which fixed it for me
    i hope it works for anyone else

    • @semisixx4967
      @semisixx4967 Год назад

      I would suggest that you understand what the code you are writing means (I am not trying to be rude, but learning the basics of lua is extremely helpful for writing good code). Since you have already fixed your code, I will just explain why they did not work.
      Here is a guide of definitions:
      function:
      Functions are basically something that returns a value, but has a wide range of uses. An example of a function of math is the linear equation (mx + b). The parameter(or whatever you put in the parenthesis) is whatever being used inside the function. You put a value of x in f(x) to find its value y in y = mx + b.
      nil:
      Nil means that it has no value or it does not exist.
      The first one is because when you use the table.insert function, you pass in two parameters. The three parameters I think is the table that something is being inserted in, where you are placing it in the table, and the thing that you are inserting. When the function runs, it realizes that the table parameter does not have a table in it, and prints an error. Find out why the table value is nil, and it will be fixed.
      In the second one, what you are doing is that you are setting the map, you want it to set to whatever is returned in the round.LoadMap function. By the way, "round" is a table, and the LoadMap function is within the table. The problem is that LoadMap and LoadMap() are two different things; and when you are calling LoadMap, it will look for a value, not the function that you set up.

    • @LouisDover-q6b
      @LouisDover-q6b Год назад

      i fixed it@@semisixx4967

  • @aspectratio_yt
    @aspectratio_yt 10 месяцев назад

    CONGRATS BRO 100K!

    • @aspectratio_yt
      @aspectratio_yt 10 месяцев назад

      i HAVE BEEN WATCHING U SINCE DAY ONE :D

  • @MrQuesoCheddar
    @MrQuesoCheddar 4 месяца назад

    41:05 i got an error " argument 1 missing or nil " when i want to load any map, anyone could help me?

  • @EternalDeveloper
    @EternalDeveloper 2 года назад +1

    Gnome, for me the waypoints bug now help

  • @Cocobid2006
    @Cocobid2006 2 года назад +1

    yo bro if u end all u gonna make it uncopylocked?

  • @ThatDemonicGamer1
    @ThatDemonicGamer1 2 года назад

    I have some more ideas for this series
    1- a shop for buying more towers that you can than select to use,
    2- a way to unlock skins for towers like crates or something,
    3- final boss health bars,
    4- music and sound effects.

    • @TurZ_06
      @TurZ_06 2 года назад

      I think these things are pretty easy to do. Gnomecodes tutorial actually explained to me a lot of things and I was able to make my custom towers properties (hidden detection etc.) custom mobs and a shop. The shop was super easy to make actually. The boss health bars are easy to make too. I haven't done it yet but I have an idea how to do it. Basically you can put a Config folder inside the boss too like Gnomecode did with his towers. After insert a BoolValue and set it to false, name it BossSpawned whatever you want. You can call it from the round script or GameController and make a boss bar GUI that has a Tween (if you want to) and when the boss gets spawned (maybe have a script that checks if there is the Boss in the round) you can say like:
      if mob.config.BossSpawned then -- checks if the bool value is in the mob
      if mob.config.BossSpawned.Value == true then
      gui.BossBar.Visible = true
      end
      end
      if you have made a tween then you can do this
      if mob.config.BossSpawned then
      if mob.config.BossSpawned.Value == true then
      bossbarTween:Play()
      end
      end
      the boss bar you can actually make it go down every time it takes damage by taking the BillboardGui (the health of those mobs that shows up on their head) source code and changing it up a little bit.
      pretty sure that could work (ONE THING, IF YOU HAVE ALREADY MADE IT THEN PLEASE NAME THE LINES THE WAY YOU HAVE NAMED THEM or the way I did.) and they will work only if you have the bossbar tween or you have the boss value
      also, the skins are hard and im gonna test it out to see how to make them.
      if you see any mistakes in my explanation please tell me. Im not that good at explaining lol

    • @ThatDemonicGamer1
      @ThatDemonicGamer1 2 года назад

      Thanks for the tip, although the way my brain works is that if I think of something that might work based on my prior knowledge I need more clarification that that will work so I don’t waste time, cause I don’t have much time on my hands for coding and stuff so I don’t have the time to try something only for it to not work cause right now I only really have time to code on weekends and Fridays so I just design towers and enemies when it isn’t a day that I have time to code

    • @TurZ_06
      @TurZ_06 2 года назад

      @@ThatDemonicGamer1 Oh alright. Well No problem for the tip, I hope it helps other people though

    • @Averageidiot1014
      @Averageidiot1014 2 года назад

      @@TurZ_06 can you help me make a hidden enemy and a hidden detection upgrade???

    • @TurZ_06
      @TurZ_06 2 года назад

      @@Averageidiot1014 sure, where can i help you with? maybe through discord its too much to type on youtube

  • @lakonag
    @lakonag Год назад +1

    in the part where you have
    table.insert(votes[vote], player.UserId)
    it creates this error for me
    ServerScriptService.Main.Round:69: invalid argument #1 to 'insert' (table expected, got nil)
    anyone know how to fix?

    • @lakonag
      @lakonag Год назад

      @victim_victim I did

    • @kamaria2006
      @kamaria2006 Год назад +1

      go to round process vote function and remove the process vote function and paste in this:
      function round.ProcessVote(player, vote)

      for name, mapVotes in pairs(votes) do
      local oldVote = table.find(mapVotes, player.UserId)
      if oldVote then
      table.remove(mapVotes, oldVote)
      print("Old vote found", oldVote)
      break
      end
      end

      print("Processed vote for", vote)
      table.insert(votes[vote], player.UserId)

      events:WaitForChild("UpdateVoteCount"):FireAllClients(votes)
      end
      events:WaitForChild("VoteForMap").OnServerEvent:Connect(round.ProcessVote)

    • @Eldery_Chooos
      @Eldery_Chooos Год назад +1

      @@kamaria2006 TYSM, however instead of
      events:WaitForChild("UpdateVoteCount"):FireAllClients(votes)
      i did
      events:WaitForChild("VoteForMap"):FireAllClients(votes)
      to get rid of the infinte yeid warning

    • @MyRaelName
      @MyRaelName 8 месяцев назад

      Dam your comment made me realise that I had to put "pairs" not "ipairs" thanks

  • @TheMokeyYT
    @TheMokeyYT 2 года назад

    It only shows the voting gui for one person whenever the voting gui becomes visible and it doesn't even become visible in the first place. Can someone tell me where in the video Gnome code makes a voting value in the info folder

  • @דנידסה-כ5ג
    @דנידסה-כ5ג 2 года назад +1

    can we play the game?

  • @foolspark
    @foolspark 2 года назад

    your videos are amazing man. i started watching and following this tutorial series thinking i'd just leave it after a couple of episodes because of boredom, but this is really unlike any other scripting series. i've had tons of fun doing this. i'm only a basic scripter and have learned so much from just a tutorial series. :)

  • @NeoETM
    @NeoETM 2 года назад +1

    I've just noticed that the kill counter only registers the kills you have gotten in that wave, not overall how do we fix this?

    • @GnomeCode
      @GnomeCode  2 года назад +1

      Are you manually setting the kills value to 0 somewhere? In my code, I only ever add to the value.

    • @NeoETM
      @NeoETM 2 года назад +1

      @@GnomeCode crap I've got to check that thank you

  • @daveandbamblifereal
    @daveandbamblifereal 2 года назад +1

    Can someone please help?I was changing the mobs a bit and when I played my game the health and wave gui were broken,I don't know how to fix it now

    • @daveandbamblifereal
      @daveandbamblifereal 2 года назад

      I fixed the wave gui but i cant manage to fix the health gui.... :(

  • @Kritznik
    @Kritznik Год назад +1

    Can someone please help me?
    Who can drop the Game Controller and Round scripts

  • @Tris2066
    @Tris2066 Год назад +1

    When there is less players than minimum players it says waiting for 1 player(s) at the top but the voting still shows up. How to fix? (btw the voting doesn't work when this happens but it is still there)

  • @star_trek-
    @star_trek- 2 года назад +1

    Gnome can please code like special story mission unlocked by killing a specific enemy unit that rarely spawns in the story game stage

  • @KoalaKrush
    @KoalaKrush 2 года назад +2

    Can you add a command system like : !spawn unit unitnamehere 100 and it spawns 100 of that unit?

    • @frostx9672
      @frostx9672 2 года назад +1

      local Folder = game:GetService("ServerStorage"):FindFirstChild("Enemys")
      local Admin = {"PLRNAME"}
      game:GetService("Players").PlayerAdded:Connect(function(plr)
      if not table.find(Admin,plr.Name) then
      return
      end

      plr.Chatted:Connect(function(message)
      local args = message:split(" ")
      local cmd = args[1]:lower()
      if cmd == "?enemy" and Folder:FindFirstChild(args[2]:lower()) then
      local Model = Folder:FindFirstChild(args[2]:lower())
      for count = 1, args[3] do
      local cloned = Model:Clone(task.wait(0.5))
      cloned.Name = Model.Name
      cloned.Parent = workspace.Enemy
      end
      end
      end)
      end)

    • @KoalaKrush
      @KoalaKrush 2 года назад

      @@frostx9672 omg thx so much!!!

    • @KoalaKrush
      @KoalaKrush 2 года назад

      @@frostx9672 does not work. it has an error on line 13. attempt to index nil with 'FindFirstChild'

    • @KoalaKrush
      @KoalaKrush 2 года назад

      fixed it. but nothing spawns

    • @typical5027
      @typical5027 2 года назад

      @@KoalaKrush Where it says ServerStorage:FindFirstChild(“”). It says enemies as that is the name of their mobs folder. Replace what’s inside the brackets with what your mob folder name is.

  • @ConeDev-1
    @ConeDev-1 2 года назад +2

    16:54 Just love how gnomecode deletes the GameRunning BoolValue like nothing happened lol

  • @LatestOfSpeed
    @LatestOfSpeed 2 года назад +1

    Hey @GnomeCode! I am not sure why, but ever since I added the new maps my collision groups are no longer working. Would you know any fix? (Or anybody else also following these amazing tutorials?)

    • @madcowplayz
      @madcowplayz Год назад

      Hey add a wait in your player added script

  • @ASingleBrick
    @ASingleBrick Год назад

    Who can fix the problem that when the map loads the voting gui doesn't go off and it keeps making polls for choosing the map every end of a round.
    Edit : Somehow I literally found out the bug a short while after publishing the comment. For anyone having the same problem. See if local map = round.LoadMap() is line below function round.StartGame() and not after the game is starting in ... or where you do waves.