View Single Post
  #4  
Old 12-12-2012, 03:48 AM
sssssssssss sssssssssss is offline
Cyril Rain
sssssssssss's Avatar
Join Date: May 2003
Location: Texas, USA
Posts: 1,134
sssssssssss will become famous soon enough
fowlplay: From my experience proper syntax is temp.var, and I typically initialize the temp.var as so, but nothing so far has stopped it from working as long as its a local var. Although, I went and changed all of them, and changes message to msg and it still isn't working at all....

Dusty: Pretty much the same thing probably. It's just odd because at first I had this, not sending an array through but just single var to the public funciton

PHP Code:
tweenInMessage(temp.msg); 
and it worked fine and sent. Now it's an array, and sub array inside, and it's not working with the if's and such.

Really, really annoying.... anyone else have any other ideas. To explain a little deeper a level npc is just sending the information to this (might as well put updated anyways):

PHP Code:
public function loadDialog(temp.conReturntemp.speakertemp.headtemp.msg)
{
  
// clear all images
  
clearImages();
  
// THIS PLAYER CHAT HAS THE CORRECT VALUE FROM THE ARRAY
player.chat temp.msg[0][0];

  
// set vars
  
this.conReturn temp.conReturn;
  
  
// make player still
  
setani("idle"null);
  
disabledefmovement();
  
  
// move in stuff
  
tweenInHead(temp.head);
  
tweenInName(temp.speaker);
  
  if (
this.conReturn)
  {
    
// THIS PLAYER CHAT RESULTS IN A 0
    
player.chat temp.msg[0][0];
    
tweenInMessage(temp.msg[0][0]);
    for (
temp.0temp.msg[0].size() - 1t++)
    {
      
tweenInChoices(temp.msg[0][i]);
    }
    
this.messageWaiting true;
  }else
  {
    
tweenInMessage(temp.msg);
  }
  
tweenInBG();
  
  
// set to show it's shown up and wait for interaction
  
this.shown true;

This section seems to be the issue:
PHP Code:
if (this.conReturn)
  {
    
player.chat temp.msg[0][0];
    
tweenInMessage(temp.msg[0][0]);
    for (
temp.0temp.msg[0].size() - 1t++)
    {
      
tweenInChoices(temp.msg[0][i]);
    }
    
this.messageWaiting true;
  }else
  {
    
tweenInMessage(temp.msg);
  } 
Just doing
PHP Code:
tweenInMessage(temp.msg
with a single var sent works fine, sending an array gets lost in the if statement.
__________________
Cyril Rain
Creator and leader of SLX
Admin of Elysium
Elysium's Facebook Page: http://facebook.com/GraalOnlineElysium
Graal Forum Thread: http://forums.graalonline.com...
Graalians Thread: http://www.graalians.com...


Reply With Quote