Graal Forums  

Go Back   Graal Forums > Development Forums > Tech Support
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 08-17-2009, 12:17 AM
Matt Matt is offline
iZone Administrator
Matt's Avatar
Join Date: Apr 2005
Location: United States
Posts: 2,690
Matt is a jewel in the roughMatt is a jewel in the rough
Gralats and Bombs

My problem is that Gralats and Bombs are not being put on the the gmap when used. Bombs just don't show anymore, and when dropping Gralats, the gralat chargani isn't being set at all.

Suggestions?
__________________
Need Playerworld or Account support?
GraalOnline/Toonslab Support Center
Reply With Quote
  #2  
Old 08-17-2009, 01:49 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
For bombs:
PHP Code:
function onWeaponfired() {
  
freezeplayer(.1);
  
setani("lay",null);
  
temp.layx player.int(player.x/64)*64 .5 vecx(player.dir)*2;
  
temp.layy player.int(player.y/64)*64 vecy(player.dir)*2;
  
putbomb(1,this.layx,this.layy);

For gralats, Stefan enabled functions for detecting when things like gralats and hearts and such are dropped, so that you can replace them easily with your own NPCs(like the scripted gralats do).
Reply With Quote
  #3  
Old 08-17-2009, 02:39 AM
Matt Matt is offline
iZone Administrator
Matt's Avatar
Join Date: Apr 2005
Location: United States
Posts: 2,690
Matt is a jewel in the roughMatt is a jewel in the rough
My talent with Scripting is garbage, so bare with me. So i replaced the current Bomb 'WEAPON' script with what's shown above, but no bombs are removed from current amount, nor is the bomb placed. Possible gani problem (Considering i don't see 'lay' in the ganis folder)?
__________________
Need Playerworld or Account support?
GraalOnline/Toonslab Support Center
Reply With Quote
  #4  
Old 08-17-2009, 02:44 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
Well it has to be clientside, with this:
//#CLIENTSIDE
at the top, and then player.bombs--; should suffice to deplete bombs. Also...
The first if checks if the player's bombs are at 0, if they are, it returns and therefor stops the rest of the function from being executed.
PHP Code:
//#CLIENTSIDE
function onWeaponfired() {
  if (
player.bombs <= 0) return;
  
player.bombs--;
  
freezeplayer(.1);
  
setani("lay",null);
  
temp.layx player.int(player.x/64)*64 .5 vecx(player.dir)*2;
  
temp.layy player.int(player.y/64)*64 vecy(player.dir)*2;
  
putbomb(1,layx,layy);


Last edited by DustyPorViva; 08-17-2009 at 03:06 AM..
Reply With Quote
  #5  
Old 08-17-2009, 02:59 AM
Matt Matt is offline
iZone Administrator
Matt's Avatar
Join Date: Apr 2005
Location: United States
Posts: 2,690
Matt is a jewel in the roughMatt is a jewel in the rough
Also no good, the gani is performed, and everything else, but the bomb does not appear.

Edit: Apparently everyone cannot see their own bombs, only others.
__________________
Need Playerworld or Account support?
GraalOnline/Toonslab Support Center
Reply With Quote
  #6  
Old 08-17-2009, 03:06 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
Sorry, I've edited it. Try it now?
Reply With Quote
  #7  
Old 08-17-2009, 03:45 AM
Matt Matt is offline
iZone Administrator
Matt's Avatar
Join Date: Apr 2005
Location: United States
Posts: 2,690
Matt is a jewel in the roughMatt is a jewel in the rough
That did the trick, thanks.

Would you happen to have the default gralat script?
__________________
Need Playerworld or Account support?
GraalOnline/Toonslab Support Center
Reply With Quote
  #8  
Old 08-17-2009, 03:49 AM
cyan3 cyan3 is offline
Registered User
cyan3's Avatar
Join Date: Nov 2005
Location: England
Posts: 2,919
cyan3 has a brilliant futurecyan3 has a brilliant futurecyan3 has a brilliant futurecyan3 has a brilliant futurecyan3 has a brilliant futurecyan3 has a brilliant futurecyan3 has a brilliant future
Quote:
Originally Posted by Matt View Post
That did the trick, thanks.

Would you happen to have the default gralat script?
Here is the default gralat script.

PHP Code:
function onCreated() {

  
showcharacter();

  
updategani();

}

function 
onUpdategani() {

  
updategani();

}

function 
updategani() {

  
temp.type 1;

  if (
rupees>=100temp.type 4;

  else if (
rupees>=30temp.type 3;

  else if (
rupees>=5temp.type 2;

  
setcharani("gralats"temp.type);

}

function 
onPlayerTouchsMe() {

  
player.rupees += rupees;

  
rupees 0;

  
destroy();


Reply With Quote
  #9  
Old 08-17-2009, 03:54 AM
Matt Matt is offline
iZone Administrator
Matt's Avatar
Join Date: Apr 2005
Location: United States
Posts: 2,690
Matt is a jewel in the roughMatt is a jewel in the rough
Well i replaced our current one (Had a mix of GS1 and GS2 i noticed) with this one you just posted, but no fix. The Rupee drops, but the gani still isn't being set.

EDIT: Restarting the NPC-Server after adding the script provided above worked, thanks for you help guys, appreciate it.
__________________
Need Playerworld or Account support?
GraalOnline/Toonslab Support Center
Reply With Quote
  #10  
Old 08-17-2009, 06:20 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 Matt View Post
Possible gani problem (Considering i don't see 'lay' in the ganis folder)?
For future reference, Ganis like "idle", "grab", "push", "swim", etc. are default Gani files and don't need to be put in the filebrowser unless changed (which shouldn't be done; a server should have their own Gani name and use replaceAni(old,new))
__________________
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
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 03:28 PM.


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