SlashGeeGee Posted May 28, 2012 Posted May 28, 2012 (edited) Hello rA , i have just learned scripting yesterday so forgive me if my script is a mess . Here's my script : - script Disable -1,{ OnInit: disablenpc "WoE Warper"; end; } prontera,150,150,4 script WoE Warper 100,{ OnMon1900: enablenpc "WoE Warper"; end; OnMon2000: disablenpc "WoE Warper"; end; } warp "prt_gld" ,132,64; end; } is it possible to add one more OnInit like this : OnInit: waitingroom "WoE: Kriemhild ^FF0000[ ON ]^00FF00",0; end; } Thanks For Helping SlashGeeGee Edited May 28, 2012 by SlashGeeGee Quote
F0xxy Posted May 28, 2012 Posted May 28, 2012 - script Disable -1,{ OnInit: disablenpc "WoE Warper"; end; } prontera,150,150,4 script WoE Warper 100,{ OnInit: waitingroom "WoE: Kriemhild [ ON ]",0; end; OnMon1900: enablenpc "WoE Warper"; end; OnMon2000: disablenpc "WoE Warper"; end; } warp "prt_gld" ,132,64; end; } Quote
SlashGeeGee Posted May 28, 2012 Author Posted May 28, 2012 - script Disable -1,{ OnInit: disablenpc "WoE Warper"; end; } prontera,150,150,4 script WoE Warper 100,{ OnInit: waitingroom "WoE: Kriemhild [ ON ]",0; end; OnMon1900: enablenpc "WoE Warper"; end; OnMon2000: disablenpc "WoE Warper"; end; } warp "prt_gld" ,132,64; end; } it doesn't work. even if i re-arranged it here: - script Disable -1,{ OnInit: disablenpc "WoE Warper"; end; } prontera,156,166,4 script WoE Warper 483,{ OnMon2230: enablenpc "WoE Warper"; end; OnMon2300: disablenpc "WoE Warper"; end; } warp "prt_gld",135,64; end; OnInit: waitingroom "WoE: Kriemhild ^FF0000[ ON ]^00FF00",0; end; } still not working Quote
Rikimaru Posted May 28, 2012 Posted May 28, 2012 Did you add the tabs? Normally it should work. Quote
SlashGeeGee Posted May 28, 2012 Author Posted May 28, 2012 Did you add the tabs? Normally it should work. yeah i tabbed them all already the error is on this code : warp "prt_gld",135,64; Quote
Magnetix Posted May 28, 2012 Posted May 28, 2012 (edited) I'm not a script expert but I can tell it's wrong. Try this, haven't really tested it tho. - script Disable -1,{ end; OnInit: disablenpc "WoE Warper"; end; OnMon1900: enablenpc "WoE Warper"; waitingroom "WoE: Kriemhild ^FF0000[ ON ]^00FF00",0; end; OnMon2000: delwaitingroom; disablenpc "WoE Warper"; end; } prontera,150,150,4 script WoE Warper 100,{ warp "prt_gld",132,64; end; } Edited May 28, 2012 by Magnetix Quote
F0xxy Posted May 28, 2012 Posted May 28, 2012 - script Disable -1,{ OnInit: disablenpc "WoE Warper"; end; } prontera,156,166,4 script WoE Warper 483,{ OnMon2230: enablenpc "WoE Warper"; end; OnMon2300: disablenpc "WoE Warper"; end; //} <--- you're ending the script right here hence why it's erroring warp "prt_gld",135,64; end; OnInit: waitingroom "WoE: Kriemhild ^FF0000[ ON ]^00FF00",0; end; } And that as they say, is that Quote
Magnetix Posted May 28, 2012 Posted May 28, 2012 (edited) - script Disable -1,{ OnInit: disablenpc "WoE Warper"; end; } prontera,156,166,4 script WoE Warper 483,{ OnMon2230: enablenpc "WoE Warper"; end; OnMon2300: disablenpc "WoE Warper"; end; //} <--- you're ending the script right here hence why it's erroring warp "prt_gld",135,64; end; OnInit: waitingroom "WoE: Kriemhild ^FF0000[ ON ]^00FF00",0; end; } And that as they say, is that how can you show the waiting room IF the npc is disabled during initialization? see the script I posted above, I don't know if it'll run and imo that's how your algoritm should be and it contains the fix for the warp syntax error. Edited May 28, 2012 by Magnetix Quote
SlashGeeGee Posted May 28, 2012 Author Posted May 28, 2012 @Magnetix your script works fine men thanks only problem is the waitingroom will only execute when a player click's the npc. @Jam yeah that's it . Quote
Magnetix Posted May 28, 2012 Posted May 28, 2012 I already corrected that SlashGeeGee. See the script I posted above. Quote
F0xxy Posted May 28, 2012 Posted May 28, 2012 (edited) - script Disable -1,{ OnInit: disablenpc "WoE Warper"; end; } prontera,156,166,4 script WoE Warper 483,{ OnMon2230: enablenpc "WoE Warper"; end; OnMon2300: disablenpc "WoE Warper"; end; //} <--- you're ending the script right here hence why it's erroring warp "prt_gld",135,64; end; OnInit: waitingroom "WoE: Kriemhild ^FF0000[ ON ]^00FF00",0; end; } And that as they say, is that how can you show the waiting room IF the npc is disabled during initialization? see the script I posted above, I don't know if it'll run and imo that's how your algoritm should be and it contains the fix for the warp syntax error. I didn't meantion anything regarding the waiting room lol I merely stated the cause of the error in the script he changed. - script Disable -1,{ end; OnInit: disablenpc "WoE Warper"; end; OnMon1900: enablenpc "WoE Warper"; end; OnMon2000: disablenpc "WoE Warper"; end; } prontera,150,150,4 script WoE Warper 100,{ goto L_warp; OnInit: waitingroom "WoE: Kriemhild ^FF0000[ ON ]^00FF00",0; end; L_warp: warp "prt_gld",132,64; end; } there... and Magnetix, you're setting the waiting room in the wrong script. Edited May 28, 2012 by F0xxy Quote
Magnetix Posted May 28, 2012 Posted May 28, 2012 I apologize but that wasn't meant for you F0xxy. My post was a continuation of your explanation that's why I quoted your post. Quote
F0xxy Posted May 28, 2012 Posted May 28, 2012 Like he said, he started scripting very recently...even though other people indeed provided a re-written working script it's good that he understands where the problems were at. No biggie mate Quote
Question
SlashGeeGee
Hello rA , i have just learned scripting yesterday so forgive me if my script is a mess .
Here's my script :
is it possible to add one more OnInit like this :
Thanks For Helping
SlashGeeGee
Edited by SlashGeeGee14 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.