Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   Old Scripting Engine (GS1) (https://forums.graalonline.com/forums/forumdisplay.php?f=154)
-   -   GS1 script will not run, why? (originally 'GS1 question') (https://forums.graalonline.com/forums/showthread.php?t=81244)

Exhausted 08-15-2008 03:08 PM

GS1 script will not run, why? (originally 'GS1 question')
 
Yay, first thread here in .. how long?

Anyway, I'm not quite sure why this script won't work.

if (playerenters){
timeout = 18.5;
}

if (timeout){
setcharani idle,;
sleep 4;
setcharani sit,;
}


I even tried


if (playerenters){
timeout = 18.5;

if (timeout){
setcharani idle,;
sleep 4;
setcharani sit,;
}
}


So I dunno. I tried a few different things, but none of them worked. What am I missing?

Btw, I know GS1 is outdated, but atm it's easier to learn (or at least experiment with) then GS2.

Codein 08-15-2008 03:51 PM

Are you testing this in the offline editor?

DustyPorViva 08-15-2008 04:05 PM

Why are you using a timeout, and then a sleep for doing basically the same thing?
PHP Code:

if (playerenters) {
  
sleep 18.5;
  
setcharani idle,;
  
sleep 4;
  
setcharani sit,;


Remember, this is not something you would do online. I assume this is for the offline editor.

Exhausted 08-15-2008 04:07 PM

yea


//#CLIENTSIDE.

// Graal2002 NPC by Stefan Knorr
if (created) {
// Initialize the attributes
showcharacter;
setcharprop #3,head0.png;
setcharprop #C0,orange;
setcharprop #C1,red;
setcharprop #C2,black;
setcharprop #C3,blue;
setcharprop #C4,black;
setcharprop #n,wat
setcharprop #2,;
shieldpower = 1;
dir = 2;
}


if (playerenters){
ap = 100;
setcharani sit,;
}


if (playerenters){
timeout = 18.5;
}

if (timeout){
setcharani idle,;
sleep 4;
setcharani sit,;
}

Exhausted 08-15-2008 04:08 PM

hold on

Codein 08-15-2008 04:09 PM

You've got two event blocks for one event. Merge them, and hopefully that'll work. Like, put what's under both if (playerenters) into one if (playerenters)

xXziroXx 08-15-2008 04:11 PM

PHP Code:

setcharprop #n,wat 

Error: missing semicolon.

DustyPorViva 08-15-2008 04:13 PM

Quote:

Originally Posted by xXziroXx (Post 1414619)
PHP Code:

setcharprop #n,wat 

Error: missing semicolon.

Thar be the problem.

Exhausted 08-15-2008 04:15 PM

@Ziro: Yeah, I forgot to add the semicolon back when I changed the script before posting it..

@Dusty. I do a lot of dumb and random stuff while scripting, but I eventually took that out after that post when I found out that wasn't helping any. =o

@Codein. That worked ;o

Thanks for the help, guys and gals.

xXziroXx 08-15-2008 04:22 PM

Quote:

Originally Posted by Exhausted (Post 1414623)
Thanks for the help, guys and gals.

The only gal in this thread is my alter-ego, Zira, and she haven't come out to play for a while.

Exhausted 08-15-2008 04:33 PM

I thought Dusty was female? Or was I misled?

Bleh. Is there a website or anything that displays the full list of GS1 commands?

How come there are GS1 commands that aren't on the list of them to the right of the Graal editor? - Me.

Stefan never updated it - sz.

I poked around and didn't see anything.. heh..

Codein 08-15-2008 04:43 PM

Quote:

Originally Posted by Exhausted (Post 1414625)
I thought Dusty was female? Or was I misled?

Bleh. Is there a website or anything that displays the full list of GS1 commands?

How come there are GS1 commands that aren't on the list of them to the right of the Graal editor? - Me.

Stefan never updated it - sz.

I poked around and didn't see anything.. heh..

Dusty is male.

Also: http://wiki.graal.net/index.php/Crea...ev/Old_GScript

PrinceOfKenshin 08-15-2008 06:16 PM

Quote:

Originally Posted by Codein (Post 1414626)
Dusty is male.

That is still up to debate :D

And try learning gs2 my friend it is a lot easier.

Exhausted 08-15-2008 08:02 PM

Thanks for the link.

I guess I'll look up GS2 sometime and try to learn it..
Learning GS2/GS1 off of guides usually confuses me, so I normally learn it by example and learning how this and that works ;o

Codein 08-15-2008 10:19 PM

Quote:

Originally Posted by PrinceOfKenshin (Post 1414636)
That is still up to debate :D

It failed to be a debate when he posted a picture of himself ;D Also, his name is Phillip :P


All times are GMT +2. The time now is 10:25 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.