Advertisement
Unlocker001_TFM

Untitled

May 6th, 2017
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.58 KB | None | 0 0
  1. --[[
  2. function eventNewPlayer(n)
  3. system.bindMouse(n,true)
  4. end
  5.  
  6.  
  7. for n,i in pairs (tfm.get.room.playerList) do
  8. eventNewPlayer(n)
  9. end
  10.  
  11. --]]
  12.  
  13. system.bindMouse("Turkitutu",true)
  14.  
  15. i=1
  16. x1=0
  17. y1=0
  18. function eventMouse(n,x,y)
  19. if i == 1 then
  20. i=2
  21. x1=x
  22. y1=y
  23. elseif i == 2 then
  24. w=x-x1
  25. y=y-y1
  26. wi=x-x1
  27. w=(w < 0 and math.abs(w) or w)
  28. xi=(wi < 0 and x1+(w/2)-w or x1+(w/2))
  29. tfm.exec.addPhysicObject(1,xi,y1,{type=1, height=10, width=w, angle=math.deg(math.tanh (math.tan(w/y))), friction=8, restitution=0, dynamic=false,foreground=true,color="0xE61414",miceCollision=true})
  30.  
  31. i=1
  32. end
  33. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement