You can add it anywhere really, I just placed it after the last line but before the }'s in the script.Darkness_PR said:Yeah im having a little problem setting LogInStats.cs adding
MailBox mailbox = m.BankBox.FindItemByType( typeof( MailBox ) ) as MailBox;
if ( mailbox != null )
{
if ( mailbox.NewMail == "true" )
m.SendGump( new NewMailGump( m, mailbox ) );
}
cant seem to fidn where to add it into the script
- Error: Scripts\Misc\LoginStats.cs: CS0246: (line 21, column 22) The type or n
amespace name 'm' could not be found (are you missing a using directive or an as
sembly reference?)
- Error: Scripts\Misc\LoginStats.cs: CS0029: (line 24, column 9) Cannot implici
tly convert type 'string' to 'bool'
- Error: Scripts\Misc\LoginStats.cs: CS0246: (line 25, column 34) The type or n
amespace name 'm' could not be found (are you missing a using directive or an as
sembly reference?)
- Error: Scripts\Misc\LoginStats.cs: CS0246: (line 25, column 5) The type or na
mespace name 'm' could not be found (are you missing a using directive or an ass
embly reference?)
show me your LoginStats.cs: script if you show it i can help you outDarkness_PR said:you might think im kinda stupid but i have ebing playing with this script and allwas get the same error dunno why.....the error is this
please help me!Code:- Error: Scripts\Misc\LoginStats.cs: CS0246: (line 21, column 22) The type or n amespace name 'm' could not be found (are you missing a using directive or an as sembly reference?) - Error: Scripts\Misc\LoginStats.cs: CS0029: (line 24, column 9) Cannot implici tly convert type 'string' to 'bool' - Error: Scripts\Misc\LoginStats.cs: CS0246: (line 25, column 34) The type or n amespace name 'm' could not be found (are you missing a using directive or an as sembly reference?) - Error: Scripts\Misc\LoginStats.cs: CS0246: (line 25, column 5) The type or na mespace name 'm' could not be found (are you missing a using directive or an ass embly reference?)
Please post your LoginStats.cs and I will see what is wrong with it.Darkness_PR said:you might think im kinda stupid but i have ebing playing with this script and allwas get the same error dunno why.....the error is this
please help me!Code:- Error: Scripts\Misc\LoginStats.cs: CS0246: (line 21, column 22) The type or n amespace name 'm' could not be found (are you missing a using directive or an as sembly reference?) - Error: Scripts\Misc\LoginStats.cs: CS0029: (line 24, column 9) Cannot implici tly convert type 'string' to 'bool' - Error: Scripts\Misc\LoginStats.cs: CS0246: (line 25, column 34) The type or n amespace name 'm' could not be found (are you missing a using directive or an as sembly reference?) - Error: Scripts\Misc\LoginStats.cs: CS0246: (line 25, column 5) The type or na mespace name 'm' could not be found (are you missing a using directive or an ass embly reference?)
I will see what I can figure out. Probably has to do with the space in the name but I shall figure it out and post a fix. Thanks for pointing it out.Reggie said:nice script but a problem is i had a character named reggie and a char named reggie noble on the shard and the letter was sent to the wrong one
any idea to fix that?
i just wrote the lette and clicked done
i dont know if there anything else to do with it
And you are positive that you are using the most current version? I did just make an update to fix another bug but in v2.4 the problem you mention should have been fixed.akrondar said:anyone el se having problems with letters....? mine are erased when i closed them..
using System;
using Server.Network;
using Server.Gumps;
using Server.Items;
namespace Server.Misc
{
public class LoginStats
{
public static void Initialize()
{
// Register our event handler
EventSink.Login += new LoginEventHandler( EventSink_Login );
}
MailBox mailbox = m.BankBox.FindItemByType( typeof( MailBox ) ) as MailBox;
if ( mailbox != null )
{
if ( mailbox.NewMail == "true" )
m.SendGump( new NewMailGump( m, mailbox ) );
}
private static void EventSink_Login( LoginEventArgs args )
{
using System;
using Server;
using Server.Items;
using Server.Mobiles;
using Server.Network;
using Server.Accounting;
namespace Server.Misc
{
public class CharacterCreation
{
public static void Initialize()
{
// Register our event handler
EventSink.CharacterCreated += new CharacterCreatedEventHandler( EventSink_CharacterCreated );
}
{
newChar.BankBox.DropItem( new MailBox() );
}
private static void AddBackpack( Mobile m )
{
Container pack = m.Backpack;
if ( pack == null )
{
pack = new Backpack();
pack.Movable = false;
m.AddItem( pack );
}
sirbum69 said:ok after further testing of this i have found out what is wrong. if the player pulls the letter from the mail box to there backpack with out reading it first then it will show up blank.
if they dbl click it while its in the mailbox first then it will show the message like it should and from then on it will stay in there backpack and can be read.
could someone tell me how this could be fixed.
Shard Admin Adam said:I am having same problem on my test system. However, my letters are blank if read in the mail box and in the backpack. I followed the correct send procedures as well... Maybe an update issue with 1.0?
corbin77x2 said:Is this code supported in 1.0.0? because that dates look a little old for the newer version of runuo, and i didn't see any recent updates. maybe i missed something.
raisor said:Advertising is against the rules except in designated forums, hope you enjoyed your 2 posts.