Post Pacific

Post Pacific (https://postpacific.mmorpg-game.online/index.php)
-   Lineage 2 General (https://postpacific.mmorpg-game.online/forumdisplay.php?f=31)
-   -   C4 CacheD, 2012 port commands (https://postpacific.mmorpg-game.online/showthread.php?t=5371)

khelben 06.04.2007 17:15

Ban

UPDATE user_account SET block_flag = 1,block_flag2 = 1 WHERE account='dumbass'

Unban

UPDATE user_account SET block_flag = 0,block_flag2 = 0 WHERE account='dumbass'

if you really really want to use cacheD commands try your cacheD command for 0 min. That's the only way i can get it to unban other than modifying the sql table.

FidoW 06.04.2007 17:35

That works for me

PHP Code:

#20 DisableCharacterPacket("ddS")
function DisableCharacterPacket($char_id) {
    
$buf = pack("c", 20);
    
$buf .= pack("i", $char_id);
    
$buf .= pack("i", 1);
    return 
CacheDInteractive($buf);
}

#21 EnableCharacterPacket("ddS")
function EnableCharacterPacket($char_id, $account_id) {
    
$buf = pack("c", 21);
    
$buf .= pack("i", $char_id);
    
$buf .= pack("i", $account_id);
    return 
CacheDInteractive($buf);
} 


FidoW 06.04.2007 17:37

My function CacheDInteractive... is better than try to connect to the server in each function...

PHP Code:

function CacheDInteractive($buf) {
    
$fp = fsockopen("127.0.0.1", "2012", $errno, $errstr, 5); 
    
$rs = "x";
    if (!
$fp) die("Error conectando con CacheD: [Server OFF?]");
    
    
fwrite($fp, pack("s", (strlen($buf)+2)).$buf);
    
$len = unpack("v", fread($fp, 2)); 
    
$rid = unpack("c", fread($fp, 1));
    for (
$i = 0; $i < (($len[1]-4) / 4); $i++) { 
      
$read = unpack("i", fread($fp, 4)); 
      
$rs .= $read[1]; 
    }
    
fclose($fp); 
    return(
$rs);
} 


SilverCloud 06.04.2007 21:41

These commands are only available when the character is offline right? If so, thats too bad.. I was about to create an auction site (php). Second, is it possible to check if a char is online?

FidoW 06.04.2007 21:58

Quote:

Originally Posted by SilverCloud (Post 83106)
These commands are only available when the character is offline right? If so, thats too bad.. I was about to create an auction site (php). Second, is it possible to check if a char is online?

You can check if player is online with this function...
PHP Code:

#1 CheckCharacterPacket("dS")
function CheckCharacterPacket($char_id) {
    
$buf = pack("c", 1);
    
$buf .= pack("i", $char_id);
    return 
CacheDInteractive($buf);
} 


But always you can kick him first and problem solved.
PHP Code:

#5 KickCharacterPacket("dS")
function KickCharacterPacket($char_id) {
    
$buf = pack("c", 5);
    
$buf .= pack("i", $char_id);
    return 
CacheDInteractive($buf);
} 


scrap512 12.04.2007 19:33

Can't get additem2 to work even. itemdata and cache are both in the cached script folder :-/ any other suggestions?

zabr 23.04.2007 11:56

has anybody make php function to add skill to char?

adriahu 23.04.2007 12:39

Quote:

Originally Posted by zabr (Post 84496)
has anybody make php function to add skill to char?

function fragment :)
PHP Code:

$buf=pack("cVVV",6,$char_id,$skill_id,$skill_level).tounicode("admin");
$cachedsocket=@fsockopen($cached_ip,$cached_port,$errno,$errstr,1) or die("error");
fwrite($cachedsocket,pack("s",(strlen($buf)+2)).$buf);
$len=unpack("v",fread($cachedsocket,2));$rid=unpack("c",fread($cachedsocket,1));
for(
$i=0;$i<(($len[1]-4)/4);$i++){$read=unpack("i",fread($cachedsocket,4));$rs.=$read[1];}
fclose($cachedsocket); 


zabr 24.04.2007 04:34

tnx will try :)

Charis 15.05.2007 09:24

Quote:

Originally Posted by FidoW (Post 83095)
That works for me

PHP Code:

#21 EnableCharacterPacket("ddS")
function EnableCharacterPacket($char_id, $account_id) {
    
$buf = pack("c", 21);
    
$buf .= pack("i", $char_id);
    
$buf .= pack("i", $account_id);
    return 
CacheDInteractive($buf);
} 


Does EnableCharacter works correct for you?
I have the same one, but it places in account_id unsigned -2 (somesing like 65K o_O).

What is wrong????

l2russia 17.06.2007 15:36

ChangePledgeOwnerPacket
37 clan_id char_id unicode(admin)
выдает 1 при подходящих данных, при неверных 024
но абсолютно ничего не происходит.

FidoW 17.06.2007 15:45

Quote:

Originally Posted by l2russia (Post 88881)
ChangePledgeOwnerPacket
37 clan_id char_id unicode(admin)
выдает 1 при подходящих данных, при неверных 024
но абсолютно ничего не происходит.

Estoy de acuerdo (?)

Guaresnay 19.06.2007 22:35

Quote:

Originally Posted by FidoW (Post 88883)
Estoy de acuerdo (?)

claro es la unica forma (?)

xly99168 22.06.2007 21:30

what is format ?
#2 SetCharacterLocationPacket("dddddS")

char_id, location_X, location_Y, Location_Z, ???????, admin

who can help ????

Write sample please...

Kenjiro 23.06.2007 12:19

Try: SetCharacterLocationPacket, char_id, 1, x, y, z, unicode(admin)

P.S. Look in cached 'system' and 'err' logs, it usually shows you what is wrong.

xly99168 28.06.2007 16:52

test success.....

very THX!

xly99168 02.07.2007 00:35

about #50 ManAnnouncePacket("ddSS")????

Why arsy-varsy code after I write chinese on announce? But english is well.....

english 2byte = chinese 1byte

xly99168 10.07.2007 18:36

about ChangePledgeOwnerPacket
37 clan_id char_id unicode(admin) ????

37 to_char_id pledge_id is error....
37 pledge_id to_char_id is error too....

then ..... ?

xly99168 10.07.2007 18:37

cached 'system' and 'err' logs, it not shows me what is wrong.

Kenjiro 23.07.2007 13:00

ChangePledgeOwnerPacket is not working through cached :/

djvogans 24.07.2007 08:31

not working in c1 modded cached . in retail cached it's working fine .

Kenjiro 24.07.2007 17:47

I'm using file 'cached.exe' size '1 540 096' from c4retailpack. It is not working for me same as PledgeDeletePacket.

xly99168 28.07.2007 20:16

Quote:

Originally Posted by Kenjiro (Post 92540)
ChangePledgeOwnerPacket is not working through cached :/


me too, and PledgeDeletePacket is not working too....

Forcer 29.07.2007 08:48

Indeed, me too.

xly99168 07.08.2007 18:12

UP. who can help ?


All times are GMT. The time now is 17:21.