RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

Simple Player Dueling.

Alex21

Sorceror
Simple Player Dueling.

This System Has Been Through About 3 Completely Different Versions, So Many Of The Post's In This Thread Are Not Valid.

Simple Player Dueling :)

Description:
This system allows players to organize highly customizable duels with out admin assistance, these duels can have up to 4 teams with a maximum of 6 players per team. Using a easy to use gump interface the player can quickly and easily set up very specific duel rules which will affect what players can and can't do in the duel. "Buy In's" can also be set which allow players to effectively "duel for cash".

How It Works:
Basically this is what a player will do when they organize a duel:

1) Say in game "i wish to duel" and receive the gump interface
2) Set up duel teams, participants, buy in and of course extensive rules
3) Once finished customizing the duel the player then uses the interface to attempt to start the duel
4) A gump allowing a player to view the duel rules and either accept/decline them, will be sent to all players
5) If all players accept the rules the duel will begin counting to a set count before attempting to start
6) If there is an arena available and all players are in correct condition's the duel will start
7) All players will be moved to the available arena and will be frozen for a short period
8) Players will begin to fight limited by the duel rules
9) After all players/all except of one team are dead the duel will end hopefully resulting in a winning team

Installation:
1) Place the dueling folder into your scripts folder

2) In Misc/Notoriety.cs Make the following modification

At the top under the line, or similar

Code:
using Server.Factions;

Place the line

Code:
using Server.Dueling;

3) In Misc/Notoriety.cs Make the following modification

Find and copy the method

Code:
public static int MobileNotoriety( Mobile source, Mobile target )

Then paste it beneath itself renaming it MobileNotoriety2

4) In Misc/Notoriety.cs Make the following modification

In the method

Code:
public static int MobileNotoriety( Mobile source, Mobile target )

At the very top add this code

Code:
if (source is PlayerMobile && target is PlayerMobile)
            {
                if (Duel_Config.InADuel((PlayerMobile)source) && Duel_Config.InADuel((PlayerMobile)target))
                    return DuelController.NotoHandler(source, target);
            }

6) In Dueling/Base/DuelConfig.cs

Find and edit as you wish this section

Code:
// Suggested User Configured Variables
        public static bool Enabled = true;
        public static bool AllowSameIPDuels = true;
        public static int DuelStartDelay = 10;
        public static bool AllowFactionersToDuel = false;
        //End of Suggested User Configured Variables

Setting Up A Duel Arena/Region:
1) Add a DuelController in game next to where you wish the region to be
2) Use the command [props to configure the DuelController to create the region
3) Restart the server and as configured the DuelController will create the region

Screen Shots:
[URL=http://img25.imageshack.us/my.php?image=41310779.jpg] [/URL]











Hope you enjoy.
 

Attachments

  • Dueling.rar
    32.2 KB · Views: 589
  • Notoriety.cs
    16.8 KB · Views: 375

Alex21

Sorceror
This system mis not complete, and due for an update at current.

* Missing duel ranking system
* In duel weapon rules do not work.
 

ClanCC

Wanderer
hm. RunUO SVN, Linux, Mono SVN

Code:
Errors:
 + Customs/Dueling/Gumps/DuelGump.cs:
    CS0135: Line 152: `duel' conflicts with a declaration in a child block
Scripts: One or more scripts failed to compile or no script files were found.
 - Press return to exit, or R to try again.
Error:
System.NullReferenceException: Object reference not set to an instance of an object
  at System.TermInfoDriver.ReadKeyInternal (System.Boolean& fresh) [0x00000]
  at System.TermInfoDriver.ReadKey (Boolean intercept) [0x00000]
  at System.ConsoleDriver.ReadKey (Boolean intercept) [0x00000]
  at System.Console.ReadKey (Boolean intercept) [0x00000]
  at Server.Core.Main (System.String[] args) [0x00000]
This exception is fatal, press return to exit
;1R
** (/RunUO/RunUO.exe:29376): WARNING **: exception inside UnhandledException handler: Object reference not set to an instance of an object
 
that means that "duel" is being declared twice at the same or lower level

one section needs to be changed to like "duel1" through that section
 

krump_king

Sorceror
help

when i try to download the file it does not show me a script can u maybe pm me a list of the steps to setting up the arenas etc would be great
 

Johabius

Knight
krump_king;729841 said:
when i try to download the file it does not show me a script can u maybe pm me a list of the steps to setting up the arenas etc would be great
You will need to unpack the rar file using winrar. The script/scripts are contained within the rar file.
 
Top