Register for your free account! | Forgot your password?

You last visited: Today at 03:50

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



LoveStone Problem

Discussion on LoveStone Problem within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old   #1
 
Electro51's Avatar
 
elite*gold: 0
Join Date: Aug 2009
Posts: 46
Received Thanks: 5
LoveStone Problem

Hi, I have a problem with crush stone for her wedding says you are married but I am not the code is not complete I need help and the npc clans..
Thank you in advance
Electro51 is offline  
Old 12/18/2009, 00:02   #2
 
elite*gold: 0
Join Date: Aug 2009
Posts: 930
Received Thanks: 448
yeah i noticed there was a error with spouses. you'll need to edit the code of it, i haven't even looked, honestly i think marriage is useless & gay (on the game ahhahaah)
.Guru is offline  
Old 12/18/2009, 05:49   #3
 
Arcо's Avatar
 
elite*gold: 0
Join Date: Oct 2009
Posts: 8,783
Received Thanks: 5,304
Quote:
Originally Posted by Electro51 View Post
Hi, I have a problem with crush stone for her wedding says you are married but I am not the code is not complete I need help and the npc clans..
Thank you in advance

Post the code here.
I'll take a look.
Arcо is offline  
Old 12/18/2009, 13:02   #4
 
Electro51's Avatar
 
elite*gold: 0
Join Date: Aug 2009
Posts: 46
Received Thanks: 5
Quote:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace NewestCOServer.PacketHandling
{
public class Marriage
{
public static void Handle(Main.GameClient GC, byte[] Data)
{
uint AttackType = BitConverter.ToUInt32(Data, 20);

if (AttackType == 8)
{
uint TargetUID = BitConverter.ToUInt32(Data, 12);
Game.Character TargetMarry = null;

if (Game.World.H_Chars.Contains(TargetUID))
TargetMarry = (Game.Character)Game.World.H_Chars[TargetUID];

if (GC.MyChar.Spouse != "None")
{ GC.LocalMessage(2005, "You are married."); return; }
if (TargetMarry.Spouse != "None")
{ GC.LocalMessage(2005, "The target is married."); return; }
if ((TargetMarry.Body == 1003 || TargetMarry.Body == 1004) && (GC.MyChar.Body == 1003 || GC.MyChar.Body == 1004))
{ GC.LocalMessage(2005, "No male and male marriage is permited!"); return; }
if ((TargetMarry.Body == 2001 || TargetMarry.Body == 2002) && (GC.MyChar.Body == 2001 || GC.MyChar.Body == 2002))
{ GC.LocalMessage(2005, "No female and female marriage is permited!"); return; }

TargetMarry.MyClient.AddSend(Packets.AttackPacket( GC.MyChar.EntityID, TargetMarry.EntityID, TargetMarry.Loc.X, TargetMarry.Loc.Y, 0, 8));
}
else if (AttackType == 9)
{
uint TargetUID = BitConverter.ToUInt32(Data, 12);
Game.Character TargetMarry = null;

if (Game.World.H_Chars.Contains(TargetUID))
TargetMarry = (Game.Character)Game.World.H_Chars[TargetUID];

TargetMarry.Spouse = GC.MyChar.Name + GC.AuthInfo.Status;
GC.MyChar.Spouse = TargetMarry.Name + TargetMarry.MyClient.AuthInfo.Status;

TargetMarry.MyClient.AddSend(Packets.String(Target Marry.EntityID, 6, TargetMarry.Spouse));
GC.AddSend(Packets.String(GC.MyChar.EntityID, 6, GC.MyChar.Spouse));

Database.SaveCharacter(TargetMarry, TargetMarry.MyClient.AuthInfo.Account);
Database.SaveCharacter(GC.MyChar, GC.AuthInfo.Account);
if (GC.MyChar.Body == 1003 || GC.MyChar.Body == 1004)
Game.World.SendMsgToAll("SYSTEM", GC.MyChar.Name + " and " + TargetMarry.Name + " are married now.", 2011, 0);
else
Game.World.SendMsgToAll("SYSTEM", TargetMarry.Name + " and " + GC.MyChar.Name + " are married now.", 2011, 0);
}
}
}
}
Marriage.cs
Electro51 is offline  
Old 12/20/2009, 02:30   #5
 
elite*gold: 0
Join Date: Sep 2009
Posts: 17
Received Thanks: 0
error
لعبة الحيا is offline  
Old 12/21/2009, 20:10   #6
 
WHITELIONX's Avatar
 
elite*gold: 0
Join Date: Apr 2006
Posts: 534
Received Thanks: 66
Oops my mistake just take this line out

{ GC.LocalMessage(2005, "The target is married."); return; }

It should work fine then I just rechecked mine and I took this line out!

It might be that the line needs to be moved elsewhere in the file but for now I have just taken it out and it seems to work fine.

Just wondering but did this help? I like to know if it actually helped and I am not really that interested in the thanks lol just want to know if it sorted the problem. It`s always good to update to let people know that the problem has been solved.
WHITELIONX is offline  
Reply


Similar Threads Similar Threads
[Release] LoveStone that Marries you and Divorces you
02/28/2010 - CO2 PServer Guides & Releases - 12 Replies
Find "#region Love Stone" and replace the whole code with this: #region Love Stone case 390: { if (Control == 0) { GC.AddSend(Packets.NPCSay("Hello my friend! What I can do for you?")); GC.AddSend(Packets.NPCLink("I wanna get married.", 1)); ...
My First Edit {LoveStone}
06/30/2009 - CO2 Weapon, Armor, Effects & Interface edits - 9 Replies
My First Edit xD LoveStone :- http://img259.imageshack.us/img259/5848/lovestone .jpg DownLoad Here Thanks xD
what is LoveStone
12/19/2006 - Conquer Online 2 - 18 Replies
..? and where i can find it?



All times are GMT +1. The time now is 03:52.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.