Advertisement
Jak92

Untitled

Jul 4th, 2020
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.61 KB | None | 0 0
  1. function GetOurAttachment(ply) // Create a selfmade function, that takes 1 argument.
  2. local ID = ply:LookupAttachment("eyes") // this will return a number corresponding with the given attachment.
  3. return ply:GetAttachment( ID ) // this will return a small table, see GetAttachment for more information.
  4. end // end our function.
  5.  
  6. function GetHeadPos() // create yet another function.
  7. LocalPlayer():ChatPrint("The position of your own head is: "..tostring(GetOurAttachment(LocalPlayer()).Pos).."!") // call our earlier function, and get the position from it so we can display it in our chat.
  8. end // and end this one as well.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement