HomePortalFAQSearchMemberlistUsergroupsRegisterLog in
Meet the new KITO admins & hear their plans here.
You can use google search to find threads and posts here now. Example

Share | 
 

 Infinit pvp??(Solved)

View previous topic View next topic Go down 
AuthorMessage
GlaciaTheWolf
®
®
avatar

Game username : Glacia, GlaciaIceWolf, GlaciaTheWolf
Server : DD (member) Wolf soul (member)
Female Posts : 1001
Join date : 2013-12-09
Age : 21
Location : Ohio

PostSubject: Infinit pvp??(Solved)   Sun Feb 08, 2015 5:49 am

I got Pvp to work in a map, but you can't kill the player? how can i make it so you can actually kill them?


Screenshot of the code



Last edited by glaciaicewolf on Sun Feb 08, 2015 10:17 pm; edited 1 time in total
Back to top Go down
Revaen
Very Helpful
Very Helpful


Male Posts : 314
Join date : 2013-07-21
Age : 16

PostSubject: Re: Infinit pvp??(Solved)   Sun Feb 08, 2015 6:30 am

I don't understand the question?

If you set alliance as enemy it will attack until kill it(and keeps attacking even after wounded).

What are you exactly having issue with?
Back to top Go down
GlaciaTheWolf
®
®
avatar

Game username : Glacia, GlaciaIceWolf, GlaciaTheWolf
Server : DD (member) Wolf soul (member)
Female Posts : 1001
Join date : 2013-12-09
Age : 21
Location : Ohio

PostSubject: Re: Infinit pvp??(Solved)   Sun Feb 08, 2015 9:59 am

The other players do not die what so ever, their health doesnt even go down
Back to top Go down
Worthis
Coder
Coder
avatar

Game username : Worthis
Server : Impressive Space
Male Posts : 157
Join date : 2012-09-29
Age : 28
Location : Russian Federation

PostSubject: Re: Infinit pvp??(Solved)   Sun Feb 08, 2015 10:58 am

That bug was fixed in new version of KITO
Back to top Go down
http://cl001.dc.stnetix.com
GlaciaTheWolf
®
®
avatar

Game username : Glacia, GlaciaIceWolf, GlaciaTheWolf
Server : DD (member) Wolf soul (member)
Female Posts : 1001
Join date : 2013-12-09
Age : 21
Location : Ohio

PostSubject: Re: Infinit pvp??(Solved)   Sun Feb 08, 2015 5:20 pm

How do i fix it?

I dont want to download the new source, because we use the body selector source
Back to top Go down
Revaen
Very Helpful
Very Helpful


Male Posts : 314
Join date : 2013-07-21
Age : 16

PostSubject: Re: Infinit pvp??(Solved)   Sun Feb 08, 2015 8:41 pm

RedEye wrote:
Here's the complete code needed for MagixServer.cpp:
Code:
case ID_PLAYERINFO:
{
 bool tReadSenderToken = false;
 if(imTheOwner(p))
 {
 RakNet::BitStream tReceiveBit(p->data, p->length, false);
 MessageID tMessage;
 tReceiveBit.Read(tMessage);

 RakNet::BitStream tBitStream;

 tBitStream.Write(tMessage);
 tBitStream.Write(getOwnerToken(p));
 tBitStream.Write(&tReceiveBit);
 sendAllServers(&tBitStream, LOW_PRIORITY, RELIABLE, 0, UNASSIGNED_SYSTEM_ADDRESS);
 }
 else tReadSenderToken = true;

 RakNet::BitStream tReceiveBit(p->data, p->length, false);
 MessageID tMessage;
 OwnerToken tSender;
 
string tMapName;
 unsigned char tDimension;
 bool tIsUpdate = false;
 bool tIsHit = false;

 tReceiveBit.Read(tMessage);
 BitSize_t offset;
 if(tReadSenderToken)
 { //printf("RTok\n");
 tReceiveBit.Read(tSender);
 offset = tReceiveBit.GetReadOffset();
 if(tSender<=0 || tSender>MAX_CLIENTS)break;
 tMapName = clientMap[tSender-1];
 tDimension = clientDimension[tSender-1];
 tReceiveBit.Read(tIsUpdate);
 tReceiveBit.Read(tIsHit);
 }
 else
{
 offset = tReceiveBit.GetReadOffset();
 getOwnerToken(p,tMapName,tDimension);
 tReceiveBit.Read(tSender);
 tReceiveBit.Read(tIsUpdate);
 tReceiveBit.Read(tIsHit);
 }

 if(tIsHit)
 {
 OwnerToken tUnitID;
 float tDamage = 0;

 tReceiveBit.Read(tUnitID);
 tReceiveBit.Read(tDamage);
 if(tDamage < 0 && tUnitID != tSender)
 { // user attacked another user
 const string tCaption = "<<(SERVER WARNING)>> "+clientName[tSender-1]+" ATTACKED "+clientName[tUnitID-1]+" FOR "+intToString((int)tDamage);
 RakNet::BitStream wBitStream;
 wBitStream.Write(MessageID(ID_GODSPEAK));
 stringCompressor->EncodeString(tCaption.c_str(),512,&wBitStream);
 sendMyPlayers(server,&wBitStream, MEDIUM_PRIORITY, RELIABLE, 0, UNASSIGNED_SYSTEM_ADDRESS);
 }
 tReceiveBit.SetReadOffset(offset);
 }
 //Complete packet relay
 RakNet::BitStream tBitStream;

 tBitStream.Write(tMessage);
 tBitStream.Write(&tReceiveBit);

 broadcastInMap(tMapName, tDimension, server, &tBitStream, LOW_PRIORITY, RELIABLE, 0, UNASSIGNED_SYSTEM_ADDRESS);
}
break;

If you just want the changes. Added lines marked with color: https://github.com/jespersh/KITO/commit/dbbf86994ccfbd92b9a49ac37e56d271eae33688
Back to top Go down
GlaciaTheWolf
®
®
avatar

Game username : Glacia, GlaciaIceWolf, GlaciaTheWolf
Server : DD (member) Wolf soul (member)
Female Posts : 1001
Join date : 2013-12-09
Age : 21
Location : Ohio

PostSubject: Re: Infinit pvp??(Solved)   Sun Feb 08, 2015 9:53 pm

Got it thanks!!
Back to top Go down
Sponsored content




PostSubject: Re: Infinit pvp??(Solved)   

Back to top Go down
 
Infinit pvp??(Solved)
View previous topic View next topic Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
Keeping I.T. Open :: SUPPORT :: Support :: Solved Support Issues-
Jump to: