Skip to content
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

Add async encode/decodeString #1226

Merged
merged 4 commits into from Jan 24, 2020
Merged

Conversation

StrixG
Copy link
Contributor

@StrixG StrixG commented Jan 24, 2020

string encode/decodeString(string algorithm, string input, table options[, function callback])

Example of decoding car txd:

function decodeCallback(txdData)
  txd = engineLoadTXD(txdData)
  engineImportTXD(txd, 411)
end

local txdFile = fileOpen("car.txd")
if txdFile then
  local buffer = fileRead(txdFile, fileGetSize(txdFile))
  decodeString(buffer, "tea", {key = "TxdKey105"}, decodeCallback)
end
fileClose(txdFile)

@CrosRoad95 CrosRoad95 added the enhancement New feature or request label Jan 24, 2020
@Woovie Woovie marked this pull request as ready for review January 24, 2020 13:28
Copy link
Contributor

@qaisjp qaisjp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested, works great. Thank you!

@qaisjp qaisjp changed the title Async encode/decodeString Add async encode/decodeString Jan 24, 2020
@qaisjp qaisjp merged commit 273a87a into multitheftauto:master Jan 24, 2020
@qaisjp qaisjp added this to the 1.6 milestone Jan 24, 2020
@Citizen01
Copy link
Member

This PR made me remember of this issue instantly: #1152
I guess it applies on this one too ?

@StrixG StrixG deleted the async-encryption branch January 25, 2020 09:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants