Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting > New Scripting Engine (GS2)
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 11-22-2005, 07:01 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
Escape Problem

I am having trouble on Rudora regarding escapes.

First, \" does not work properly. It returns scripting errors (like I am about to demostrate). However, I can use \\".

To start, the following script:
PHP Code:
function onCreated()
{
  echo(
"Hello, \"friend\"!");

... is returning the following errors:
HTML Code:
Script compiler output for Test (in level rudora_adminhouse1.nw at pos (30.5, 30)):
error: unexpected token: friend at line 4: friend\""!"");"
error: missing semicolon at line 4: friend\""!"");"
error: unexpected token: \ at line 4: friend\""!"");"
error: unexpected token: ) at line 4: friend\""!"");"
error: unexpected token: " at line 4: friend\""!"");"
The script of npc Test has been updated
What's more, is that when I reopen the script, it all of a sudden has changed (see Database NPC "Test" on Rudora):
PHP Code:
function onCreated()
{
  echo(
"Hello, "
friend\\""!"");"

However, if I use the following instead (escaping the escape):
PHP Code:
function onCreated()
{
  echo(
"Hello, \\"friend\\"!"); 
  
/*
    That has a \\" at the end of "friend" but
    vBulletin is being evil to me
  */

... then it works.

I'm not sure about this myself, but I'd call this a fairly large problem.
__________________
Skyld

Last edited by Skyld; 11-22-2005 at 09:46 PM.. Reason: Better name
Reply With Quote
  #2  
Old 11-22-2005, 07:19 PM
Fox1545 Fox1545 is offline
Registered User
Join Date: Jul 2004
Posts: 78
Fox1545 is on a distinguished road
It works for me ;o
That is because I do not use a development environment that tries to escape and unescape things inconsistently across the varying frontends and backend! Stuff like this has been going on for ages please fix ok
Reply With Quote
  #3  
Old 11-22-2005, 09:30 PM
Admins Admins is offline
Graal Administration
Join Date: Jan 2000
Location: Admins
Posts: 11,693
Admins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud of
Which RC version?
Reply With Quote
  #4  
Old 11-22-2005, 09:35 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
Quote:
Originally Posted by Stefan
Which RC version?
2004/01/17.

Works properly in 2005/11/09, though, but I'm consciously aware that this version is not released.

I thought it was a server problem.
__________________
Skyld
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 05:18 PM.


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