Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Conquer Online 2 > CO2 Private Server
You last visited: Today at 10:45

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

Advertisement



need a smart idea for portable wh

Discussion on need a smart idea for portable wh within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old 09/02/2014, 15:14   #16
 
elite*gold: 67
Join Date: Aug 2014
Posts: 1,323
Received Thanks: 928
Quote:
Originally Posted by abdoumatrix View Post
just making sure cuz when i tried to send the packet it take the nearest npcuid and send it in warehousepacket
That is a kinda stupid approach im my head. But if it works reliably its ingenius!
Xio. is offline  
Old 09/02/2014, 23:32   #17
 
turk55's Avatar
 
elite*gold: 130
Join Date: Oct 2007
Posts: 1,655
Received Thanks: 706
Quote:
Originally Posted by abdoumatrix View Post
just making sure cuz when i tried to send the packet it take the nearest npcuid and send it in warehousepacket
It isn't hard to figure out which one is the closest though. Here is a quick thought on how to approach it:

A list or dictionary with warehouse npcs including their locations (mapid, x, y)
Loop through the npcs that are in the same map and calculate the distance ->
((x1 - x2) * (x1 - x2)) + ((y1 - y2) * (y1 - y2))
turk55 is offline  
Old 09/02/2014, 23:41   #18
 
abdoumatrix's Avatar
 
elite*gold: 0
Join Date: Jul 2008
Posts: 874
Received Thanks: 238
Quote:
Originally Posted by turk55 View Post
It isn't hard to figure out which one is the closest though. Here is a quick thought on how to approach it:

A list or dictionary with warehouse npcs including their locations (mapid, x, y)
Loop through the npcs that are in the same map and calculate the distance ->
((x1 - x2) * (x1 - x2)) + ((y1 - y2) * (y1 - y2))
xD client does this not server

that what happen with me when i tried to open warehouse interface with datapacket it send me a warehouse packet with npcid of the nearest npc.

maybe it just some luck i will test again to make sure

========

nah i was wrong.

1. first u talk with npc
2. u use datapacket to open warehouse interface
3. the warehousepacket will be send with the lastest npcid u talk with.

so u can use a portable warehouse like this

1. summon itembox npc with item or whatever u want
2. from its npcdialogpacket u forced it to open warehouse interface
(u can use it too in option removing it)
3. the warehouse packet will send with this npc uid and the rest is easy.
abdoumatrix is offline  
Old 09/03/2014, 08:12   #19
 
elite*gold: 0
Join Date: Jun 2014
Posts: 69
Received Thanks: 13
okay it's about time to give some updated

couldn't find postCmd parameter for the sash gui, did test 0->3500

Quote:
The client doesn't need to know what warehouse it is as long as the server knows.
it does because the client doesn't have an event on closing a wh so the server will never know if the user closed the wh or not
i have a way around that but won't work with vip wh as it will keep sending a new 1102 packet everytime the user change his wh to another city wh also normal wh will not send a packet if no npc where clicked since login

if what i've just said didn't make sense then please give me a valid example to make it work

Quote:
summon itembox npc with item or whatever u want
that would get it done but it looks gay to click npc dialog to summon an itembox to click it to show the wh, kinda gay isn't it ?
OverKillasdwqe is offline  
Old 09/03/2014, 13:38   #20
 
abdoumatrix's Avatar
 
elite*gold: 0
Join Date: Jul 2008
Posts: 874
Received Thanks: 238
Quote:
Originally Posted by OverKillasdwqe View Post
okay it's about time to give some updated

couldn't find postCmd parameter for the sash gui, did test 0->3500


it does because the client doesn't have an event on closing a wh so the server will never know if the user closed the wh or not
i have a way around that but won't work with vip wh as it will keep sending a new 1102 packet everytime the user change his wh to another city wh also normal wh will not send a packet if no npc where clicked since login

if what i've just said didn't make sense then please give me a valid example to make it work



that would get it done but it looks gay to click npc dialog to summon an itembox to click it to show the wh, kinda gay isn't it ?
xD no u press the item ,the item summon the itembox

u try to talk with the itembox
1. it open the warehouse gui for u
2.send u messagebox for if u want to remove it
abdoumatrix is offline  
Reply




All times are GMT +1. The time now is 10:47.


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.