generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Change "z" to zoom to Right Click?

Previous Thread :: Next Thread 
coolninja1234 is not online. coolninja1234
Joined: 15 Jul 2009
Total Posts: 128
08 Jun 2014 07:03 PM
Instead of zooming with "z" what do I type to use the mouse right click and hold?
Report Abuse
ComBatPro is not online. ComBatPro
Joined: 27 Dec 2010
Total Posts: 205
08 Jun 2014 07:04 PM
I don't know what you're talking out zoom with z
Report Abuse
coolninja1234 is not online. coolninja1234
Joined: 15 Jul 2009
Total Posts: 128
08 Jun 2014 07:08 PM
This is a part of the script, its for a sniper. If I change the "z" to another letter it will use that letter. How can I make it use Hold Right click on the mouse instead of a letter?
-Thanks


function onEquipped(mouse)
plr=game.Players.LocalPlayer
equipped=true
if mouse~=nil then
mouse.Icon="http://www.roblox.com/asset/?id=18662154"--"rbxasset://textures\\GunCursor.png"
mouse.KeyDown:connect(function(key)if key thenkey=string.lower(key)if key=="r" then reload()elseif
key=="z" and canzoom~=0 and not reloading and equipped then
print(key .. " FOUND ME")
local cam=game.Workspace.CurrentCamera
if cam then
zoomed=math.floor(cam.FieldOfView+.5)
zoomgui.Parent=plr.PlayerGui
Report Abuse
calebpwns1002 is not online. calebpwns1002
Joined: 29 Mar 2013
Total Posts: 521
08 Jun 2014 07:28 PM
MouseButton2Down i believe.
Report Abuse
ComBatPro is not online. ComBatPro
Joined: 27 Dec 2010
Total Posts: 205
08 Jun 2014 07:31 PM
local player = game.Players.LocalPlayer
local mouse = player:GetMouse()

function zoom()
--ur code
end

mouse.Button2Down:connect(function()
zoom()
end)
Report Abuse
iStarry is not online. iStarry
Joined: 14 Nov 2012
Total Posts: 245
08 Jun 2014 07:38 PM
^^^^
Report Abuse
iStarry is not online. iStarry
Joined: 14 Nov 2012
Total Posts: 245
08 Jun 2014 07:39 PM
; You didn't need all that crap; it's a pretty simple script.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image