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 11-28-2005, 10:31 PM
excaliber7388 excaliber7388 is offline
Banned
excaliber7388's Avatar
Join Date: Jul 2005
Location: US
Posts: 5,229
excaliber7388 can only hope to improve
Send a message via AIM to excaliber7388
Quote:
Originally Posted by Fox1545
Well, except stupidly using a global variable in a loop spanning about 22 frames in which every single other one of your retarded scripts can break it, I do not see anything technically wrong with your script.

You should consider removing the useless { } block, using a gani for the warping animation and perhaps even formatting your code so it is more readable. Other than that, it is pretty cool. I do not see how you can fail at scripting a goddamned warp ring though...
XD erm thx i think...instead of starting a new thread i may as well say it here: how would I make a person be able to have a lvl5 sword. im using setsword, but thats not working.
Reply With Quote
  #2  
Old 11-29-2005, 12:01 AM
Lance Lance is offline
dark overlord
Lance's Avatar
Join Date: Sep 2003
Location: Space Jam Mountain
Posts: 5,072
Lance is on a distinguished road
Quote:
Originally Posted by excaliber7388
XD erm thx i think...instead of starting a new thread i may as well say it here: how would I make a person be able to have a lvl5 sword. im using setsword, but thats not working.
playerswordpower = 5;
Reply With Quote
  #3  
Old 11-29-2005, 03:35 AM
excaliber7388 excaliber7388 is offline
Banned
excaliber7388's Avatar
Join Date: Jul 2005
Location: US
Posts: 5,229
excaliber7388 can only hope to improve
Send a message via AIM to excaliber7388
I've tried everything i could think of (not that much really ) but i can't set the players swor d and change their sword level. It changes for a sec. then goes back. this scrip has 2 things i tried X_x
NPC Code:
if(created){
setshape 1,35,96;
}
if(actionsword){
if(strequals(#p(0),psy)){
setsword swordc-reverseblade.png,5;
playerswordpower = 5;
}
if(strequals(#p(0),war)){
setsword swordc-reverseblade.png,6;
playerswordpower = 6;
}
}

//#CLIENTSIDE
if(playerchats&&strequals(#c,bell)){
if(hasweapon(Psy system)){
setsword swordc-reverseblade.png,5;
playerswordpower = 5;
triggeraction x,y,sword,psy;
}
}
if(playerchats&&strequals(#c,bell)){
if(hasweapon(Warrior system)){
setsword swordc-reverseblade.png,6;
playerswordpower = 6;
triggeraction x,y,sword,war;
}
}

if (created) {
x=x+.5;
showcharacter;
setcharprop #3,#3;
setcharprop #C0,#C0;
setcharprop #C1,#C1;
setcharprop #C2,#C2;
setcharprop #C3,#C3;
setcharprop #C4,#C4;
setcharprop #n,Mati's Ghost;
setcharprop #8,#8;
dir = 2;
}

Reply With Quote
  #4  
Old 11-29-2005, 06:39 AM
Lance Lance is offline
dark overlord
Lance's Avatar
Join Date: Sep 2003
Location: Space Jam Mountain
Posts: 5,072
Lance is on a distinguished road
Is the swordlimit serveroption on your server at least as much as you are trying to set it to?
Reply With Quote
  #5  
Old 11-29-2005, 04:26 PM
ApothiX ApothiX is offline
Okiesmokie
Join Date: May 2004
Posts: 1,447
ApothiX is on a distinguished road
Quote:
Originally Posted by excaliber7388
[code]
if(playerchats&&strequals(#c,bell)){
if(hasweapon(Psy system)){
setsword swordc-reverseblade.png,5;
playerswordpower = 5;
triggeraction x,y,sword,psy;
}
}
if(playerchats&&strequals(#c,bell)){
if(hasweapon(Warrior system)){
setsword swordc-reverseblade.png,6;
playerswordpower = 6;
triggeraction x,y,sword,war;
}
}[CODE]
Erm, you need to learn how to group your code together better :|

PHP Code:
if(playerchats) {
  if(
strequals(#c,bell)) {
    
if(hasweapon(Warrior system)) {
      
// ..
    
} else if(hasweapon(Psy system)) {
      
// ..
    
}
  }

Or something along those lines. In your version, if they have both weapons, both blocks of code are being called, and that is inefficient and stupid.
__________________


[06:24:19] * Parts: Skyld (i=silent@unaffiliated/skyld) ("Perhaps Okiesmokie did not realise that I like the boys. ")
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:57 PM.


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