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
 

Simple ~ not working

Previous Thread :: Next Thread 
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 11:38 AM
so i made a local script and i put this is StarterGui. Still doesn't seem to work.

local gps = game:GetService("GamePassService")

local gpid = 208731388
local speed = 25
local player = game.Players.LocalPlayer
wait(1/3)
if gps:PlayerHasPass(Player, gpid) then
player.Character:WaitForChild("Humanoid").WalkSpeed = speed
end
Report Abuse
RenderSettings is not online. RenderSettings
Joined: 16 Aug 2010
Total Posts: 2560
29 Jan 2015 11:39 AM
You shouldn't check if a player has a pass on the client. Do that on the server, or else people will be able to cheat it via Fiddler.
Report Abuse
TheRobloxian909 is not online. TheRobloxian909
Joined: 08 Aug 2013
Total Posts: 2444
29 Jan 2015 11:39 AM
(Player, gpid)

Try typing 'player' with no capital letters!
Report Abuse
Rellica is not online. Rellica
Joined: 11 May 2013
Total Posts: 955
29 Jan 2015 11:41 AM
ROBLOX's servers need to reset to actually approve that the player has it, unless you use the equipIfPurchased (only works for gear sales) I recommend using a Product instead.
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 11:48 AM
I have tried making the P of player not capitalized, still doesn't seem to work. I'm not to sure where to put the 'Product' in the script and what to replace, would you mind showing me?
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 11:54 AM
b1
Report Abuse
ByDefault is not online. ByDefault
Joined: 25 Jul 2014
Total Posts: 3197
29 Jan 2015 11:56 AM
You cant use :PlayerHasPass in a LocalScript
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 12:02 PM
Would you mind fixing it for me, im not sure what to do
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 12:22 PM
b2
Report Abuse
epicbreaker is not online. epicbreaker
Joined: 23 Apr 2011
Total Posts: 2791
29 Jan 2015 12:28 PM
Why does no one use :PlayerOwnsAsset()?

As for your script:

if game.MarketplaceService:PlayerOwnsAsset(player, gpid) then
repeat wait() until Player.Character
player.Character:WaitForChild("Humanoid").WalkSpeed = speed
end
Report Abuse
epicbreaker is not online. epicbreaker
Joined: 23 Apr 2011
Total Posts: 2791
29 Jan 2015 12:30 PM
PS: You were calling for "Player", when you actually only defined "player".
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 12:36 PM
Sorry but where do i put the Gamepass id?
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 12:56 PM
bumpp
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 01:17 PM
b1?
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 01:25 PM
b4
Report Abuse
epicbreaker is not online. epicbreaker
Joined: 23 Apr 2011
Total Posts: 2791
29 Jan 2015 01:52 PM
gpid.
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 02:02 PM

if game.MarketplaceService:PlayerOwnsAsset(player, 208731388) then
repeat wait() until Player.Character
player.Character:WaitForChild("Humanoid").WalkSpeed = speed 24
end

Not sure if that's where you were suppose to put it, and it doesn't recognize '24'
Report Abuse
epicbreaker is not online. epicbreaker
Joined: 23 Apr 2011
Total Posts: 2791
29 Jan 2015 02:04 PM
You put it in the right place. however you could've just kept it as gpid. (Since you already defined it as a variable.)

Also:
player.Character:WaitForChild("Humanoid").WalkSpeed = 24
Report Abuse
epicbreaker is not online. epicbreaker
Joined: 23 Apr 2011
Total Posts: 2791
29 Jan 2015 02:05 PM
speed was defined as a variable, so you can either put speed or 24.

EG1: player.Character:WaitForChild("Humanoid").WalkSpeed = speed
EG2: player.Character:WaitForChild("Humanoid").WalkSpeed = 24

They would both turn out the same in this case.
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 03:17 PM
this still wont work.



local gpid = 208731388
local speed = 25
local player = game.Players.LocalPlayer

if game.MarketplaceService:PlayerOwnsAsset(player, 208731388) then
repeat wait() until player.Character
player.Character:WaitForChild("Humanoid").WalkSpeed = 25
end
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 03:26 PM
b5
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 03:32 PM
b6
Report Abuse
epicbreaker is not online. epicbreaker
Joined: 23 Apr 2011
Total Posts: 2791
29 Jan 2015 03:41 PM
Any error in the console?
Report Abuse
epicbreaker is not online. epicbreaker
Joined: 23 Apr 2011
Total Posts: 2791
29 Jan 2015 03:42 PM
PS: Only bump once every half-hour.
Report Abuse
mulJR is not online. mulJR
Joined: 25 Dec 2012
Total Posts: 305
29 Jan 2015 05:42 PM
No cant find an error in the server console
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 2Go to page: [1], 2 Next
 
 
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