-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make outputMessage::addRawString available in Lua #93
Conversation
Why write msg:addU8(1); msg:addU8(0); msg:addU8(171); when you can instead write msg:addRawString("\x01\x00\x71"); ? Would make some lua scripts much easier to write :)
Ignoring the fact that this repo is no longer maintained... This is in no way better. |
@Oen44 in your opinion, is this code: msg:addRawString("\x0A\x00\x82\xFF\xFF\x41\x00\x00\x26\x0B\x00\x01"); better or worse than this code: msg:addU8(10)
msg:addU8(0)
msg:addU8(130)
msg:addU8(255)
msg:addU8(255)
msg:addU8(65)
msg:addU8(0)
msg:addU8(0)
msg:addU8(38)
msg:addU8(11)
msg:addU8(0)
msg:addU8(1) ? |
Worse. |
@Oen44 explain what it does with comments. Sometimes I record that the client sends a specific packet on a quest, don't have access to the server source code, don't know if it's actually comprised of U8 or U16's or U32's, don't really care, just know that on this specific part of the script, i need to send the exact packet |
Bullshit. Here is a BlackD Proxy script to buy manarunes and stack them on http://tibiafunevo.zapto.org :
|
Ah, you are here for botting, well, good luck! |
@Oen44 but do you see how difficult it is to port the blackd proxy script
to otcv8? the otcv8 equivalent is literally: local msg = OutputMessage.create()
msg:addU8(15)
msg:addU8(0)
msg:addU8(120)
msg:addU8(255)
msg:addU8(255)
msg:addU8(65)
msg:addU8(0)
msg:addU8(0)
msg:addU8(129)
msg:addU8(12)
msg:addU8(0)
msg:addU8(230)
msg:addU8(3)
msg:addU8(109)
msg:addU8(4)
msg:addU8(7)
msg:addU8(1)
g_game.getProtocolGame().send(msg) if we make outputMessage::addRawString() available, it would be trivial to port: local msg = OutputMessage.create()
msg:addRawString("\x0F\x00\x78\xFF\xFF\x41\x00\x00\x81\x0C\x00\xE6\x03\x6D\x04\x07\x01")
g_game.getProtocolGame().send(msg) |
If OTCv8 wish to maintain scripting compatibility with edubart/otclient, this should be merged. OutputMessage:addRawString has just been added to edubart/otclient, see edubart/otclient#1218 . |
Why write
when you can instead write
? Would make some lua scripts much easier to write :)