Graal Forums  

Go Back   Graal Forums > PlayerWorlds > PlayerWorlds Main Forum
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 02-14-2008, 06:18 PM
warmaster70229 warmaster70229 is offline
Banned
Join Date: Jun 2007
Location: Texas ;D
Posts: 111
warmaster70229 is on a distinguished road
Send a message via AIM to warmaster70229 Send a message via MSN to warmaster70229 Send a message via Yahoo to warmaster70229
Infamous, tileset/NPC trouble..

Hello, I would like some help from the global script team, there seems to be a problem with the NPC-Server on infamous...

I created a weapon, -System/Core and placed in it the following code:

PHP Code:
function onActionServerSide(cmd)
{
  echo(
"Hai");
}

//#CLIENTSIDE
function onCreated() 
{
  
removetiledefs();
  
addtiledef("pokeSMOT_InfamousTiles.png""infamous_" 0);
  
loadmap("Infamous.gmap");
  
triggerServer("gui",name,"d00d");
}

function 
onPlayerchats()
{
  if(
player.chat=="/reconnect")
  {
    
serverwarp("Infamous");
  }

The onCreated() function is not called, thus the serverside function i was using to test the onCreated() call was also not called.

Mind me if there is some stupid mistake i made, having some IRL trouble and am not really myself right now...
Reply With Quote
  #2  
Old 02-14-2008, 07:04 PM
Switch Switch is offline
o.o
Switch's Avatar
Join Date: Jan 2007
Location: Philadelphia
Posts: 3,038
Switch has a spectacular aura about
Send a message via MSN to Switch
Quote:
Originally Posted by warmaster70229 View Post
PHP Code:
  triggerServer("gui",name,"d00d"); 
Should be triggerserver("gui",this.name,"d00d");
of course, you can make it triggerServer, doesn't matter xD
__________________
Oh squiggly line in my eye fluid. I see you lurking there on the peripheral of my vision.
But when I try to look at you, you scurry away.
Are you shy, squiggly line?
Why only when I ignore you, do you return to the center of my eye?
Oh, squiggly line, it's alright, you are forgiven.
Reply With Quote
  #3  
Old 02-14-2008, 07:08 PM
xAndrewx xAndrewx is offline
Registered User
xAndrewx's Avatar
Join Date: Sep 2004
Posts: 5,260
xAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud of
make sure that the weapon is being added to the players upon login.
__________________
Reply With Quote
  #4  
Old 02-14-2008, 07:16 PM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
Quote:
Originally Posted by Switch View Post
Should be triggerserver("gui",this.name,"d00d");
of course, you can make it triggerServer, doesn't matter xD
this. isn't needed.
Reply With Quote
  #5  
Old 02-14-2008, 07:39 PM
Crow Crow is offline
ǝɔɐɹq ʎןɹnɔ
Crow's Avatar
Join Date: Dec 2006
Location: Germany
Posts: 5,153
Crow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond repute
Quote:
Originally Posted by DustyPorViva View Post
this. isn't needed.
What Dusty said *points up*
Reply With Quote
  #6  
Old 02-14-2008, 11:23 PM
warmaster70229 warmaster70229 is offline
Banned
Join Date: Jun 2007
Location: Texas ;D
Posts: 111
warmaster70229 is on a distinguished road
Send a message via AIM to warmaster70229 Send a message via MSN to warmaster70229 Send a message via Yahoo to warmaster70229
It is being added, and the triggerserver isn't important, just a way to see if onCreated() was being called, it's the addtiledef() that is important.
Reply With Quote
  #7  
Old 02-14-2008, 11:27 PM
Chompy Chompy is offline
¯\(º_o)/¯
Chompy's Avatar
Join Date: Sep 2006
Location: Norway
Posts: 2,815
Chompy is just really niceChompy is just really niceChompy is just really nice
Send a message via MSN to Chompy
use "/find pokeSMOT_InfamousTiles.png" in rc, to check if it's found and/or downloadable
__________________
Reply With Quote
  #8  
Old 02-14-2008, 11:38 PM
cbk1994 cbk1994 is offline
the fake one
cbk1994's Avatar
Join Date: Mar 2003
Location: San Francisco
Posts: 10,718
cbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond repute
Send a message via AIM to cbk1994
Generally don't use capitalization in Graal file names.

I would change the gmap so it doesn't use capitalization as well.

And also, REMOVE THE LOADMAP! That is for offline only! IT SHOULDN'T BE USED ON A SERVER! Add the name of the gmap to gmaps= in the server options.

And I've found that removeTileDefs() only seems to work if you put a "" inside, but they may have fixed it.
__________________
Reply With Quote
  #9  
Old 02-14-2008, 11:38 PM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
Well it's been said, make sure the player actually has the weapon(it's case sensitive, by the way). You can't put 'Weapon' in the players weapon list when the weapon is called 'weapon'.
Also, you can easily check and see if onCreated is being called by putting player.chat="test" in there.
Reply With Quote
  #10  
Old 02-14-2008, 11:39 PM
napo_p2p napo_p2p is offline
oh snaps
napo_p2p's Avatar
Join Date: Sep 2003
Location: Pismo Beach, California
Posts: 2,118
napo_p2p has a spectacular aura aboutnapo_p2p has a spectacular aura about
Send a message via AIM to napo_p2p Send a message via MSN to napo_p2p
Quote:
Originally Posted by Chompy View Post
use "/find pokeSMOT_InfamousTiles.png" in rc, to check if it's found and/or downloadable
Yes do that first. Also removetiledefs() takes one parameter. You would need to put removetiledefs("");
__________________
Scito hoc super omnia.
Haec vita est tua una sola.
Dum vita superest, utere maxime quoque puncto, momento, et hora quae habes.
Tempus neminem non manet.
Noli manere tempus.
Carpe Diem

Seize the Day.
Reply With Quote
  #11  
Old 02-15-2008, 12:04 AM
warmaster70229 warmaster70229 is offline
Banned
Join Date: Jun 2007
Location: Texas ;D
Posts: 111
warmaster70229 is on a distinguished road
Send a message via AIM to warmaster70229 Send a message via MSN to warmaster70229 Send a message via Yahoo to warmaster70229
I didn't add the loadmap, it was questionable to me, but i thought poke had his reasons :P

Anyways ill try what you guys said and see if it works...

Edit: I checked, it is there AND downloadable, then i checked my graal/levels/tiledefs folder, the tile set isn't even being set.
Reply With Quote
  #12  
Old 02-15-2008, 09:41 AM
xAndrewx xAndrewx is offline
Registered User
xAndrewx's Avatar
Join Date: Sep 2004
Posts: 5,260
xAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud of
are you sure that the weapon is being added to the player?
__________________
Reply With Quote
  #13  
Old 02-15-2008, 01:46 PM
Arch_Angel Arch_Angel is offline
Registered User
Join Date: Apr 2007
Posts: 482
Arch_Angel is on a distinguished road
Send a message via AIM to Arch_Angel
This is because (I think) the tiles are not named properly. Tiles have to have the word 'tileset' in there name for them to load to the Graal folder properly. Try re-naming the tiles to 'pokesmot_infamous-tileset1.png' or soemthing along those lines.
Reply With Quote
  #14  
Old 02-15-2008, 09:18 PM
Pimmeh Pimmeh is offline
Rgesitreed Uesr
Pimmeh's Avatar
Join Date: May 2007
Location: Utrecht, the Netherlands
Posts: 1,586
Pimmeh has a spectacular aura about
Send a message via AIM to Pimmeh Send a message via MSN to Pimmeh
no, not true.
My tileset was always named something along the lines of
quian_new.png or w/e
__________________
Oh, Death,
No wealth, no ruin, no silver, no gold
Nothing satisfies me but your soul
Reply With Quote
  #15  
Old 02-15-2008, 10:53 PM
napo_p2p napo_p2p is offline
oh snaps
napo_p2p's Avatar
Join Date: Sep 2003
Location: Pismo Beach, California
Posts: 2,118
napo_p2p has a spectacular aura aboutnapo_p2p has a spectacular aura about
Send a message via AIM to napo_p2p Send a message via MSN to napo_p2p
warmaster, try to catch me on AEON sometime, and I'll be glad to help you out personally.
__________________
Scito hoc super omnia.
Haec vita est tua una sola.
Dum vita superest, utere maxime quoque puncto, momento, et hora quae habes.
Tempus neminem non manet.
Noli manere tempus.
Carpe Diem

Seize the Day.
Reply With Quote
  #16  
Old 02-15-2008, 11:15 PM
cbk1994 cbk1994 is offline
the fake one
cbk1994's Avatar
Join Date: Mar 2003
Location: San Francisco
Posts: 10,718
cbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond repute
Send a message via AIM to cbk1994
Quote:
Originally Posted by Inverness View Post
Don't give people advice when you don't know what you're talking about, thanks.
Is this just your personality? I've been told by everyone NEVER use it online. You could ... I don't know ... tell me instead of just be rude about it ...
Quote:
Originally Posted by Inverness View Post
If you knew how to read the Wiki you would know this.
Where did I ever say I didn't know how to read the Wiki? "Not knowing how" and "not reading every page" are completely different things ...
__________________
Reply With Quote
  #17  
Old 02-15-2008, 11:27 PM
Inverness Inverness is offline
Incubator
Inverness's Avatar
Join Date: Aug 2004
Location: Houston, Texas
Posts: 3,613
Inverness is a jewel in the roughInverness is a jewel in the rough
Quote:
Originally Posted by cbkbud View Post
<snip>
My apologies for the rudeness, it comes naturally and I get rather incensed when people give bad advice when it comes to things like scripting.
Quote:
Originally Posted by cbkbud View Post
I've been told by everyone NEVER use it online.
Well then, "everyone" is wrong because I've always used it online and it works just fine. I would like to know who "everyone" is and who told them that.

And another thing, there is no reason for loadmap to be just for offline considering:
Quote:
Originally Posted by Wiki
For offline editing add the gmap name as a new line to a file loadgmaps.txt which must be put in your Graal Editor base folder. The editor will automatically load the gmap once it is started and will correctly link levels.
Which invalidates any reason for loadmap being offline only if this method exists. This method is actually better since you don't have to bother having the script in the level.
__________________
Reply With Quote
  #18  
Old 02-16-2008, 12:15 AM
Arch_Angel Arch_Angel is offline
Registered User
Join Date: Apr 2007
Posts: 482
Arch_Angel is on a distinguished road
Send a message via AIM to Arch_Angel
Quote:
Originally Posted by Pimmeh View Post
no, not true.
My tileset was always named something along the lines of
quian_new.png or w/e
well the lates time i tried something like that, the tiles didnt load. then i talked to dusty, and he said i had to put tileset in the name of it for it to load properly. have you done this recently ? maybe it is an update or something, im not sure. but thats just wat i was told
Reply With Quote
  #19  
Old 02-16-2008, 02:12 AM
Inverness Inverness is offline
Incubator
Inverness's Avatar
Join Date: Aug 2004
Location: Houston, Texas
Posts: 3,613
Inverness is a jewel in the roughInverness is a jewel in the rough
Quote:
Originally Posted by Arch_Angel View Post
and he said i had to put tileset in the name of it for it to load properly.
Good lord. Where do you people get your information from? That is completely WRONG.
__________________
Reply With Quote
  #20  
Old 02-16-2008, 05:38 AM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
Hmm? I don't remember saying anything like that.
Reply With Quote
  #21  
Old 02-16-2008, 09:49 PM
Inverness Inverness is offline
Incubator
Inverness's Avatar
Join Date: Aug 2004
Location: Houston, Texas
Posts: 3,613
Inverness is a jewel in the roughInverness is a jewel in the rough
I would recommend using this.name instead of just 'name' I had a case where using that actually fixed an odd bug which I believe was with the engine itself.
Quote:
Originally Posted by cbkbud View Post
And also, REMOVE THE LOADMAP! That is for offline only! IT SHOULDN'T BE USED ON A SERVER! Add the name of the gmap to gmaps= in the server options.
Read:
Quote:
Originally Posted by http://wiki.graal.net/index.php/Creation/Dev/GMap#Deployment
For speeding up the entering of maps you can preload gmaps on clientside using the script command "loadmap <mapname>;". This is actually not required, but will reduce the loading time when the player is warped onto the map.
The gmaps server option is mainly so the server can know what the gmaps are, not for the client.

By the way, if you're going to leave me negative rep, be nice and leave your name.
__________________
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 01:05 PM.


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