|
| 12 Apr 2014 11:27 PM |
I'm not a very skilled Lua scripter by any means, and I really want to have this script.
It's a script that allows someone to type something in the chat-lets say "create dragon", and a model of a dragon appears.
I was thinking of doing something like "Instance.new('Dragon', Workspace)
Would that work? |
|
|
| Report Abuse |
|
|
HEAT507
|
  |
| Joined: 31 Aug 2012 |
| Total Posts: 429 |
|
|
| 12 Apr 2014 11:32 PM |
I herd of asking for help, but dont make the attempt unless your asking anyways
local user=game:service'Players'.you;
user.Chatted:connect(function(obj) if(obj=='create dragon')then game:service'InsertService':loadAsset(ID OF DRAGON HERE):children()[1].Parent=workspace; end; end);
I mean thats how I'd do it the lazy way |
|
|
| Report Abuse |
|
|
| |
|
jbjgang2
|
  |
| Joined: 07 Feb 2010 |
| Total Posts: 8948 |
|
|
| 12 Apr 2014 11:33 PM |
First of all put the dragon into the Lighting.
make this in a local script: local player = game.Players.LocalPlayer
function processCommand(speaker, message) if message == {"create dragon","Create dragon", "Create Dragon", "create Dragon"} then game.Lighting.--Put the name of the dragon model here--:Clone().Position.Vector3 = Vector3.new(0,0,0) --change to the position you want the dragon to appear at end end
game.Players.PlayerAdded:connect(function(player) player.Chatted:connect(function(message) processCommand(player, message) end) end
Swaggin' since 2010 |
|
|
| Report Abuse |
|
|
jbjgang2
|
  |
| Joined: 07 Feb 2010 |
| Total Posts: 8948 |
|
|
| 12 Apr 2014 11:34 PM |
wait sorry, Put this in the local script
local player = game.Players.LocalPlayer
function processCommand(speaker, message) if message == {"create dragon","Create dragon", "Create Dragon", "create Dragon"} then game.Lighting.--Put the name of the dragon model here--:Clone().Position.Vector3 = Vector3.new(0,0,0) --change to the position you want the dragon to appear at-- end end
game.Players.PlayerAdded:connect(function(player) player.Chatted:connect(function(message) processCommand(player, message) end) end
Swaggin' since 2010 |
|
|
| Report Abuse |
|
|
|
| 12 Apr 2014 11:35 PM |
Okay thanks, but I would like to dissect this a little-bit.
local user=game:service'Players'.you; <<--- What do I put in place of this? I want everyone to be able to say this
user.Chatted:connect(function(obj) if(obj=='create dragon')then game:service'InsertService':loadAsset(ID OF DRAGON HERE):children() <---ID of dragon as in a mesh? [1].Parent=workspace; end; end);
|
|
|
| Report Abuse |
|
|
Goulstem
|
  |
| Joined: 04 Jul 2012 |
| Total Posts: 7177 |
|
| |
|
HEAT507
|
  |
| Joined: 31 Aug 2012 |
| Total Posts: 429 |
|
| |
|
HEAT507
|
  |
| Joined: 31 Aug 2012 |
| Total Posts: 429 |
|
|
| 13 Apr 2014 12:04 AM |
it will move the dragon to 0,0,0 and you can get a tool to move it around or whatever l0l
--mokah |
|
|
| Report Abuse |
|
|
HEAT507
|
  |
| Joined: 31 Aug 2012 |
| Total Posts: 429 |
|
|
| 13 Apr 2014 12:04 AM |
| 'you' is where you put your name dont edit anything before that |
|
|
| Report Abuse |
|
|
HEAT507
|
  |
| Joined: 31 Aug 2012 |
| Total Posts: 429 |
|
| |
|
|
| 13 Apr 2014 12:06 AM |
| "l0l","-- mokah" ~Award Winning Phrases by the lovely, HEAT507. |
|
|
| Report Abuse |
|
|