|
You last visited: Today at 22:00
Advertisement
[Help] /hp command
Discussion on [Help] /hp command within the CO2 Private Server forum part of the Conquer Online 2 category.
07/06/2009, 06:53
|
#1
|
elite*gold: 0
Join Date: Sep 2007
Posts: 1,705
Received Thanks: 441
|
[Help] /hp command
Ok im really new to c# and dont know much so would anyone be willing to hlep me with an /hp command (some sources might have it but the one i got doesnt)
This is what I got and I know something is missing so im not suprised that it doesnt work:
Code:
if (Splitter[0] == "/hp")
{
MyChar.MaxHP = MyChar.BaseMaxHP();
MyChar.CurHP = MyChar.MaxHP;
}
|
|
|
07/06/2009, 07:21
|
#2
|
elite*gold: 20
Join Date: Apr 2008
Posts: 2,281
Received Thanks: 913
|
With Co, you have to send Packets to the Client to know whats happening.
So you have to send the status packet for the Hp.
|
|
|
07/06/2009, 17:28
|
#3
|
elite*gold: 0
Join Date: Sep 2007
Posts: 1,705
Received Thanks: 441
|
Ok now im doing an internal database packet:
Code:
if (Splitter[0] == "/hp")
{
InternalDatabase.GetStats(MyChar);
MyChar.MaxHP = MyChar.BaseMaxHP();
MyChar.CurHP = MyChar.MaxHP;
}
Like i said im new to c# and I cant get "GetCurHP" for the internal DB b/c it has no definition :/
|
|
|
07/06/2009, 17:46
|
#4
|
elite*gold: 0
Join Date: Jun 2009
Posts: 149
Received Thanks: 15
|
Rawr AlwaysOnDicks. Where'd you go.
Anyways, you should base the command off a HP pot because it's the same concept.
Code:
if (Splitter[0] == "/hp")
{
MyChar.MaxHP = MyChar.BaseMaxHP();
MyChar.CurHP = MyChar.MaxHP;
SendPacket(General.MyPackets.Vital(MyChar.UID, 0, MyChar.CurHP));
}
|
|
|
07/06/2009, 17:56
|
#5
|
elite*gold: 0
Join Date: Sep 2007
Posts: 1,705
Received Thanks: 441
|
Well ill try that in a bit but my command will work but fills up half HP, and reviving uses same concept,
Code:
CurHP = MaxHP;
Alive = true;
And i still get half HP, but when I use /job XX i get full hp ???
EDIT: Woot it works now, I fixed the revive HP too. The working command is:
Code:
if (Splitter[0] == "/hp")
{
MyChar.CurHP = MyChar.MaxHP;
SendPacket(General.MyPackets.Vital((long)MyChar.UID, 0, MyChar.CurHP));
}
|
|
|
07/06/2009, 18:04
|
#6
|
elite*gold: 0
Join Date: Jun 2009
Posts: 149
Received Thanks: 15
|
Idk, I just made this up quickleh. Here joo goo mr. aod.
Code:
if (Splitter[0] == "/revive")
{
MyChar.CurHP = MyChar.MaxHP;
MyChar.Alive = true;
MyChar.MyClient.SendPacket(General.MyPackets.Status1(MyChar.UID, 0));
MyChar.MyClient.SendPacket(General.MyPackets.Status3(MyChar.UID));
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 26, MyChar.GetStat()));
MyChar.MyClient.SendPacket(General.MyPackets.CharacterInfo(MyChar));
MyChar.SendEquips(false);
MyChar.BlueName = false;
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 26, MyChar.GetStat()));
MyChar.Stamina = 100;
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 9, MyChar.Stamina));
World.UpdateSpawn(MyChar);
}
|
|
|
07/06/2009, 18:15
|
#7
|
elite*gold: 0
Join Date: Sep 2007
Posts: 1,705
Received Thanks: 441
|
They already had that command + someone released it:
This is the one most have:
Code:
if (Splitter[0] == "/rev")
{
MyChar.CurHP = MyChar.MaxHP;
MyChar.Alive = true;
MyChar.MyClient.SendPacket(General.MyPackets.Status1(MyChar.UID, 0));
MyChar.MyClient.SendPacket(General.MyPackets.Status3(MyChar.UID));
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 26, MyChar.GetStat()));
MyChar.MyClient.SendPacket(General.MyPackets.CharacterInfo(MyChar));
MyChar.SendEquips(false);
MyChar.BlueName = false;
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 26, MyChar.GetStat()));
MyChar.Stamina = 100;
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 9, MyChar.Stamina));
MyChar.MyClient.SendPacket(General.MyPackets.String(MyChar.UID, 10, "born3"));
World.UpdateSpawn(MyChar);
}
|
|
|
07/06/2009, 18:20
|
#8
|
elite*gold: 20
Join Date: Jun 2006
Posts: 3,296
Received Thanks: 925
|
Quote:
Originally Posted by AmbiguousStatement
Idk, I just made this up quickleh. Here joo goo mr. aod.
Code:
if (Splitter[0] == "/revive")
{
MyChar.CurHP = MyChar.MaxHP;
MyChar.Alive = true;
MyChar.MyClient.SendPacket(General.MyPackets.Status1(MyChar.UID, 0));
MyChar.MyClient.SendPacket(General.MyPackets.Status3(MyChar.UID));
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 26, MyChar.GetStat()));
MyChar.MyClient.SendPacket(General.MyPackets.CharacterInfo(MyChar));
MyChar.SendEquips(false);
MyChar.BlueName = false;
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 26, MyChar.GetStat()));
MyChar.Stamina = 100;
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 9, MyChar.Stamina));
World.UpdateSpawn(MyChar);
}
|
Quote:
Originally Posted by raidenx123
They already had that command + someone released it:
This is the one most have:
Code:
if (Splitter[0] == "/rev")
{
MyChar.CurHP = MyChar.MaxHP;
MyChar.Alive = true;
MyChar.MyClient.SendPacket(General.MyPackets.Status1(MyChar.UID, 0));
MyChar.MyClient.SendPacket(General.MyPackets.Status3(MyChar.UID));
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 26, MyChar.GetStat()));
MyChar.MyClient.SendPacket(General.MyPackets.CharacterInfo(MyChar));
MyChar.SendEquips(false);
MyChar.BlueName = false;
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 26, MyChar.GetStat()));
MyChar.Stamina = 100;
MyChar.MyClient.SendPacket(General.MyPackets.Vital(MyChar.UID, 9, MyChar.Stamina));
MyChar.MyClient.SendPacket(General.MyPackets.String(MyChar.UID, 10, "born3"));
World.UpdateSpawn(MyChar);
}
|
LOTF right? if so this one is better:
Code:
if (Splitter[0] == "/revive")
{
if (!MyChar.Alive)
MyChar.Revive(false);
}
|
|
|
07/06/2009, 19:22
|
#9
|
elite*gold: 0
Join Date: Sep 2007
Posts: 1,705
Received Thanks: 441
|
By the looks does that one just revive you?
/rev Charname is the one i use
Edit: Woot just finished new quest "The Darkness"
|
|
|
07/06/2009, 19:58
|
#10
|
elite*gold: 0
Join Date: Jun 2009
Posts: 149
Received Thanks: 15
|
Quote:
Originally Posted by raidenx123
By the looks does that one just revive you?
/rev Charname is the one i use
Edit: Woot just finished new quest "The Darkness"
|
w00t, just stoled your client makingzorsz with the ak.
|
|
|
07/06/2009, 22:38
|
#11
|
elite*gold: 0
Join Date: Sep 2007
Posts: 1,705
Received Thanks: 441
|
Lolz ur dumb, i said the AK was photoshopped b/c i was waiting for the thread to appear
And i never released my client with all the edits.
|
|
|
07/06/2009, 23:19
|
#12
|
elite*gold: 0
Join Date: Jun 2009
Posts: 149
Received Thanks: 15
|
Quote:
Originally Posted by raidenx123
Lolz ur dumb, i said the AK was photoshopped b/c i was waiting for the thread to appear
And i never released my client with all the edits.
|
Yesh yu deeeed fagpahgabag.
Yu gib me yestermorraw. Dnt yu think that FRIED ***** have gotten it and ditrubate it.
|
|
|
07/07/2009, 00:33
|
#13
|
elite*gold: 0
Join Date: Sep 2007
Posts: 1,705
Received Thanks: 441
|
:P i havent even made it a .rar yet and even if you somehow got it then its useless, it has no armors or headgear LOL
|
|
|
07/07/2009, 00:37
|
#14
|
elite*gold: 0
Join Date: Jun 2009
Posts: 149
Received Thanks: 15
|
Gtfo. I HACKED YOUR COMPUTER WITH GOOGLE AND WEED.
|
|
|
07/07/2009, 05:35
|
#15
|
elite*gold: 0
Join Date: Jan 2009
Posts: 1,922
Received Thanks: 491
|
your revive command fails
here is saints...
Code:
if (Splitter[0] == "/revive")
{
if (Splitter.Length == 1)
MyChar.Revive(false);
else
{
string Name = Splitter[1];
foreach (DictionaryEntry DE in World.AllChars)
{
Character Revived = (Character)DE.Value;
if (Revived.Name == Name) Revived.Revive(false);
}
}
}
here is the hp command.
Code:
if (Splitter[1] == "/hp")
{
MyChar.CurHP = MyChar.MaxHP;
SendPacket(General.MyPackets.Vital((long)MyChar.UID, 0, MyChar.CurHP));
}
|
|
|
 |
|
Similar Threads
|
command
06/27/2010 - CO2 Private Server - 8 Replies
Using:CoSX Source
hey guys i have my p server and i am PM and i have a normal the name of it is test1 i do /kick test1 ok so it gets dc so now my other friend has an acc name xSplashx i do /kick xSplashx and nothing happens i get a error on my CoSX console
|
GM command-s
04/06/2010 - SRO Private Server - 8 Replies
Please start I Silkroad server 1.236 (CRSEMU) how to fix that I am GM and what are the command-s to spawn the NPC-s and MOB-s and ITEM-s and GOLD please help, give me command-s, ty
|
[HELP] command
02/05/2010 - EO PServer Hosting - 4 Replies
I would like to know how the write command in data base
For example when a player kills a monster, that you mosntro of an item, if he kills the monster again, the action of this monster would be saying he already got the item that day, your not experienced in programming but I'm doing my own quest.
thank you very much
excuse the English
|
i want command
02/24/2009 - CO2 Private Server - 3 Replies
hi guys
what command for skill reflect
and why star guild war in cov2 cource
thanx ..
|
o:- can't do both of that command plz some help ...
02/13/2008 - Kal Online - 9 Replies
hi u guys , sup every ?? hope all fine
i have some problem .. i'm a gm in private server and when i type /moveto name of player none moving from my place it's mean not work so any 1 can just say me what can i do ?? 2 get place's player
2nd problem i can't attacking moobs while away from them i should get close enough like normal player ??
i need some help plz
3rd how i can get stuff mixing Demon Blood ?? or should admin make it 4 me
4th why i can't upgrade it egg's 4 ppl or me ?? or same...
|
All times are GMT +1. The time now is 22:00.
|
|