Minimap - Roblox Scripting Tutorial

  Рет қаралды 28,357

Suphi Kaner

Suphi Kaner

Күн бұрын

Discord: / discord
Patreon: / suphi
Donate: www.roblox.com/games/7532473490
create.roblox.com/docs/refere...
0:00:00 - Demo
0:01:47 - Gui
0:04:06 - Local Script
0:14:45 - Camera Offset
0:19:28 - Zoom
0:21:54 - Player Indicator
0:28:47 - Outro

Пікірлер: 127
@sinklz
@sinklz Жыл бұрын
Really good tutorial. The work you're putting into these tutorial videos is much appreciated by the community!
@KebeMaro
@KebeMaro 2 жыл бұрын
You never cease to amaze me with the new unique tutorials!
@gdetonator1182
@gdetonator1182 2 жыл бұрын
A very helpful tutorial keep up the work 👍
@HingerYT
@HingerYT Жыл бұрын
Works really well! Thanks for the tutorial!
@ultra_9861
@ultra_9861 Жыл бұрын
i found the name of your channel in the comments of a roblox studio video that was the best discovery i have ever made it is really interesting to see how this minimap is made and why is it made like this you are literally one of my favorite youtubers now. no joke
@Khaled-bx2zg
@Khaled-bx2zg 2 жыл бұрын
thanks a lot for explaining everything in detail, you deserve more followers! keep up the outstanding work! also can you make a working blade with very good hitbox mechanics thx alot!
@alexandrvu7010
@alexandrvu7010 Ай бұрын
Marvelous work!!!
@ruadhandarcy8111
@ruadhandarcy8111 2 жыл бұрын
Goat youtuber keep up the good work 👏
@devdeepy5665
@devdeepy5665 2 жыл бұрын
Amazing!
@seasoncookie
@seasoncookie Жыл бұрын
This is a amazing tutorial !
@5uphi
@5uphi Жыл бұрын
Thank you
@infinity2394
@infinity2394 Жыл бұрын
YOOOOOOOOOOOOO THIS IS ACTUALLY INSANE
@goreacraft
@goreacraft 2 жыл бұрын
Thank you for the tutorial (i wish you made this a few months ago when i had to make my own minimap script and i am not willing to rewrite it now :P, was to much of a hassle ), but still got some nice ideas from this tutorial. I wonder if your minimap system works well with "SteamingEnabled"?
@5uphi
@5uphi 2 жыл бұрын
The viewport updates as you move from chunk to chunk so if the parts have been streamed by the time you enter a chunk it should be in the mini map or you would need to force update the viewport when a new item gets added
@luketloop
@luketloop Жыл бұрын
The speed in which you type is incredible
@5uphi
@5uphi Жыл бұрын
AutoHotKey
@zesuma
@zesuma Жыл бұрын
Brilliant
@absolute_zero982
@absolute_zero982 2 жыл бұрын
That help alot thank you
@M11NGO
@M11NGO 2 жыл бұрын
Been looking for a tutorial like this for my go karting game for ages wow.
@M11NGO
@M11NGO 2 жыл бұрын
How would I go about making it spin like in racing games, like the map?
@5uphi
@5uphi 2 жыл бұрын
clip decedents and rotating GUI do not work together unfortunately so you would have no choice but to use the full viewportframe and always update the viewports camera so you would not be able to use the optimizations I show in this video if you want to rotate the minimap :(
@M11NGO
@M11NGO 2 жыл бұрын
@@5uphi Ahh glad you told me, also my game has a custom first person that moves as the mouse is moving how could I fix my player's position on the map because it goes normal when I return to third.
@5uphi
@5uphi 2 жыл бұрын
Make sure to set the cameras focus in your custom camera script
@M11NGO
@M11NGO 2 жыл бұрын
@@5uphi I'm trying to see what you mean, I never knew you could even do that. And it shouldn't mess anything up right? sry about the questions.
@cyrusdevs
@cyrusdevs Жыл бұрын
Bro I think I just found out that you have a bot that writes the stuff for you. I hear you making some combination on your keyboard to start it. If I'm wrong, you're probably holding Ctrl+Y or Ctrl+Z or you're typing is just perfect. Keep up the good work btw
@5uphi
@5uphi Жыл бұрын
Ctrl + Alt + V
@cyrusdevs
@cyrusdevs Жыл бұрын
@@5uphi wait its that simple?
@cyrusdevs
@cyrusdevs Жыл бұрын
@@5uphi it doesnt work
@GhettoWxzrd
@GhettoWxzrd Жыл бұрын
@@cyrusdevs his AI needs an update.
@user-xc2hy1ur2h
@user-xc2hy1ur2h 2 жыл бұрын
Thanks!
@sloth-mode
@sloth-mode Ай бұрын
cool
@superstorm4228
@superstorm4228 9 ай бұрын
Thanks for the tutorial. At 5:00 when you run the local script it loops all the objects in the Map folder and clones them into your viewport frame, but when I do it nothing happens because it runs so fast that it loops before any objects can be rendered into the game in the map folder. Why do I have this problem and you don't? Also is there a solution to this problem other than adding a simple wait before I run any of the local scripts code?
@5uphi
@5uphi 9 ай бұрын
You can use childadded to detect when instances get added
@fuckwitbazza8801
@fuckwitbazza8801 Жыл бұрын
local frame = script.Parent local camera = workspace.CurrentCamera local viewportFrame = frame.ViewportFrame for i, descendant in inpairs(workspace.Map:GetDescendants()) do if descendant:IsA("BasePart") == false then continue end local clone = descedant:Clone() clone.Parent = viewportFrame end local viewportCamera = instance.new("Camera") viewportCamera.FieldOfView = 28 viewportFrame.CurrentCamera = viewportCamera local offset = Vector3.new(0, 500, 0) camera.GetPropertyChangeSignal("Focus"):Connect(function()
@alex342gwsturk8
@alex342gwsturk8 Жыл бұрын
i have a question, can viewport frames be on billboardgui and surfacegui or is it screengui only
@5uphi
@5uphi Жыл бұрын
If I remember correctly it can
@Smurfis
@Smurfis Жыл бұрын
I’d like to incorporate a friend system for this and remove the ability to see the “Player2” as well as make it circular
@5uphi
@5uphi Жыл бұрын
all of that is possible check out the discord for help
@YTDani75
@YTDani75 9 ай бұрын
So I've seen the comments about terrain and how the solution would be to represent terrain via parts, but couldn't I just take a screenshot of the entire map from above or draw it and then put it onto the frame while still having the character walk on it?
@5uphi
@5uphi 9 ай бұрын
Yes that is also an option then you don't need a viewport frame simply use a image label
@geonesfa
@geonesfa 9 ай бұрын
does it work for terrain? i made one bbut it didnt do terrain
@mosquito2712
@mosquito2712 2 жыл бұрын
my head trying to understand everything: 🤯🤯
@SuqarSkllz
@SuqarSkllz Ай бұрын
migraine…
@tfx9223
@tfx9223 18 күн бұрын
You’re better off learning Lua concepts rather than bashing your head against tutorials
@xato8673
@xato8673 2 жыл бұрын
tnx you
@yeah7689
@yeah7689 2 жыл бұрын
Can you make a Pistol with recoil and cool effects that damages a player? Also, I found your channel yesterday and I am so glad I did, I made a cool car thanks to you!
@5uphi
@5uphi 2 жыл бұрын
i am trying to think of some good gun code but will most likely not be about the effects but how to make guns not exploitable
@root6132
@root6132 2 жыл бұрын
@@5uphi that’s exactly what we need, making non exploitable weapon/gun system gotta be hella useful, amazing content keep it up ❤️🔥.
@yeah7689
@yeah7689 2 жыл бұрын
@@5uphi I'm fine with that.
@SamLeroSberg
@SamLeroSberg 2 жыл бұрын
Recoil basically just tween the camera's CFrame
@bwah9481
@bwah9481 5 ай бұрын
Tip: Use a noise gate on your mic
@5uphi
@5uphi 5 ай бұрын
Mic problems have been fixed in more recent videos
@akdnberkay
@akdnberkay Жыл бұрын
How can I enlarge the map and see the whole map by pressing a button or tapping on it
@5uphi
@5uphi Жыл бұрын
simply change the size of the outer frame
@G_kendall
@G_kendall Жыл бұрын
hey, im having a problem to where the viewport is outside of the frame
@5uphi
@5uphi Жыл бұрын
the viewport should go outside the frame but when you enable ClipsDescendants it should hide the parts outside the frame but if you rotate the frame then it wont hide it so make sure the rotation is set to 0
@deactivated_.
@deactivated_. Жыл бұрын
I'm really confused because of the first part of the localscript. I have a map with multiple folders inside to count for other uses, so does that not work? When I run my game, the viewport is not there at all. It is just a completely white screen on my minimap.
@5uphi
@5uphi Жыл бұрын
It's down to you to decide what parts get cloned into the viewportframe if it's completely white then it's most likely that your not cloning anything into the viewportframe so it's just a empty frame
@deactivated_.
@deactivated_. Жыл бұрын
@@5uphi This makes sense, because of how you coded it, but I copied every instance underneath the "OldMap" folder (which is what i'm referring to as my map folder). Would it clone everything inside a child folder from "OldMap", such as a Folder inside called "Walls" or "Trees", as an example?
@5uphi
@5uphi Жыл бұрын
if you use getchildren then it will only clone the children if you use getdescendants that it will get everything including things inside sub folders
@deactivated_.
@deactivated_. Жыл бұрын
@@5uphi Alright, thanks. That's probably where I've gone wrong.
@HK_Martin
@HK_Martin 6 ай бұрын
so i copied everything exactly, and for some reason when i walk, the image jumps instead of a smooth transition, and doesn't seem to align with my characters position at all times. i added different parts into the Map Folder but still same result.
@5uphi
@5uphi 6 ай бұрын
Something might be incorrect with your gui
@HK_Martin
@HK_Martin 6 ай бұрын
​@@5uphi i looked over the code many times, i checked the gui, i even changed every single thing in the gui and tried to see how it affected it and still nothing. Edit: whats even weirder is when i copy the minimap system into a different game it works Edit2: The issue happens when the parts are further away from the worlds Y axis. In Order to Fix this i just changed the workspace's Y Position
@user-eb6pb2uh9i
@user-eb6pb2uh9i 4 ай бұрын
Everything works well but there is a issue i can only the bassplate in the map and nothing else
@generic.student3857
@generic.student3857 3 ай бұрын
yeah me too!
@peskybird202
@peskybird202 2 жыл бұрын
Question, would this work on natural terrain or does this only support part-made terrain?
@5uphi
@5uphi 2 жыл бұрын
Viewports are not able to render terrain
@peskybird202
@peskybird202 2 жыл бұрын
@@5uphi gotcha, thanks.
@5uphi
@5uphi 2 жыл бұрын
You could read the terrain voxels or raycast and use that to generate parts that looks like terrain but it won't be very good on performance
@dextertheio2857
@dextertheio2857 19 күн бұрын
how does this guy type so fast?
@user-jy9yv7to8u
@user-jy9yv7to8u Жыл бұрын
Hey do you know if there is a way to make a mini map with terrain?
@5uphi
@5uphi Жыл бұрын
Viewportframes can't render terrain you will have to create parts that emulate the terrain
@akzholtosamaeva117
@akzholtosamaeva117 2 жыл бұрын
😍😍😍😘😘😘
@Embidro
@Embidro 25 күн бұрын
The tuturial is amazing but im just stuck at 19:27 i can't get the chunks to update normally 😭😭
@Embidro
@Embidro 25 күн бұрын
Ye ehm I think I'm quitting this idea it's a great video and I suppose it'll help others real good but I've been searching 40 min+ and still can't find what I've done wrong I have read the script over 3 times to check for any spelling mistakes, Upper/Lower Case and just about anything I just can't find it...
@Embidro
@Embidro 25 күн бұрын
I can still see the viewport updating 🥲
@Embidro
@Embidro 25 күн бұрын
So I rewrote the whole script and you can still see the viewportframe updating anyone know how to fix this? (Time stamp mentioned above)
@5uphi
@5uphi 25 күн бұрын
It might be because content streaming is enabled so when the player enters the game the folder has not loaded yet so nothing is added to the folder You can use child added and child removed to detect when the things are added to the folder to add them to the viewport
@Kitsune_Dev
@Kitsune_Dev 5 ай бұрын
How can I make this work with terrain?
@5uphi
@5uphi 5 ай бұрын
Raycast to find the height of the terrain then place a part in the minimap to represent the terrain
@karlson203
@karlson203 5 ай бұрын
do you know how to translate this into a surface gui?
@5uphi
@5uphi 5 ай бұрын
Simply place the viewport frame into a surface gui
@parrot9148
@parrot9148 2 жыл бұрын
Does it show client sided replications?
@5uphi
@5uphi 2 жыл бұрын
Yes but because the viewport only updates when you move from one chunk to the next chunk you would have to force the viewport to update when something changes so this optimised method works best for things that are anchored and are not moving but if you want to have moving parts it might be best to just have the viewport camera update every frame and not worry about the optimized chunk system I show in this video
@opm_a-ngo2903
@opm_a-ngo2903 10 ай бұрын
would this work with terrain ?
@5uphi
@5uphi 10 ай бұрын
You would have to use parts to represent the terrain
@uzidayo
@uzidayo Жыл бұрын
Why do we move the frame's position instead of the camera?
@5uphi
@5uphi Жыл бұрын
Because when you move the camera the viewport has to render the texture again so if you have 100000s of parts in your viewport its more optimal to move the frames position but you don't have to do it this way if you like you could just move the camera
@uzidayo
@uzidayo Жыл бұрын
@@5uphi Ah, I thought so. So as long as we don't change anything in the viewport (such as the children/properties/cframes or whatever) the viewport will cache the texture instead of re-rendering every frame
@5uphi
@5uphi Жыл бұрын
Correct
@walsterburns450
@walsterburns450 Жыл бұрын
Bro you are should make a game in unity or unreal insteas of roblox studio
@5uphi
@5uphi Жыл бұрын
I like Roblox and Lua is my favourite language but if I did use something else I would most likely try GODOT
@LIVXXET
@LIVXXET 7 ай бұрын
so im following your video and on my end my viewport is only displaying a white screen?
@5uphi
@5uphi 7 ай бұрын
Make sure to follow the video correctly
@LIVXXET
@LIVXXET 7 ай бұрын
@@5uphi thank you
@LIVXXET
@LIVXXET 7 ай бұрын
wait so when i re did it it doesnt send anything to the viewport frame
@5uphi
@5uphi 7 ай бұрын
This is mostly likely because content streaming is turned on by default now You need to use childadded to detect when a part streams in you can also use a model with streaming set to persistent I have a video on content streaming if you need more information
@LIVXXET
@LIVXXET 7 ай бұрын
@@5uphi def would like that thank you
@Luckychew
@Luckychew Жыл бұрын
Hey i've done everything correct and it just doesn't work for some reason.
@5uphi
@5uphi Жыл бұрын
Double check you must of made a mistake somewhere
@Luckychew
@Luckychew Жыл бұрын
@@5uphi i've checked multiple times. it just doesn't work (sorry for late response,forgot about this xD)
@jeanjoensuu8391
@jeanjoensuu8391 2 жыл бұрын
Why map only move front left and back right?
@5uphi
@5uphi 2 жыл бұрын
I did not quite understand the question
@SamLeroSberg
@SamLeroSberg 2 жыл бұрын
@@5uphi He wants it to rotate on your perspective as well. You could do this by rotating the top down-view camera to be the same rotation as the player's Y orientation. Ofc this will look weird when your character is spinning
@5uphi
@5uphi 2 жыл бұрын
Oh well clip descendants and rotating GUI does not work together so if you wanted to rotate the mini map you would have to update the camera every frame
@b5rke_
@b5rke_ 2 жыл бұрын
Working for terrains?
@5uphi
@5uphi 2 жыл бұрын
no you would have to generate lots of parts to represent the terrain
@tohereknowswhen779
@tohereknowswhen779 Жыл бұрын
yoooo
@5uphi
@5uphi Жыл бұрын
Yo
@tohereknowswhen779
@tohereknowswhen779 Жыл бұрын
@@5uphi id really like to learn coding but my inconsistency is against it.. can you give me some tips and proper mindset man? :((( should i take online courses?
@5uphi
@5uphi Жыл бұрын
just do it!, I never took any courses
@_quite.essentiallyjay
@_quite.essentiallyjay Жыл бұрын
damn, I thought I'd find one that could render terrain
@5uphi
@5uphi Жыл бұрын
Only way would be to create parts with raycasting to represent terrain
@_quite.essentiallyjay
@_quite.essentiallyjay Жыл бұрын
@@5uphi hmm i never thought of that as a possibility before thanks for the idea
@indoshonstudios1893
@indoshonstudios1893 10 ай бұрын
Don't wanna be that guy, but like... this just does not work anymore
@5uphi
@5uphi 10 ай бұрын
It does work :)
@indoshonstudios1893
@indoshonstudios1893 10 ай бұрын
@@5uphi You sure? When's the last time you tested it?
@5uphi
@5uphi 10 ай бұрын
if you share your code in discord we can help you fix it
@austincampbell1297
@austincampbell1297 10 ай бұрын
I was also having issues and I found that making the viewport frame 2 times as big as the frame helped solve it. Also be cautious about getting + and * mixed up. Those are the issues I had
@g14n_
@g14n_ 8 ай бұрын
29:29
@jtxdgamer455
@jtxdgamer455 Жыл бұрын
Hey man. I've been trying to write ur script so many times but it just dont wanna work. local frame = script.Parent local camera = workspace.CurrentCamera local viewPortFrame = frame.ViewportFrame for i, descendat in ipairs(workspace.Map:GetDescendants()) do if descendat:Isa("BasePart") == false then continue end local clone = descendat:Clone() clone.parent = viewPortFrame end local viewPortCamera = Instance.new("Camera") viewPortCamera.FieldOfView = 20 viewPortFrame.CurrentCamera = viewPortCamera local offset = Vector3.new(0, 500, 0) camera:GetPropertyChangedSignal("Focus"):Connect(function() local cz = camera.Focus.Position.Z local cx = camera.Focus.Position.X local position = Vector3.new(cx, 0, cz) viewPortCamera.CFrame = CFrame.lookAt(position + offset, position -Vector3.zAxis) end) everything is right idk why its not working. could u please send me the whole script in text ?
@5uphi
@5uphi Жыл бұрын
In the description of the video is a link to the discord channel
@thediamondbowtdb1633
@thediamondbowtdb1633 Жыл бұрын
@@5uphi Bruh where in the discord
@BOB-hy5nz
@BOB-hy5nz 2 ай бұрын
local frame = script.Parent local camera = workspace.CurrentCamera local viewportFrame = frame.ViewportFrame for i, descendant in inpairs(workspace.Map:GetDescendants()) do if descendant:IsA("BasePart") == false then continue end local clone = descedant:Clone() clone.Parent = viewportFrame end local viewportCamera = instance.new("Camera") viewportCamera.FieldOfView = 28 viewportFrame.CurrentCamera = viewportCamera local offset = Vector3.new(0, 500, 0) camera.GetPropertyChangeSignal("Focus"):Connect(function()
Slice / Cut Parts - Roblox Scripting Tutorial
1:10:29
Suphi Kaner
Рет қаралды 58 М.
6 Developers make a Game Without Communicating
15:00
Jackson Academy
Рет қаралды 156 М.
She ruined my dominos! 😭 Cool train tool helps me #gadget
00:40
Go Gizmo!
Рет қаралды 62 МЛН
Luck Decides My Future Again 🍀🍀🍀 #katebrush #shorts
00:19
Kate Brush
Рет қаралды 8 МЛН
Khóa ly biệt
01:00
Đào Nguyễn Ánh - Hữu Hưng
Рет қаралды 21 МЛН
When You Get Ran Over By A Car...
00:15
Jojo Sim
Рет қаралды 4,7 МЛН
I Tested Every FREE Drawing App
22:15
viyaura
Рет қаралды 324 М.
I spent 500 DAYS Building My Roblox Game!
14:21
DeHapy
Рет қаралды 950 М.
31 portals of impossible shape
35:50
optozorax
Рет қаралды 671 М.
Turning an Optical Illusion Into a Playable Character
22:39
ByteBlox
Рет қаралды 700 М.
Roblox Experience Map Size Comparison 🌎🌍🌏
8:39
HalfSplit
Рет қаралды 873 М.
I tried Discord Bot Makers...
14:19
FaceDev
Рет қаралды 84 М.
How pro Roblox developers learnt to script
10:03
AlvinBlox
Рет қаралды 836 М.
Building a Mega Map In Roblox...
6:03
RoBuilder
Рет қаралды 81 М.
My Xbox Wants To Die. I'm Not Letting it.
26:26
Bringus Studios
Рет қаралды 1,1 МЛН
She ruined my dominos! 😭 Cool train tool helps me #gadget
00:40
Go Gizmo!
Рет қаралды 62 МЛН