Go Back   RunUO - Ultima Online Emulation > RunUO > Server Support on Windows

Server Support on Windows Get (and give) support on general questions related to the RunUO server itself.

Reply
 
Thread Tools Display Modes
Old 07-24-2003, 01:07 AM   #1 (permalink)
 
Join Date: May 2003
Location: Springfield, MO
Posts: 417
Default Password

exists any command to change password in the game?
with no need not to add any script
i use search but not found any
Regressi0n is offline   Reply With Quote
Old 07-24-2003, 01:13 AM   #2 (permalink)
 
Join Date: Apr 2003
Posts: 40
Default

Nope there is not a built-in script to change password in-game. Admins can change it for players, but if you want players to change it themselves you'll have to make a script involving Mobile.Password = new password.
Eldron is offline   Reply With Quote
Old 07-24-2003, 01:16 AM   #3 (permalink)
 
Join Date: May 2003
Location: Springfield, MO
Posts: 417
Default

Quote:
Originally Posted by Eldron
Nope there is not a built-in script to change password in-game. Admins can change it for players, but if you want players to change it themselves you'll have to make a script involving Mobile.Password = new password.
[code:1]
using System;
using Server;
using Server.Misc;
using Server.Accounting;

namespace Server.Scripts.Commands
{
public class NewPasswordCommand
{
public static void Initialize()
{
Server.Commands.Register( "NewPassword", AccessLevel.Player, new CommandEventHandler( ChangePassword_OnCommand ) );
Server.Commands.Register( "NewPass", AccessLevel.Player, new CommandEventHandler( ChangePassword_OnCommand ) );
Server.Commands.Register( "Password", AccessLevel.Player, new CommandEventHandler( ChangePassword_OnCommand ) );
Server.Commands.Register( "PW", AccessLevel.Player, new CommandEventHandler( ChangePassword_OnCommand ) );
}

[Usage( "NewPassword <password>" )]
[Description( "Changes the current account's password." )]
[Aliases( "NewPass, Password, PW" )]
public static void ChangePassword_OnCommand( CommandEventArgs e )
{
if ( e.Length == 0 )
{
e.Mobile.SendMessage( "Format: <new password>" );
e.Mobile.SendMessage( 0x35, "Password must contain only letters of the alphabet. No spaces, quotes or numbers allowed." );
}
if ( e.Length == 1 )
{
Account acct = e.Mobile.Account as Account;

if ( NameVerification.Validate( e.ArgString, 2, 16, true, false, true, 1, NameVerification.SpaceDashPeriodQuote ) )
{
Console.WriteLine( "{0} is changing password to '{1}'", e.Mobile, e.ArgString );
acct.Password = e.ArgString;
e.Mobile.SendMessage( 0x35, "Your password has been changed." );
e.Mobile.SendMessage( "New password: {0}", e.ArgString );
}
else
{
e.Mobile.SendMessage( 0x25, "Password \"{0}\" failed verification. Try again with a different password.", e.ArgString );
}
}
}
}
}
[/code:1]

like this?
Regressi0n is offline   Reply With Quote
Old 07-24-2003, 01:21 AM   #4 (permalink)
 
Join Date: Apr 2003
Posts: 40
Default

Sure that works, someone posted a newer one here:

http://www.runuo.com/discussion/viewtopic.php?t=13775&highlight=password+chang e
Eldron is offline   Reply With Quote
Old 07-24-2003, 01:24 AM   #5 (permalink)
 
Join Date: May 2003
Location: Springfield, MO
Posts: 417
Default

okay , thx
Regressi0n is offline   Reply With Quote
Old 07-24-2003, 01:29 AM   #6 (permalink)
 
Join Date: Apr 2003
Posts: 40
Default

Np, just trying to build up my post count
Eldron is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

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
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 RC5