Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   Commands that elude me (https://forums.graalonline.com/forums/showthread.php?t=59509)

ChibiChibiLuc 06-18-2005 08:49 PM

Commands that elude me
 
Elude.. Hehe.. Funny word.
Anyway, I'm making a commands.rtf for the new engine.
I either don't know the usage of the following commands or I don't know what part of the syntax is. Can anyone give me a hand? I know some are probably irrelevant to a regular server.
I can't play around with GS2 at the moment. :(

synctimeofday(float, float) (Irrelevant?)

setcontentcontrol(obj) (No clue.)

emoticonchar (What does it return?)
requesttext(str, str) (I want to make sure I listed all the things it can request)
triggerserver(str, str, str) - I need the syntax. :/

Evil_Trunks 06-18-2005 09:18 PM

Quote:

Originally Posted by ChibiChibiLuc
timevar2 (Can't remember what the interval it increases at is.)

seconds since 00:00:00 UTC, January 1, 1970, with nanoseconds precision

Ajira 06-18-2005 09:42 PM

A lot of them are for 3D servers, like cursoron() and off, also the matrix and vector functions.

Velox Cruentus 06-19-2005 01:02 AM

PHP Code:

 sortascending() 

Sorts list GUIs

PHP Code:

 getobjectat(floatfloat)
 
getobjectatmouse() 

I guess getobjectat(x,y), returning the npc object as a variable.

PHP Code:

worldclockstopped
worldhour
worldminute
worldminutesofday
worldrealsecondsperday 

Time variables? Perhaps was for NewWorld or something?

PHP Code:

waterheight
getsurfacetype
(floatfloat

Graal 3D

PHP Code:

gravity 

Gravity effects Shoot commands. Perhaps other use in Graal 3D as well.

PHP Code:

 getz(floatfloat) (No clue.) 

GMap

PHP Code:

 requestfilesmove(strstr

From... To.

PHP Code:

 timershow() 

Displays remaining timeout via chat.


I can't go through them all. They seem to be mostly for Graal 3D

Rick 06-19-2005 05:49 AM

HTML Code:

editingmission - Probably a variable signifying a mission is being edited (Graal3D probably).
waterheight - Graal3D water probably.
getsurfacetype - Graal3D.
popdialog() - Popping a dialog from the stack. Think a layer of cards on which you remove/add cards. Now think of this as GUI windows instead.
pushdialog(obj) - Pushing a dialog onto the stack. See above note.
selectedsword - Graal3D probably.
commandtoserver(str) - Graal3D.
extractfilebase(str) - extractfilebase("directory/file.txt") will return "directory" (or "directory/" ?).
findfirstfile(str) - Iterating through lists of files, removed in v4 I believe.
findnextfile(str) - See above note.
getboxcenter(str) - Graal3D, I assume it returns a vector of the center of a 3D box.
getdatablocktypes() - Graal3D.
getobjectbyray(str, str) - Raycash check for objects. Graal3D.
lightscene() - Graal3D, tells the client to generate a lightmap for the current mission.
mapshapeanimation(str, str, str, float) - Graal3D.
triggerserver(str, str, str) - Just like triggeraction without coords and serverside parameter.

Stuff I can identify is above...

Benm00t 06-19-2005 03:00 PM

Quote:

Originally Posted by Evil_Trunks
seconds since 00:00:00 UTC, January 1, 1970, with nanoseconds precision

How can it have nanosecond precision when it's only counting in seconds.

Evil_Trunks 06-19-2005 08:04 PM

Quote:

Originally Posted by Benm00t
How can it have nanosecond precision

the magic of decimals

Admins 06-20-2005 12:43 AM

Ah its a little bit confusing, most of those commands are from Graal2D and exist for a long time, also you should also list the object type if you list object functions.

emoticonchar - also #E i think, its the character you typed for emoticons (Ctrl+key), this has been added before keydown2 was available

obj.sortascending() / obj.sortdescending() is sorting an array by name

worldminute, syntimeofday etc. is the for Graal3D daynight effect

waterheight - defines the z of the water on terrain (e.g. on Kingdoms)

gravity - can be set on clientside and serverside and defines how much projectiles (shoot) are moved towards the ground, default value is 2 i think, on Zone it is only 0.2 so that projectiles don't fly in a curve

requestfilesmove is for the scripted RC i think, not sure

selectedsword - gives the index of the sword weapon (not sure if its available in normal Graal but it has been used some years ago)

I will add more descriptions to the scripting commands, when you do "Graal4.exe -listscriptfunctions" it is listing all available functions and most built-in variables, and it is also giving some short description for important functions, but I haven't got the time yet to document them all.

ChibiChibiLuc 06-20-2005 01:44 AM

Okay, thank you. :)

If only I had Graal4. :(

CheeToS2 06-20-2005 12:40 PM

Quote:

Originally Posted by Stefan
I will add more descriptions to the scripting commands, when you do "Graal4.exe -listscriptfunctions" it is listing all available functions and most built-in variables, and it is also giving some short description for important functions, but I haven't got the time yet to document them all.

We have been thinking about doing some documentation on #gscript for GS2 with the scriptfunctions file. Is there any specific format it should be written in to make it easier for you to implement, or should the documentation just be written at the end of each line?

Admins 06-20-2005 09:38 PM

Yes just at the end of the line


All times are GMT +2. The time now is 06:12 PM.

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