Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   Announcements (https://forums.graalonline.com/forums/forumdisplay.php?f=240)
-   -   New NPCServer (https://forums.graalonline.com/forums/showthread.php?t=134268290)

Admins 06-01-2013 10:35 PM

New NPCServer
 
The npcserver has been updated, some servers have been updated already for the changes:

- Having two functions with the same name in the same script is now reported as error
- Having two switch-cases with the same parameter will be displayed as warning
- Look in logs/syntaxerrors.txt to see errors of NPCs in levels
- If a script is updated and has bugs then the server will continue to run the old script (but the script needs to be fixed before the next server restart)
- New script function [level.]findareaplayers(x,y,width,height)
- Fixed a crashing bug when returning TStaticVar or SQL objects in functions

There is also a problem with setting nicks on some servers, there is a new option which is accidently set to false but should be set to true, so add
PHP Code:

enableclientsidenick=true 

if you see problems with setting nick names with "setnick" or RC.

cbk1994 06-02-2013 12:23 AM

Very nice, especially the new script function. Thanks!

BlueMelon 06-02-2013 12:34 AM

Nice updates

Can you make echo a log-able function
http://forums.graalonline.com/forums...hp?t=134267946

Tim_Rocks 06-02-2013 03:50 AM

Quote:

Originally Posted by Stefan (Post 1718685)
- If a script is updated and has bugs then the server will continue to run the old script (but the script needs to be fixed before the next server restart)

Could this have reverted a script back to a previous state while I'm editing it? I'm curious because I reconnected after I edited a script and everything I did yesterday was reverted to an older version. Does my updated copy just get deleted or moved to a temp file?

cbk1994 06-02-2013 03:56 AM

Quote:

Originally Posted by Tim_Rocks (Post 1718693)
Could this have reverted a script back to a previous state while I'm editing it? I'm curious because I reconnected after I edited a script and everything I did yesterday was reverted to an older version. Does my updated copy just get deleted or moved to a temp file?

My guess would be that the script is simply never updated on the npcserver even though the file is (which is why it has to be fixed before the server is restarted).

Tim_Rocks 06-02-2013 05:22 AM

Quote:

Originally Posted by cbk1994 (Post 1718694)
My guess would be that the script is simply never updated on the npcserver even though the file is (which is why it has to be fixed before the server is restarted).

Well that's not going to be fun if the server crashes if there's an error of some kind and I can't correct it before I'm disconnected.

cbk1994 06-02-2013 05:39 AM

Quote:

Originally Posted by Tim_Rocks (Post 1718695)
Well that's not going to be fun if the server crashes if there's an error of some kind and I can't correct it before I'm disconnected.

Wouldn't be any different than what we had prior to the update.

dylan 06-02-2013 06:01 AM

Is there any way to enable/disable GS3 strict mode?

Cubical 06-02-2013 06:04 AM

Quote:

Originally Posted by dylan (Post 1718697)
Is there any way to enable/disable GS3 strict mode?

As far as i'm aware you just add //#GS3 to your code however it did not work for me so it may have to be activated on your playerworld. Stefan's initial post unclear but implied that it was implemented but did not specifically state it.

dylan 06-02-2013 03:44 PM

Quote:

Originally Posted by Cubical (Post 1718698)
As far as i'm aware you just add //#GS3 to your code however it did not work for me so it may have to be activated on your playerworld. Stefan's initial post unclear but implied that it was implemented but did not specifically state it.

Yes, I was just wondering if there was a servop that would enable it.

Currently, compiling any script with the //#GS3 tag, GS3 included or not, will return something like this:
PHP Code:

GS3 strict mode is not enabledcannot compile -BB/GS3
Weapon
/GUI-script -BB/GS3 added/updated by dylan 


xAndrewx 06-02-2013 05:01 PM

is there any way to make sure all scripts are working fine before we do a restarted?

Lets say someone is updating and doesn't notice an error for example

Draenin 06-02-2013 06:36 PM

Quote:

Originally Posted by Stefan
- New script function [level.]findareaplayers(x,y,width,height)

Does this return a count of players in the area, or the names of the players?

xAndrewx 06-02-2013 06:38 PM

the object of the player

HTML Code:

for (temp.p: findareaplayers(this.x, this.y, 10, 10)) {
  temp.p.chat = "hello";
}


Matt 06-02-2013 08:56 PM

gj :)


All times are GMT +2. The time now is 07:24 AM.

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