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 » Scripters
Home Search
 

Re: FE - RemoteEvents

Previous Thread :: Next Thread 
BlueWizard12345 is not online. BlueWizard12345
Joined: 31 Mar 2012
Total Posts: 906
15 May 2017 06:28 PM
With a turret I'm creating with FE on, I am connecting the mouse's move function to a script that updates the turret's rotation.

The localscript gets the mouse's position and sends it to the server for turret rotating.

Since remoteevents have a request limit, the turret would start lagging to the client after using it for a couple seconds.

How would you guys approach this problem?

Game: https://www.roblox.com/games/270640895/-
Report Abuse
PhoenixSigns is not online. PhoenixSigns
Joined: 17 Sep 2011
Total Posts: 1137
15 May 2017 06:42 PM
Set the network ownership of the turret to the player.
Report Abuse
BlueWizard12345 is not online. BlueWizard12345
Joined: 31 Mar 2012
Total Posts: 906
15 May 2017 06:55 PM
any other ideas?
Report Abuse
BlueWizard12345 is not online. BlueWizard12345
Joined: 31 Mar 2012
Total Posts: 906
15 May 2017 06:57 PM
it would work, but atm my turret parts are welded to an anchored part so it doesn't work
Report Abuse
BlueWizard12345 is not online. BlueWizard12345
Joined: 31 Mar 2012
Total Posts: 906
15 May 2017 07:21 PM
b
Report Abuse
PhoenixSigns is not online. PhoenixSigns
Joined: 17 Sep 2011
Total Posts: 1137
16 May 2017 09:38 PM
How often are you firing your rE?
Report Abuse
BlueWizard12345 is not online. BlueWizard12345
Joined: 31 Mar 2012
Total Posts: 906
17 May 2017 05:40 AM
I ended up using the network ownership idea.

I WAS firing the remote event every time the mouse moved by connecting it to the Mouse.Move function.
Report Abuse
Only_EighteenChars is not online. Only_EighteenChars
Joined: 22 Dec 2010
Total Posts: 505
17 May 2017 06:26 AM
You could also make it so that it's click based - the turret only rotates once the user clicks.

never ever never ever spam Remotes.
Report Abuse
PhoenixSigns is not online. PhoenixSigns
Joined: 17 Sep 2011
Total Posts: 1137
18 May 2017 07:51 PM
^
BlueWizard, no wonder. You should make it fire at most ever RenderStepped or Heartbeat, not every time the mouse moves.
Report Abuse
BlueWizard12345 is not online. BlueWizard12345
Joined: 31 Mar 2012
Total Posts: 906
18 May 2017 09:04 PM
no, that's the same thing it would still lag
Report Abuse
PhoenixSigns is not online. PhoenixSigns
Joined: 17 Sep 2011
Total Posts: 1137
21 May 2017 12:18 AM
Hmmm, maybe rotate the turret locally?
Report Abuse
PhoenixSigns is not online. PhoenixSigns
Joined: 17 Sep 2011
Total Posts: 1137
21 May 2017 12:19 AM
Then when the player clicks the mouse to shoot, the local script can pass the turret tip location to the server, and the server can verify if it's a reasonable location and if so, then fire from the position to the mouse position.
Report Abuse
BlueWizard12345 is not online. BlueWizard12345
Joined: 31 Mar 2012
Total Posts: 906
21 May 2017 09:36 AM
I already have a fix that I've been using: using set network ownership and rotating the turret on the client.
Report Abuse
Spathi is not online. Spathi
Joined: 18 Nov 2013
Total Posts: 14776
21 May 2017 09:38 AM
add a wait function


Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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