Register for your free account! | Forgot your password?

You last visited: Today at 13:20

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

Advertisement



@revive command

Discussion on @revive command within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Jan 2009
Posts: 1,922
Received Thanks: 491
Question @revive command

hi im pete,

this is not a release just a question , and i dont even know if this code works never tested ( ye its for LOTF , if you have a problem dont post xD )

Code:
if (Splitter[0] == "@revive")
                                            {
                                                foreach (DictionaryEntry DE in World.AllChars)
                                                {
                                                    if (MyChar.Alive = false)
                                                        Char.CurHP = Char.MaxHP;
                                                        Char.Alive = true;
                                                        Char.MyClient.SendPacket(General.MyPackets.Status1(Char.UID, 0));
                                                        Char.MyClient.SendPacket(General.MyPackets.Status3(Char.UID));
                                                        Char.MyClient.SendPacket(General.MyPackets.Vital(Char.UID, 26, Char.GetStat()));
                                                        Char.MyClient.SendPacket(General.MyPackets.CharacterInfo(Char));
                                                        Char.SendEquips(false);
                                                        Char.BlueName = false;
                                                        Char.MyClient.SendPacket(General.MyPackets.Vital(Char.UID, 26, Char.GetStat()));
                                                        Char.Stamina = 100;
                                                        Char.MyClient.SendPacket(General.MyPackets.Vital(Char.UID, 9, Char.Stamina));
                                                        World.UpdateSpawn(Char);

                                                    Character Char = (Character)DE.Value;
                                                    if (Splitter[1] == Char.Name)
                                                    {
                                                        Char.CurHP = Char.MaxHP;
                                                        Char.Alive = true;
                                                        Char.MyClient.SendPacket(General.MyPackets.Status1(Char.UID, 0));
                                                        Char.MyClient.SendPacket(General.MyPackets.Status3(Char.UID));
                                                        Char.MyClient.SendPacket(General.MyPackets.Vital(Char.UID, 26, Char.GetStat()));
                                                        Char.MyClient.SendPacket(General.MyPackets.CharacterInfo(Char));
                                                        Char.SendEquips(false);
                                                        Char.BlueName = false;
                                                        Char.MyClient.SendPacket(General.MyPackets.Vital(Char.UID, 26, Char.GetStat()));
                                                        Char.Stamina = 100;
                                                        Char.MyClient.SendPacket(General.MyPackets.Vital(Char.UID, 9, Char.Stamina));
                                                        World.UpdateSpawn(Char);
                                                    }
                                                }
                                            }
any simplier way to write this?

what im trying to do here is check if im dead and if i am dead it will revive me, but if i want to revive someoen else < such as @revive hairybob , it will revive them.. any help?
PeTe Ninja is offline  
Old 02/07/2009, 01:31   #2
 
elite*gold: 0
Join Date: Jan 2009
Posts: 145
Received Thanks: 4
I can help you but i need a favor in return.. xD do you have teamview?
add me on msn:
TasteofChaos is offline  
Old 02/07/2009, 01:42   #3
 
elite*gold: 0
Join Date: Jan 2009
Posts: 1,922
Received Thanks: 491
lol its not like i deadly need it... just post here and ask for a favor, i help anyone.. everyone knows that
PeTe Ninja is offline  
Old 02/07/2009, 01:45   #4
 
Hoven's Avatar
 
elite*gold: 0
Join Date: Jan 2009
Posts: 456
Received Thanks: 128
PeTe sign on msn

u been posting here all day n i wanted 2 talk 2 ya haha
Hoven is offline  
Old 02/07/2009, 01:46   #5
 
elite*gold: 0
Join Date: Jan 2009
Posts: 145
Received Thanks: 4
Quote:
Originally Posted by PeTe Ninja View Post
lol its not like i deadly need it... just post here and ask for a favor, i help anyone.. everyone knows that
I don't usually use a LOTF source, but I'm working on something atm and don't wanna screw up my main source, but I'm having a problem to start debugging.. (not giving me the option) I just thought you might know more about this than I do. Thanks.

TasteofChaos is offline  
Old 02/07/2009, 02:02   #6
 
elite*gold: 0
Join Date: Feb 2008
Posts: 1,590
Received Thanks: 154
The character class has a revive(bool) already coded for you.
MyChar.Revive(false);//false means no rev point, true will teleport you.
tao4229 is offline  
Old 02/07/2009, 02:04   #7
 
damianpesta's Avatar
 
elite*gold: 0
Join Date: Jan 2007
Posts: 1,034
Received Thanks: 58
Quote:
Originally Posted by tao4229 View Post
The character class has a revive(bool) already coded for you.
MyChar.Revive(false);//false means no rev point, true will teleport you.
True its easier way, but It teleports you to Nearest Rev point.This one is not bad tho... But you always can have 2 of em? rite? I c no prob in that =o
damianpesta is offline  
Old 02/07/2009, 02:28   #8
 
elite*gold: 0
Join Date: Feb 2008
Posts: 1,590
Received Thanks: 154
Quote:
Originally Posted by damianpesta View Post
True its easier way, but It teleports you to Nearest Rev point.This one is not bad tho... But you always can have 2 of em? rite? I c no prob in that =o
Read what I said.

If you pass the first(and only) parameter as false, it won't teleport you to the nearest rev point, if you specify it as true, it will.
Look at the pray code(pray as in the water tao revive skill, not luckytime).
tao4229 is offline  
Old 02/07/2009, 02:28   #9
 
damianpesta's Avatar
 
elite*gold: 0
Join Date: Jan 2007
Posts: 1,034
Received Thanks: 58
Quote:
Originally Posted by tao4229 View Post
Read what I said.

If you pass the first(and only) parameter as false, it won't teleport you to the nearest rev point, if you specify it as true, it will.
Look at the pray code(pray as in the water tao revive skill, not luckytime).
#true , ur rite :P
damianpesta is offline  
Old 02/07/2009, 02:41   #10
 
Exia13's Avatar
 
elite*gold: 0
Join Date: May 2008
Posts: 256
Received Thanks: 21
Quote:
Originally Posted by TasteofChaos View Post
I can help you but i need a favor in return.. xD do you have teamview?
add me on msn:
Just letting you know. Nobody really knows who you are. You just made your account last month. Don't go asking people if they have team viewer. Im not flaming you, but seriously, no one's gonna trust you so easily.
Exia13 is offline  
Old 02/07/2009, 02:54   #11
 
elite*gold: 0
Join Date: Feb 2008
Posts: 1,590
Received Thanks: 154
Code:
[color=black]
[color=blue]if [/color](Splitter[0] == [color=darkred]"@revive"[/color])
{
    [color=blue]if[/color] (Splitter.Length == 1)
        MyChar.Revive([color=blue]false[/color]);
    [color=blue]else[/color]
    {
         [color=blue]string[/color] Name = Splitter[1];
         [color=blue]foreach[/color] ([Color=mediumturquoise]DictionaryEntry[/color] DE [color=blue]in[/color] [color=mediumturquoise]World[/color].AllChars)
         {
             [Color=MediumTurquoise]Character[/color] Revived = ([Color=MediumTurquoise]Character[/color])DE.Value;
            [color=blue] if [/color](Revived.Name == Name) Revived.Revive([color=blue]false[/color]);
         }
    }
}
[/color]
tao4229 is offline  
Old 02/07/2009, 03:36   #12
 
elite*gold: 0
Join Date: Jan 2009
Posts: 145
Received Thanks: 4
this is my second account exia.. i was originally "stiggydude" since jan 2006 =P
TasteofChaos is offline  
Old 02/07/2009, 14:00   #13
 
Beta Limit's Avatar
 
elite*gold: 0
Join Date: Dec 2008
Posts: 493
Received Thanks: 71
Quote:
Originally Posted by Exia13 View Post
Just letting you know. Nobody really knows who you are. You just made your account last month. Don't go asking people if they have team viewer. Im not flaming you, but seriously, no one's gonna trust you so easily.
I know who he is thanks very much and he is trust worthy.
Beta Limit is offline  
Reply


Similar Threads Similar Threads
[Release] Revive Command
08/02/2010 - CO2 PServer Guides & Releases - 2 Replies
This is a perfect revive command to my knowledge I've tested it multiple times in my server and had no problems. I'm currently working on remaking all commands and releasing them sometime in the near future. This is for a 5165 source. Hope you guys like it :D Command: /revive /revive (players name) #region Revive if (Cmd == "/Revive" || Cmd == "/revive")
Die and revive in under 1 sec
03/13/2010 - Conquer Online 2 - 3 Replies
hey, today i fight to it was only me and another noobie in Ninja class pk war.. i killed her.. so i speaked to the blue man, and he said i won.. so i took claim prize. and when i got teleport.. i did not get the expballs and the Halo.. and some few mins later.. i saw that Noobie won the Ninja Pk Class war.. please help.
[RELEASE] Revive Command
10/06/2009 - CO2 PServer Guides & Releases - 13 Replies
Press thanks and I hope you enjoy. In Client.cs add:
Revive anywhere.
08/06/2009 - CO2 Exploits, Hacks & Tools - 63 Replies
Patched.



All times are GMT +2. The time now is 13:20.


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