Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Sessumaru

Members
  • Posts

    4
  • Joined

  • Last visited

    Never

Sessumaru's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. Just…. Quote... it makes a funkeh shape
  2. The /away command doesn't work on my server. I have looked through the main to try to see why, yet nothing appears to be wrong. Is there anything i have to change if i installed the server to a custom directory (thats the only thing i can think of.) I am running EE, any ideas?
  3. Vortex Online is looking for several mappers to help expand the world. Vortex is a Medieval Fantasy RPG Automated Events CTF PK System 2 Very Unique Class Trees Many new scripts and quests will be added within the next few weeks. Factions will be added as soon as the Town Maps are completed. Some Screenies of the Fighter Class Change Quest: ![](http://i286.photobucket.com/albums/ll97/Sessumaru999/KrusadeScreenyPyramid1.jpg) ![](http://i286.photobucket.com/albums/ll97/Sessumaru999/KrusadeScreenyPyramidEntrance.jpg) They aren't great i know, but mapping is certainly not my forte. E-mail [email protected] to apply. Please either post an example here, or send it in the email.
  4. ``` ':: Text Color Code :: 'Black = 0 'Blue = 1 'Green = 2 'Cyan = 3 'Red = 4 'Magenta = 5 'Brown = 6 'Grey = 7 'DarkGrey = 8 'BrightBlue = 9 'BrightGreen = 10 'BrightCyan = 11 'BrightRed = 12 'Pink = 13 'Yellow = 14 'White = 15 ':: Mini Scripting Explanation :: 'Writing with ' before it are comments and do not do anything. 'Subs are mini packages of code that run as a group from top to bottom 'You can run subs by calling them. ie call onattack(index) and index would be a player number. 'Dims are boxes for storing data in. You say dim MYSTUFF, then MYSTUFF = "thisword", and you could use MYSTUFF where ever you needed the text "thisword" 'Different commands have different pieces of info you must give to them. See the scripting forum for more help. '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs whenever a new character is created. ' Warning: This is intended for creating new values, etc. only. ' The player is NOT logged into the game when this runs, so commands ' such as PlayerMsg will NOT work Sub OnNewChar(index, charNum) Dim CharName CharName = GetPlayerName(index) If Len(CharName) >= 12 Then Call SetPlayerName(index, left(CharName, 12)) End If End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub is used to run timed events based off the server time. Sub TimedEvent(Hours,Minutes,Seconds) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' If minutes are zero then If minutes = 0 Then ' If seconds are also zero then If seconds = 0 Then ' Tell the admins to come check out the forums Call adminmsg("Dear admins: Dont forget to vote for Krusade Online. We need your support and fresh interest via the vote sites to keep the engine alive and updates continuing...", 14) End If End If End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs every time the player hits the ctrl key and attacks. Sub OnAttack(index) x = GetPlayerX(index) y = GetPlayerY(index) m = GetPlayerMap(index) Select Case GetPlayerDir(index) Case 0 y = y - 1 Case 1 y = y + 1 Case 2 x = x - 1 Case 3 x = x + 1 End Select If GetVar("OneTimeVars.ini", Cstr(m), Cstr(x) & "_" & Cstr(y)) = "1" Then Call CheckChestStackable(index, x, y) End If If GetVar("OneTimeVars.ini", Cstr(m), Cstr(x) & "_" & Cstr(y)) = "0" Then Call CheckChestNonStackable(index, x, y) End If If GetVar("OneTimeVars.ini", Cstr(m), Cstr(x) & "_" & Cstr(y)) = "2" Then Call CheckChestEquipment(index, x, y) End If z = 1 Do While z < 16 If GetNPCX(m, z) = x Then If GetNPCY(m, z) = y Then If GetMapNpcHP(m, z) > 0 and GetMapNpcHP(m, z) 32767 Then Call SpellAnim(4, m, x, y) Exit Sub End If End If End If z = z + 1 Loop Call CastCheck(index) End Sub 'This subs checks all conditions for fishing. 'After checking, it feeds the needed data to the catching sub. Sub CastCheck(index) 'Get the x and y coordinates of the tile that the player is facing. x = GetPlayerX(index) y = GetPlayerY(index) Select Case GetPlayerDir(index) Case 0 y = y - 1 Case 1 y = y + 1 Case 2 x = x - 1 Case 3 x = x + 1 End Select 'If the player isn't facing a fishable tile, there's no 'need to continue checking. Exit the sub. If GetVar("scripts\fishing\tiles.ini", CStr(GetPlayerMap(index)) & "_" & CStr(x) & "_" & CStr(y), "Fishable") = "" Then Exit Sub End If 'If the player doesn't have a weapon equipped, they can't possibly 'be holding their rod. Exit the sub. If GetPlayerWeaponSlot(index) = 0 Then Call PlayerMsg(index, "You need to equip a rod!", 4) Exit Sub End If 'If the player doesn't have a bait selected, exit the sub. If GetVar("scripts\fishing\players.ini", GetPlayerName(index), "Bait") = "" Then Call PlayerMsg(index, "You need to select a bait!", 4) Exit Sub Else Bait = GetVar("scripts\fishing\players.ini", GetPlayerName(index), "Bait") End If 'Since they do have a weapon, we check to see if it's a rod. 'Multiple rods are usable. Maxrods = CLng(GetVar("scripts\fishing\Rods.ini", "Constants", "MaxRods")) rod = 1 Do While rod 0 LevelReq = CLng(GetVar("scripts\fishing\fish.ini", GetVar("scripts\fishing\tiles.ini", CStr(GetPlayerMap(index)) & "_" & CStr(x) & "_" & CStr(y), "Fish" & CStr(Temp) & "Num"), "LevelReq")) If LevelReq > level Then Maxfish = Maxfish - 1 Else Exit Do End If Temp = Temp - 1 Loop Fish = Rand(1, Maxfish) BaseRoll = Rand(1, 80) Call PutVar("scripts\fishing\players.ini", GetPlayerName(index), "CurrentFish", CStr(Fish)) Call PutVar("scripts\fishing\players.ini", GetPlayerName(index), "CurrentChance", CStr(BaseRoll)) End If BaseRoll = CLng(GetVar("scripts\fishing\players.ini", GetPlayerName(index), "CurrentChance")) Fish = CLng(GetVar("scripts\fishing\players.ini", GetPlayerName(index), "CurrentFish")) FishNum = CLng(GetVar("scripts\fishing\tiles.ini", CStr(GetPlayerMap(index)) & "_" & CStr(x) & "_" & CStr(y), "Fish" & CStr(Fish) & "Num")) 'Chance variables and equation LevelBonus = (level - CLng(GetVar("scripts\fishing\fish.ini", CStr(Fish), "LevelReq"))) * 5 RodBonus = CLng(GetVar("scripts\fishing\rods.ini", GetVar("scripts\fishing\players.ini", GetPlayerName(index), "Rod"), "Bonus")) Chance = Int((Baseroll - LevelBonus - RodBonus) / (check / 20)) TargetChance = CLng(GetVar("scripts\fishing\tiles.ini", CStr(GetPlayerMap(index)) & "_" & CStr(x) & "_" & CStr(y), "Fish" & CStr(Fish) & "Chance")) If Chance CLng(GetVar("scripts\fishing\experience.ini", "experience", Level)) Then Call PutVar("scripts\fishing\players.ini", GetPlayerName(index), "level", Level + 1) Call PutVar("scripts\fishing\players.ini", GetPlayerName(index), "Exp", Exp - CLng(GetVar("scripts\fishing\experience.ini", "experience", Level))) End If Call RemoveTimer("CatchCheck " & index & "," & x & "," & y & "," & bait) Exit Sub End If If check = 20 Then Call RemoveTimer("CatchCheck " & index & "," & x & "," & y & "," & bait) Call PlayerMsg(index, "...But the fish aren't biting.", 15) Exit Sub End If check = check + 1 Call PutVar("scripts\fishing\players.ini", GetPlayerName(index), "check", check) End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs when any player presses the PageUp key Sub HotScript1(index) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 'Call SetPlayerSPeed(index, 10) End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs when any player presses the Delete key Sub HotScript2(index) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Dim diceroll 'Rolling dice script 'diceroll becomes a Random number between 1 and 6 'diceroll=Rand(6,1) 'Call Mapmsg(GetPlayerMap(index), GetPlayerName(index) & " rolls a " & 'Int(diceroll) & " (1-6)", 15) 'Call CustomMenuShow(index, "custom", "\GUI\CUSTOM\test.bmp", 0) 'Call CustomMenuClose(index) End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs when players press the End key Sub HotScript3(index) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' Telling players the game time Call playermsg(index, "The time is " & getservertimehour() & ":" & getservertimeminute() & ":" & getservertimesecond() , 14) End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs when players press the PageDown key Sub HotScript4(index) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' Example of finding an empty inventory slot and giving the player 1 of item 1 : 'If giveplayeritem(index, 1, 1, 0) = 1 Then 'Call playermsg(index,"You magically have one more gold piece.", 10) 'Else 'Call playermsg(index,"Your bag feels too heavy for more gold.", 12) 'End If ' Examples of using text bubbles : 'Call textbubble(index, 1, "These Are",GetPlayerMap(index), 4, 4, 10) 'Call textbubble(index, 2, "All Scripted",GetPlayerMap(index), 6, 6, 10) 'Call textbubble(index, 3, "Text Bubbles",GetPlayerMap(index), 8, 8, 10) 'Call textbubble(index, 4, "Only This",GetPlayerMap(index), 10, 10, 10) 'Call textbubble(index, 5, "Player Sees!",GetPlayerMap(index), 12, 12, 10) 'Call maptextbubble(20, "All players would see this one though.",GetPlayerMap(index), 4, 10, 14) 'Call textbubble(index, 6, "It does have limits in size, three lines is max.",GetPlayerMap(index), 2, 12, 12) ' Example of making a shop run : 'Call goshopping(index,1) ' Example of changing the players guild : 'Call setplayerguildname(index,"Bobzor!") 'Call setplayerguildaccess(index, 1) 'Call sendplayerdata(index) ' Example of changing the spawn type of a map to spawn an NPC, useful for bosses : 'Call ScriptSpawnNpc(15,GetPlayerMap(index),GetPlayerX(index), GetPlayerY(index),1) ' Example of spawning an item on a map just as though it had been dropped : 'Call Spawnitemonmap(GetPlayerMap(index),GetPlayerX(index), GetPlayerY(index),1,15,0) ' Example of locking a player so they cant move : 'Call lockplayer(index,1) ' Example of showing or hiding paperdoll: 'Call HidePlayerPaperdoll(index) 'Call ShowPlayerPaperdoll(index) ' Example of setting player pet: 'Call SetPlayerPet(index, 1) End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs when something on a custom menu is clicked. Sub MenuScripts(index, Clicked_Index, Menu_Type) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Dim field_message Dim menu_title menu_title = getplayermenuclicktitle(index) field_message = getplayermenuclickmsg(index) ' Figure out what type of button was clicked ie picture, textbox, label. Select Case Menu_Type Case 1 ' PICTURE WAS CLICKED ' Player has clicked a picture box whos number is clicked_index on the custom menu named menu_title Call playermsg(index, "Clicked picture number " & clicked_index & " on the menu named " & menu_title, 14) Case 2 ' FIELD WAS CLICKED ' Player has clicked a text field OK button whos number is clicked_index on the custom menu named menu_title. Call playermsg(index, "Clicked field number " & clicked_index & " on the menu named " & menu_title & ". The field text was " & field_message, 14) Case 3 ' LABEL WAS CLICKED ' Player has clicked a label button whos number is clicked_index on the custom menu named menu_title Call playermsg(index, "Clicked label number " & clicked_index & " on the menu named " & menu_title, 14) End Select End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs when a player logs into the game. Sub JoinGame(index) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ On Error Resume next Dim GameName Dim MOTD Dim firstjoin ' Load the gamename from the data.ini file into the variable named GameName GameName = Trim(GetVar("Data.ini", "CONFIG", "GameName")) ' Load the message of the day from the motd.ini file into the variable named MOTD MOTD = GetVar("motd.ini", "MOTD", "Msg") ' Send a global message that he/she joined If GetPlayerAccess(index) 0 and getbootx(index) = 0 and getbooty(index) = 0 Then ' If numbers are legitimate, warp the player Call Playerwarp(Index, getbootmap(index), getbootx(Index), getbooty(Index)) End If Else ' Check numbers arent beyond the limits for the map size If getbootmap(index) > 0 and getbootx(index) = 0 and getbooty(index) = 0 Then ' If numbers are legitimate, warp the player Call Playerwarp(Index, getbootmap(index), getbootx(Index), getbooty(Index)) End If End If ' Send a global message that he/she left If GetPlayerAccess(index) GetPlayerNextLevel(index) D = GetPlayerExp(index) - GetPlayerNextLevel(index) Call SetPlayerLevel(index, GetPlayerLevel(index) + 1) I = Int(GetPlayerSpeed(index) / 10) If I < 1 Then I = 1 If I > 3 Then I = 3 Call SetPlayerPoints(index, GetPlayerPoints(index) + I) Call SetPlayerExp(index, D) C = C + 1 Loop ' Optional section currently disabled for broadcasting when players level up. ' If C > 1 Then ' Call GlobalMsg(GetPlayerName(index) & " has gained " & C & " levels!", 6) ' Else ' Call GlobalMsg(GetPlayerName(index) & " has gained a level!", 6) ' End If ' Tells the player how many points they have to distribute Call BattleMsg(index, "You have " & GetPlayerPoints(index) & " stat points.", 9, 0) End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs when a player uses one of the points given on an attribute to level up. Sub UsingStatPoints(index, PointType) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' Decide which point type was clicked and run different things accordingly. Select Case PointType Case 0 ' STRENGTH WAS CLICKED + ' Gives you a set max If GetPlayerSTR(index) + 1 > 1000 Then Call BattleMsg(index, "You have maxed your strength!", 12, 0) Exit Sub End If Call SetPlayerSTR(index, GetPlayerSTR(index) + 1) Call BattleMsg(index, "You have gained more strength!", 15, 0) Case 1 ' DEFENCE WAS CLICKED + ' Gives you a set max If GetPlayerDEF(index) + 1 > 1000 Then Call BattleMsg(index, "You have maxed your defence!", 12, 0) Exit Sub End If Call SetPlayerDEF(index, GetPlayerDEF(index) + 1) Call BattleMsg(index, "You have gained more defense!", 15, 0) Case 2 ' MAGIC WAS CLICKED + ' Gives you a set max If GetPlayerMAGI(index) + 1 > 1000 Then Call BattleMsg(index, "You have maxed your magic!", 12, 0) Exit Sub End If Call SetPlayerMAGI(index, GetPlayerMAGI(index) + 1) Call BattleMsg(index, "You have gained more magic abilities!", 15, 0) Case 3 ' SPEED WAS CLICKED + ' Gives you a set max If GetPlayerSpeed(index) + 1 > 1000 Then Call BattleMsg(index, "You have maxed your speed!", 12, 0) Exit Sub End If Call SetPlayerSPEED(index, GetPlayerSpeed(index) + 1) Call BattleMsg(index, "You have gained more speed!", 15, 0) End Select ' Remove one point after the sub in question is done Call SetPlayerPoints(index, GetPlayerPoints(index) - 1) End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs when a player steps onto a scripted tile Sub ScriptedTile(index, Script) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' Choose what number the tile was to determine the effect to have Select Case Script Case 0 If GetPlayerLevel(index) < 4 Then Call PlayerMsg(index,"You need to be level 4 to enter the subterrane", 7) Else Call PlayerWarp(index, 17, 10, 13) End If Case 1 If GetPlayerLevel(index) < 6 Then Call PlayerMsg(index,"You need to be level 6 to enter the Ezmeral Pass", 7) Else Call PlayerWarp(index, 28, 9, 13) End If Case 2 Call Baron_Uber_skills(index) ' Case 3 Call Baron_Stam_regain(index) Case 4 'class change Dim PlayerLv Dim PlayerClass PlayerLv = GetPlayerLevel(index) PlayerClass = GetPlayerClass(index) If PlayerLv => 10 then If PlayerClass 10 then If PlayerClass =3 Then Call playermsg(index, "Drop Info - num: " & itemnum & " val: " & itemval & " dur: " & itemdur, 14) Call playermsg(index, "Item Index " & item_index & " was dropped from slot " & inv_slot & " onto map " & map, 14) End If End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs each time a player changes map Sub OnMapLoad(index) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Dim map map=GetPlayerMap(index) ' Example of a map script: ' If map = 52 Then ' Call playermsg(index, "You see the goblin shaman eye you warily as you enter his tent", 12) ' End If End Sub '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' This sub runs whenever you kill an NPC. Good for boss kill checkers, 'monster trackers etc Sub onNPCdeath(index, map, NPC_Num, NPC_index) If GetPlayerLevel( Index) > 48 then Call SetPlayerLevel( Index, 1) End if If NPC_num = 16 Then If GetVar("Data\Boss\" & GetPlayerName(index) & ".ini","Quest", "Boss1") = "Dead" Then Exit Sub End if If giveplayeritem(index, 32, 0, 0) = 1 then Call PutVar("Data\Boss\" & GetPlayerName(index) & ".ini", "Quest", "Boss1", "Dead") Call BattleMsg(index, "You killed the Goblin Lord! Now bring his head back to the miner to claim your reward!", 12, 0) Else Call BattleMsg(index, "You don't have enough inventory space to carry the Goblin Lord's head!", 12, 0) Call BattleMsg(index, "Make some room and kill him again!", 12, 0) End If End If If NPC_num = 28 Then If GetVar("Data\Boss\" & GetPlayerName(index) & ".ini","Quest", "Boss2") = "Dead" Then Exit Sub End if If giveplayeritem(index, 66, 0, 0) = 1 then Call PutVar("Data\Boss\" & GetPlayerName(index) & ".ini", "Quest", "Boss2", "Dead") Call BattleMsg(index, "You killed the Skeleton Lord! Now bring his head back to the Gravedigger to claim your reward!", 12, 0) Else Call BattleMsg(index, "You don't have enough inventory space to carry the Skeleton Lord's head!", 12, 0) Call BattleMsg(index, "Make some room and kill him again!", 12, 0) End If End If i = 1 Do While i
×
×
  • Create New...