Register for your free account! | Forgot your password?

You last visited: Today at 19:50

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

Advertisement



help with comy 5017

Discussion on help with comy 5017 within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: May 2008
Posts: 103
Received Thanks: 3
help with comy 5017

I want to be a limited number of exball so that each player on the day 10 exball not be open


if u want help post your reply


That's all, thank
m7med is offline  
Old 07/22/2009, 18:05   #2
 
n0mansland's Avatar
 
elite*gold: 0
Join Date: Aug 2008
Posts: 780
Received Thanks: 255
First make a table in characters in navicat or w/e. Then name it like ExpBall.. Then once you do that define everything so you can use it in C#.. A few examples if you search.. Then find where exp ***** are used and near the top or something put like MyChar.ExpBall < 11) So it checks if you used 10 or below.. <-- Making at the top of my mind >.>.. Once you made it check go near the end and put something like ExpBall+1 <-- Not sure of the code just came back to LOTF... but in CoEmu It would be like
Code:
ExpBall(+1, CSocket);
Then you have to make a timer for the end of the day where it takes away all your exp ball points... and sets it back to 0
n0mansland is offline  
Thanks
1 User
Old 07/22/2009, 18:17   #3
 
elite*gold: 0
Join Date: May 2008
Posts: 103
Received Thanks: 3
Thank you for this but i hope u can help me by team viewer


add me

hope see u in my list friend ؛)
m7med is offline  
Old 07/22/2009, 18:29   #4
 
elite*gold: 20
Join Date: Jan 2008
Posts: 2,338
Received Thanks: 490
add in Character.cs
PHP Code:
        // ExpBall-limit
        
public uint expball 0;
        public 
DateTime expballend;
        public 
string expballend2 ""
then search for: else if (ItemParts[0] == "723700")
and replace this item with:
PHP Code:
else if (ItemParts[0] == "723700")
            {
                if (
expball 10)
                {
                    
expball++;
                    
expballend DateTime.Now.AddDays(1);
                    
SaveExpball();

                    if (
Level 100)
                        
AddExp((ulong)(1295000 Level 50000), false);
                    else if (
Level 110)
                        
AddExp((ulong)(1395000 Level 80000), false);
                    else if (
Level 115)
                        
AddExp((ulong)(1595000 Level 100000), false);
                    else if (
Level 120)
                        
AddExp((ulong)(1895000 Level 120000), false);
                    else if (
Level 125)
                        
AddExp((ulong)(2095000 Level 150000), false);
                    else if (
Level 130)
                        
AddExp((ulong)(2395000 Level 180000), false);
                    else if (
Level 135)
                        
AddExp((ulong)(2895000 Level 200000), false);
                    
RemoveItem(ItemUID);
                }
                else
                {
                    
MyClient.SendPacket(General.MyPackets.SendMsg(MyClient.MessageId"SYSTEM"Name"You used allready 10 used ExpBalls"2005));
                }
                
            } 
search for : if (DateTime.Now > GotBlueName.AddMilliseconds(35000))
and an before:


PHP Code:
if (DateTime.Now >= expballend)
            {
                
                
expballend2 "";
                
expball 0;
                
SaveExpball();
                
MyClient.SendPacket(General.MyPackets.Vital(UID180));
                
MyClient.SendPacket(General.MyPackets.Vital(UID26GetStat()));
                
World.UpdateSpawn(this);
            } 
then search for: public void Save()
and add before
PHP Code:
 public void SaveExpball()
        {
            if (
MyClient.There)
                if (
MyClient.Online)
                    
DataBase.SaveExpball(this);
        } 
now search for you wellcomemess and add before:

PHP Code:
if (MyChar.expball 0)
                                        {
                       
                                            
MyChar.expballend DateTime.Parse(MyChar.expballend2);
                                            
SendPacket(General.MyPackets.String(MyChar.UID10"zf2-e128"));

                                            
SendPacket(General.MyPackets.Vital(MyChar.UID26MyChar.GetStat()));
                                            
World.UpdateSpawn(MyChar);
                                        } 
search for: public static void SaveChar(Character Charr)
and add befor:

HTML Code:
[PHP]public static void Expball(Character Charr)
        {
            try
            {
                MySqlCommand Command = null;
                Command = new MySqlCommand("UPDATE `Characters` SET `expballend` = '" + Charr.expballend.ToString() + "',`expball` = '" + Charr.expball + "' WHERE `Account` = '" + Charr.MyClient.Account + "'", Connection);
                Command.ExecuteNonQuery();

            }
            catch (Exception Exc) { General.WriteLine(Convert.ToString(Exc)); }
        }[/PHP]
Now,search for:
Charr.RealModel = Charr.Model;
and add before

PHP Code:
Charr.expballend2 = (string)DR["expballend"];
                    
Charr.expball = (byte)DR["expball"]; 
Last part,add this into your Character table in database :
Code:

PHP Code:
Fieldexpballend
Type 
VARCHAR
Lenght 
32
null 
not null 
and
Code:
PHP Code:
Fieldexpball
Type 
TINYINT
Lenght 
10
Attribute 
UNSIGNED
null 
not null
Default : 
thatīs all
~Yuki~ is offline  
Old 07/22/2009, 18:35   #5
 
elite*gold: 0
Join Date: Oct 2008
Posts: 430
Received Thanks: 176
search

Code:
else if (ItemParts[0] == "723700")
add this below it

Code:
{
if (ExpBallCount < 5)
{
go to the bottom and before

Code:
RemoveItem
add

Code:
ExpBallCount++;
then search

Code:
public byte RBCount = 0;
and add this below it

Code:
public byte ExpBallCount = 0;
That will make it so they can only use 5, though if they relog, it will reset the count. You'll need to create a timer, and a database entry to record the count.

Goodluck...

Edit: Of course someone else would post while I was typing -_-"

lol
Incariuz is offline  
Old 07/22/2009, 20:36   #6
 
elite*gold: 0
Join Date: May 2008
Posts: 103
Received Thanks: 3
thank ~Yuki~ and Incariuz i will try its
m7med is offline  
Old 07/23/2009, 21:07   #7
 
elite*gold: 0
Join Date: May 2008
Posts: 103
Received Thanks: 3
now search for you wellcomemess and add before:


where this place
m7med is offline  
Reply


Similar Threads Similar Threads
most wanted for me help in comy 5017
07/23/2009 - CO2 Private Server - 6 Replies
in my server i did not have donation system like king and queen if u can help me plz post your reply
[Developement] CoMy 5017 With Ninja And Evreything
07/22/2009 - CO2 Private Server - 123 Replies
Credits to BrokeN WinG for base! Well i decided to continue working on that source for the community. What we have so far: Ninja Nearly Done except skills 120 Earring Called CoMyEarring DONE 120 Shield called DragonShield DONE GoldTrophy FIxed and Done



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


Powered by vBulletin®
Copyright ©2000 - 2026, 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 ©2026 elitepvpers All Rights Reserved.