therustoldfather submitted a new resource:
Simple FOV Changer - FOV Changer
Simple FOV Changer - FOV Changer
Read more about this resource...
Read more about this resource...
Approved, but fix your code.therustoldfather submitted a new resource:
Simple FOV Changer - FOV Changer
Read more about this resource...
Read the rest of this update entry...Code changed.
Thanks for DreTax
Will add to my plug-in "Drugs"therustoldfather updated Simple FOV Changer with a new update entry:
Code is fixed!
Read the rest of this update entry...
Read the rest of this update entry...
- Player commads: /fov basis , /fov normal , /fov high
Basis: 65
Normal: 75
High: 85
- Easier management
- No more error messages*
Code
![]()
by...
I saw that you were doing multiple "switch" checks in the code. I think you didn't understand how does switch work properly, so I hope this one will be clear for you:therustoldfather updated Simple FOV Changer with a new update entry:
New features!
Read the rest of this update entry...
function On_PlayerConnected(Player)
{
Player.SendCommand("render.fov 85");
}
function On_Command(Player, cmd, args)
{
if(cmd == "fov")
{
switch(args[0])
{
case "basis":
Player.SendCommand("render.fov 65");
Player.MessageFrom("FOV Changer", "Your FOV has changed. (65)");
break;
case "normal":
Player.SendCommand("render.fov 75");
Player.MessageFrom("FOV Changer", "Your FOV has changed. (75)");
break;
case "high":
Player.SendCommand("render.fov 85");
Player.MessageFrom("FOV Changer", "Your FOV has changed. (85)");
break;
default:
Player.MessageFrom("Invalid Command!");
break;
}
}
}