![]() |
Learning GS2 :D
I was problem solving with Chicken yesterday and he was teaching me about each aspect of GS2. So I learned alot really. Here's a couple things I put together with Chicken_l33t.
Simple Light Switch PHP Code:
PHP Code:
E: Eew wasn't in PHP. My bad. :] |
One of my irl friends wanted to learn @ 3 AM yesterday (around the time you imed me :o).
He made a staff npc or so with a buncha commands in like 20-30 minutes. :P |
PHP Code:
PHP Code:
PHP Code:
PHP Code:
PHP Code:
PHP Code:
PHP Code:
Sorry. ^^ |
Skyld, teach me how to script :(.
|
Quote:
PHP Code:
Quote:
Quote:
Quote:
Quote:
Quote:
|
Here I rewrote it zeroing in on all problems. Be happy Skyld and leave me and my caveman scriptign alone. >:[
PHP Code:
|
Meow. I feel like teaching and stuff, if anyone is paying attention to this forum and wishes to aim me for some scripting help. I'll try to be as of best help as possible even considering it's late, and i'm sick.
Edit: Come onnnnnn i'm bored >_> |
Well, I added you :p, as soon as you lgo on AIM, I will bug you.
|
Quote:
What I previously used was PHP Code:
|
Quote:
This is a lot more efficient, though: (Not to mention, it should work.) PHP Code:
|
there are a couple of minor problems with your code there, problems that will stop it executing the way you expect it to.
PHP Code:
Secondly, comparision is done with == not =. = is used to set values and can be read as "becomes". == can be read as "is equal to", so that line of code should be this: PHP Code:
|
Quote:
|
Now I look like a noob, lol. Anyway good work with the fixing of it killer.
|
Quote:
Also, there are a few errors, such as the semi-colon after the if statement, and the fact that you are missing a curly-brace at the end (which would have been easily distinguishable if you had formatted your code ;)) Fixed (Differentish) version: PHP Code:
|
Quote:
|
| All times are GMT +2. The time now is 09:17 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.