Graal Forums  

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

Closed Thread
 
Thread Tools Search this Thread Display Modes
  #1  
Old 07-10-2003, 02:02 AM
Shroomed Shroomed is offline
Gone..
Shroomed's Avatar
Join Date: Jun 2003
Location: middleton, MA
Posts: 111
Shroomed is on a distinguished road
Send a message via ICQ to Shroomed Send a message via AIM to Shroomed
My servers leveling system

Can you tell me whats wrong with this level up system for my new server?

// NPC made by nervNAT
if (playerenters) {
if (!hasweapon(*System)) {
toweapons *System;
setstring client.maxmp,#v(int(strtofloat(#s(client.level))*1 .5));
setstring client.maxhp,#v(int(strtofloat(#s(client.level))*1 .8));
setstring client.hp,#s(client.maxhp);
setstring client.mp,#s(client.maxmp);
setstring client.maxexp,1000000;
setstring client.level,1;
}
this.baddiecount=compuscount;
timeout=.05;
}
if (timeout) {
if (playerhearts<playerfullhearts) setstring client.hp,#v(strtofloat(#s(client.hp))-1);
setstring client.exptonext,#v(strtofloat(#s(client.level))*5 );
baddycheck();
playerhearts=playerfullhearts;
if (strtofloat(#s(client.hp))>strtofloat(#s(client.ma xhp))) setstring client.hp,#s(client.maxhp);
if (strtofloat(#s(client.mp))>strtofloat(#s(client.ma xmp))) setstring client.mp,#s(client.maxmp);
exp();
if (strtofloat(#s(client.hp))<=0) dead();
showimg 0,@HP:#s(client.hp)/#s(client.maxhp),570,10;
changeimgvis 0,4;
showimg 1,@MP:#s(client.mp)/#s(client.maxmp),570,25;
changeimgvis 1,4;
showimg 2,@EXP:#s(client.exp)/#s(client.exptonext),570,40;
changeimgvis 2,4;
showimg 3,@Level:#s(client.level),570,55;
changeimgvis 3,4;
timeout=.05;
}
function baddycheck() {
for (this.i=0;this.i<compuscount;this.i++) {
if (compus[this.i].mode==3) {
if (compus[this.i].type==0) this.exp=1;
if (compus[this.i].type==1) this.exp=2;
if (compus[this.i].type==2) this.exp=3;
if (compus[this.i].type==3) this.exp=3;
if (compus[this.i].type==4) this.exp=3;
if (compus[this.i].type==5) this.exp=1;
if (compus[this.i].type==6) this.exp=1;
if (compus[this.i].type==7) this.exp=4;
if (compus[this.i].type==8) this.exp=5;
if (compus[this.i].type==9) this.exp=6;
}}
if (this.baddiecount!=compuscount) {
setstring client.exp,#v(strtofloat(#s(client.exp))+this.exp) ;
this.baddiecount=compuscount;
}}
function dead() {
freezeplayer 3;
setani dead,dead;
setstring client.hp,#s(client.maxhp);
setstring client.deaths,#v(strtofloat(#s(client.deaths))+1);
}
function exp() {
setstring client.maxmp,#v(int(strtofloat(#s(client.level))*1 .5));
setstring client.maxhp,#v(int(strtofloat(#s(client.level))*1 .8));
if (strtofloat(#s(client.exp))>strtofloat(#s(client.m axexp))) setstring client.exp,#s(client.maxexp);
if (strtofloat(#s(client.exp))>=strtofloat(#s(client. exptonext))) {
setstring client.level,#v(strtofloat(#s(client.level))+1);
setstring client.exp,#v(strtofloat(#s(client.exp))-strtofloat(#s(client.exptonext)));
setstring client.hp,#s(client.maxhp);
setstring client.mp,#s(client.maxmp);
setplayerprop #c,Level Up!;
}
}


BTW i didnt make this another staf on my server did...he just dont have gold days left on his acc
__________________
Gone......
  #2  
Old 07-10-2003, 02:56 AM
Python523 Python523 is offline
Banned
Join Date: Aug 2001
Location: Illinois
Posts: 3,498
Python523 is on a distinguished road
why dont YOU tell US what is wrong
  #3  
Old 07-10-2003, 03:37 AM
Shroomed Shroomed is offline
Gone..
Shroomed's Avatar
Join Date: Jun 2003
Location: middleton, MA
Posts: 111
Shroomed is on a distinguished road
Send a message via ICQ to Shroomed Send a message via AIM to Shroomed
Alas, I cannot I am just a simple LAT......I can make simple scripts but this is just outta my ball park...alright there junior?
__________________
Gone......
  #4  
Old 07-10-2003, 04:26 AM
protagonist protagonist is offline
Banned
protagonist's Avatar
Join Date: May 2003
Location: CAW
Posts: 5,586
protagonist is on a distinguished road
Send a message via AIM to protagonist Send a message via MSN to protagonist
That is very hard to read.
  #5  
Old 07-10-2003, 04:38 AM
Python523 Python523 is offline
Banned
Join Date: Aug 2001
Location: Illinois
Posts: 3,498
Python523 is on a distinguished road
Quote:
Originally posted by Shroomed
Alas, I cannot I am just a simple LAT......I can make simple scripts but this is just outta my ball park...alright there junior?
I meant what part doesnt work
  #6  
Old 07-10-2003, 06:27 AM
adam adam is offline
http://wiki.graal.us/
adam's Avatar
Join Date: Nov 2001
Posts: 2,247
adam has a spectacular aura aboutadam has a spectacular aura about
Send a message via AIM to adam
Quote:
Originally posted by Shroomed
Alas, I cannot I am just a simple LAT......I can make simple scripts but this is just outta my ball park...alright there junior?
Then ask the guy who made it for you.
__________________
Rogue Shadow (TCN)(NAT)(Global Development Team)

For development help, contact the patrons of the #graaldt irc channel below, I am usually there.
Click Here to Join IRC Chat Now! -- irc.freenode.net Channel: #graaldt
Quote:
<Dustyshouri> no, RogueShadow is always talking about scripts lol
<Dustyshouri> in fact, he pretty much brought Graal back as a topic single-handedly
  #7  
Old 07-10-2003, 07:09 AM
Shroomed Shroomed is offline
Gone..
Shroomed's Avatar
Join Date: Jun 2003
Location: middleton, MA
Posts: 111
Shroomed is on a distinguished road
Send a message via ICQ to Shroomed Send a message via AIM to Shroomed
nonononono

He told me as soon as you preview the level you start leveling up....He gave it to me not knowing I had no effing idea what to do with it...So I brought it to the pro's. (Hopefully)
__________________
Gone......
  #8  
Old 07-10-2003, 07:47 AM
Projectshifter Projectshifter is offline
The David
Projectshifter's Avatar
Join Date: Apr 2002
Location: USA
Posts: 912
Projectshifter is an unknown quantity at this point
Send a message via ICQ to Projectshifter Send a message via AIM to Projectshifter Send a message via MSN to Projectshifter Send a message via Yahoo to Projectshifter
Maybe you should take the advice of your sig?
Honestly, we're not going to interpret someone else's script for you.
It is not designed for an NPC Server anyway, so it's stupid >.< Toweapons is like... nonexistant anymore =/ He he... offline and Classic
Dude, go ask the guy who made it, we're not going to just go and spend 5 minutes on this hard to read script, and then try and figure it out... that's not what we're here to do. By the "pros" you should realize this means we would help YOU fix something... assuming you even knew what was wrong...
---Shifter
__________________
Who has time for life these days?
  #9  
Old 07-10-2003, 08:12 AM
wonderboysp2p wonderboysp2p is offline
Registered User
wonderboysp2p's Avatar
Join Date: Sep 2002
Location: -Wonderboy
Posts: 537
wonderboysp2p is on a distinguished road
Send a message via AIM to wonderboysp2p
is that a pic of you? your ears look magnetic and id be scared they'd stick to my teeth if i were you...

anyways that script is very poorly written and i dislike it very much and plz dont post a full script and say 'FIX IT'

if you have a prob ay what's not workin post the part that's not working and it might be helped
__________________

we are the llama FORUms!!!EWQ Ce13d5423f23!! 2e1 @$6tgv3uy65!
  #10  
Old 07-10-2003, 08:21 AM
Kaimetsu Kaimetsu is offline
Script Monkey
Kaimetsu's Avatar
Join Date: May 2001
Posts: 18,222
Kaimetsu will become famous soon enough
The End.
__________________
Closed Thread


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 07:52 AM.


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