Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 03-17-2007, 09:48 PM
Chandler Chandler is offline
Banned
Join Date: Jan 2007
Posts: 656
Chandler will become famous soon enough
Scheduleevent Error

HTML Code:
function onCreated()
  this.scheduleevent(5, "removeImages", {300, 301});
function onRemoveImages(imageIndexs)
  echo(temp.imageIndexs);
returns:
PHP Code:
300 
Doesn't transmit array types?

Last edited by Chandler; 03-17-2007 at 10:06 PM..
Reply With Quote
  #2  
Old 03-17-2007, 09:51 PM
xXziroXx xXziroXx is offline
Malorian
xXziroXx's Avatar
Join Date: May 2004
Posts: 5,289
xXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant future
Quote:
Originally Posted by Chandler View Post
HTML Code:
function onCreated()
  this.scheduleevent(5, "removeImages", {300, 301});
function onRemoveImages(imageIndexs)
  echo(temp.imageIndexs);
returns:
PHP Code:
300 
Doesn't transmit array types?
Try:

PHP Code:
this.scheduleevent(5"removeImages", @{300301}); 
__________________
Follow my work on social media post-Graal:Updated august 2025.
Reply With Quote
  #3  
Old 03-17-2007, 09:52 PM
Chandler Chandler is offline
Banned
Join Date: Jan 2007
Posts: 656
Chandler will become famous soon enough
No fix, returns same.
Reply With Quote
  #4  
Old 03-17-2007, 09:54 PM
Riot Riot is offline
Delteria Management
Join Date: Nov 2003
Location: Seminole County, Florida
Posts: 280
Riot is on a distinguished road
Quote:
Originally Posted by Chandler View Post
HTML Code:
function onCreated()
  this.scheduleevent(5, "removeImages", {300, 301});
function onRemoveImages(imageIndexs)
  echo(temp.imageIndexs);
returns:
PHP Code:
300 
Doesn't transmit array types?
It passes them as separate params:
HTML Code:
function onCreated() {
  this.scheduleEvent(1, "Test", {"param0", "param1"});
}

function onTest() {
  echo(params[0]);
  echo(params[1]);
}
Returns:
param0
param1

You can get around this by doing an array in an array:
HTML Code:
function onCreated() {
  this.scheduleEvent(1, "Test", { {"param0", "param1"} });
}

function onTest() {
  echo(params[0]);
}
returns:
param0,param1
Reply With Quote
  #5  
Old 03-17-2007, 09:56 PM
Chandler Chandler is offline
Banned
Join Date: Jan 2007
Posts: 656
Chandler will become famous soon enough
Weird, it shouldn't do that!
Thanks for clearing it up, however, I'd like this fixed!
Reply With Quote
  #6  
Old 03-17-2007, 10:05 PM
Riot Riot is offline
Delteria Management
Join Date: Nov 2003
Location: Seminole County, Florida
Posts: 280
Riot is on a distinguished road
Quote:
Originally Posted by Chandler View Post
Weird, it shouldn't do that!
Thanks for clearing it up, however, I'd like this fixed!
trigger(evt,params..) does the same thing, and I would imagine a few others do it as well.
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 04:47 PM.


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