// mes/input on npcevents - script NPCNAME -1,{ end; OnInit: callfunc "spawn"; end; OnPoringKilled: mes "poring died!"; next; mes "gimme any number"; next; input @temp; end; } function script spawn { monster "geffen",0,0,"Quest Poring",1002,10,"NPCNAME::OnPoringKilled"; return; } geffen.gat,0,0,0,0 monster QuestPoring2 1002,10,0,0,NPCNAME::OnPoringKilled prontera.gat,150,290,1 script testscript 53,1,1,{ set $var,1; if ($var==1) mapannounce "prontera.gat","Hi all",16; if ($var==1) mapannounce "prontera.gat","Hi all2",16; if( $@testscriptname$ != "" ) goto L_BUSY; mes "this test script will set the character name and invoke a timer to check attachrid behaviour"; set $@testscriptname$, strcharinfo(0); mes "name '"+$@testscriptname$+"' stored, adding timer."; addtimer 5000, "testscript::OnTimer5000"; close; L_BUSY: mes "I'm busy waiting for '"+$@testscriptname$+"', please try again later"; close; OnTimer5000: areaannounce "prontera.gat",100,200,250,350,"Uhaaa...",8; if( attachrid( getcharid(3, $@testscriptname$) ) ) goto L_SWOK; set $@testscriptname$, ""; end; L_SWOK: mes "found your char '"+ $@testscriptname$ +"'=='"+ strcharinfo(0) +"'"; set $@testscriptname$, ""; close; OnInit: set $GlobalNumeric, 0x00010001; set @TempNumeric, $GlobalNumeric; set @BitOpTest, @TempNumeric & 0xffff; debugmes $GlobalNumeric; debugmes @TempNumeric; debugmes @BitOpTest; set @TempNumeric, 0x00010001; set @BitOpTest, @TempNumeric & 0xffff; debugmes $GlobalNumeric; debugmes @TempNumeric; debugmes @BitOpTest; debugmes "regex:"; regex "\\s(h[^\\s]*)\\s", "this is a hallo test"; debugmes $p0$; debugmes $p1$; debugmes $p2$; } function script testtext { mes "hallo " + rand(2); Announce "Guild Base [" + GetCastleName(getarg(0)+".gat") + "] has been taken by the [" + GetGuildName(@GID) + "] guild.",0; close; return; } izlude.gat,128,107,4 script test 116,1,1,{ input @message$; mes ""+@message$+"?"; callfunc "testtext","aldeg_cas01","A01",216,24; mes "hallo " + rand(2); mes "hallo " + rand(2); mes "hallo " + rand(2); mes "hallo " + rand(2); mes "hallo " + rand(2); mes "hallo " + rand(2); mes "chaos " + Chaos; mes "karma " + Karma; set karma, karma-10; set chaos, chaos+10; // if(rand(2) == 1 ) callfunc "testtext"; close; OnTouch: npctalk "Ouch !!"; npcwalkto 128-8+rand(4,16),107-8+rand(4,16); break; } morocc.gat,79,112,2 script Dude 797,{ npcspeed 100; if($@Guy1==1) goto L_Stop; initnpctimer; set $@Guy1,1; npcwalkto 161,184; end; L_Stop: set $@Guy1,0; stopnpctimer; setnpctimer 0; npcstop; end; OnTimer5000: npcwalkto 60,100; end; OnTimer10000: setnpctimer 0; npcwalkto 79,112; end; }