![]() |
New Scripter On The Block :)
This is me being the guy who started learning scripting today.
function onCreated(){ e = "Penguin"; say(e); } function onCreated(){ e = "Penguin"; player.chat = e; ; Now, the first would make me say penguin with anything I said correct? And the second would be only when I said e? |
Would need to be say2 and it should not be in onCreated() I guess.
say2() displays a "sign", while assigning something to player.chat is changing the text over the player. Instead of onCreated(), which is only called when the object is created, you should use onPlayerEnters() or similar. |
Ah thanks Stefan old boy. ;) Didn't your birthday just pass? :o I could be wrong.
|
Quote:
NPC Code: That will start the whole ball rolling, now you want to return something when you say e? NPC Code: and return something else otherwise? NPC Code: Now lets put it all into practice. NPC Code: Hope I have helped you some. |
I think I understand what you did. The way you scripted turned it into an action I'm guessing? By the if (player.chat == "e") this means if the player types the word e nd presses enter the player chat will turn into Penguin whereas using say2 it will be a box/sign?
|
Assuming you knew GS1
NPC Code: is PHP Code:
NPC Code: is PHP Code:
|
Quote:
|
Quote:
|
PHP Code:
|
Quote:
PHP Code:
|
| All times are GMT +2. The time now is 07:40 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.