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
 

Output says "player is not a valid member of DataModel"

Previous Thread :: Next Thread 
wwemaniac99 is not online. wwemaniac99
Joined: 10 Mar 2010
Total Posts: 41496
04 May 2012 09:52 PM
This is the line the output is referring to.

local player = game.player.LocalPlayer.Character
Report Abuse
mage11561 is not online. mage11561
Joined: 03 Sep 2008
Total Posts: 13217
04 May 2012 09:52 PM
local player = game.Players.LocalPlayer.Character
Report Abuse
wwemaniac99 is not online. wwemaniac99
Joined: 10 Mar 2010
Total Posts: 41496
04 May 2012 09:54 PM
oh ok, I had the P capitalized at first, then thought it was wrong because my local wasn't capitalized. But I forgot a s. Thanks
Report Abuse
wwemaniac99 is not online. wwemaniac99
Joined: 10 Mar 2010
Total Posts: 41496
04 May 2012 09:58 PM
Character is not a valid member of DataModel

obj.Name = "Car for " ..player.Character
Report Abuse
mage11561 is not online. mage11561
Joined: 03 Sep 2008
Total Posts: 13217
04 May 2012 09:59 PM
Is this in a localscript inside the player, one of the characters tools, or it's playergui?
Report Abuse
wwemaniac99 is not online. wwemaniac99
Joined: 10 Mar 2010
Total Posts: 41496
04 May 2012 10:03 PM
Local inside a tool in starterpack
Report Abuse
mage11561 is not online. mage11561
Joined: 03 Sep 2008
Total Posts: 13217
04 May 2012 10:05 PM
Post whole script?
Report Abuse
wwemaniac99 is not online. wwemaniac99
Joined: 10 Mar 2010
Total Posts: 41496
04 May 2012 11:42 PM
local tool = script.Parent
function onEquip() -- Finds the player when they equip the tool in game
local player = game.Players.LocalPlayer.Character
local obj = game:GetService("InsertService"):LoadAsset(65487807)
game:GetService("InsertService"):Insert(obj)
obj.Parent = game.Workspace
obj.Name = "Car for " ..player.Character
end
tool.Equipped:connect(onEquip)
Report Abuse
ozza is not online. ozza
Joined: 11 Oct 2007
Total Posts: 726
04 May 2012 11:49 PM
local tool = script.Parent
function onEquip() -- Finds the player when they equip the tool in game
local player = game.Players.LocalPlayer
local obj = game:GetService("InsertService"):LoadAsset(65487807)
game:GetService("InsertService"):Insert(obj)
obj.Parent = game.Workspace
obj.Name = "Car for " ..player.Character
end
tool.Equipped:connect(onEquip)

Come on, you shoudl've caught that one.You defined character.character.
Report Abuse
wwemaniac99 is not online. wwemaniac99
Joined: 10 Mar 2010
Total Posts: 41496
05 May 2012 12:01 AM
"You defined character.character."

What?
Report Abuse
ozza is not online. ozza
Joined: 11 Oct 2007
Total Posts: 726
05 May 2012 12:02 AM
>player = game.Players.LocalPlayer.Character

>player.Character


^ Lines from your code.
Report Abuse
wwemaniac99 is not online. wwemaniac99
Joined: 10 Mar 2010
Total Posts: 41496
05 May 2012 09:08 AM
OH, thanks.
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