LewsTherinTelescope

Members
  • Content Count

    109
  • Joined

Everything posted by LewsTherinTelescope

  1. OK, thanks. Is the NUL separate from the cell terminator ([other cell] NUL NUL NUL [other cell]), or do I just leave the data blank ([other cell] NUL NUL [other cell]? And is the data section null terminated or delimited (is there a NUL ending the file)? Thanks for the code, I'll try to get that to regular Java and test it. My editor has separate encodings for ASCII and UTF-8, so the binary data is probably just messing things up.
  2. Except I have 32 extra lines, and that would only allow for one (also, my editor uses Unix newlines, not Windows), because the offset would increase when writing the next number. I haven't tested it with dummy data, only with an actual mod, so I'll see if maybe it is different on Android, or maybe wy other code messes with it?
  3. OK, thanks! I'd use a ByteBuffer with a length of two, correct? And then four for row count, since it is 32 bit?Looking at the Jade Empire Modding wiki, the column names are ASCII, so I'm assuming the rest of the text is too. And I need to replace empty cells with "****", correct? Or does the binary 2DA not use that? My current code for offsets: short offset = 0; // Stores the offset ByteBuffer offsetLE = ByteBuffer.allocate(2).order(LITTLE_ENDIAN).putShort(offset); // Must be little endian for (int i = 0; i < this.data.length; i++) { // Loop through rows for (int j = 0; j < this.data[i].length; j++) { // Loop through columns fos.write(offsetLE.array()); // Write offset String cell = (String) data[i][j]; // Cast to String offset += cell.getBytes().length; // Add length to offset offsetLE.putShort(0, offset); // Update ByteBuffer } } fos.write(new byte[]{NUL,NUL}); // Terminate offsetsFor some reason, writing the offsets is adding a bunch of newlines to the file. Any idea what could cause that?
  4. Got it. So I need to convert header, data, and labels to ASCII one byte? And I need to make the row count little endian as well? EDIT: Is it plain ASCII, or one of the extensions? My text editor is recognizing it as UTF-8, but obviously it's not a plain text file, so it might be messing up.
  5. Thanks! I saw that code already when looking at your TwoDABroker.java, but explanation helps. I'm using your code to read them, what I'm trying to do is calculate and write them when saving changes. Do you know if I need to convert everything to little endian, or just numbers?
  6. Thanks, so would I just probably getBytes() and add that length to the offset for the next one, and start at 0? I think DataOutoutStream has an option to write a short.
  7. I know they're 16 bit integers, but are they the number of bytes into the data section, or what? And is there any delimiting character, or since they're all the same size, do I just put one right after the other? And lastly, I would use a short to represent one in Java, correct?
  8. Pretty sure I have 2DA editing done, once I figure out how to write it to a file, I'll double check, and should release the next update! After that, I'll focus on namespaces, then other stuff. School starts back up tommorow (well, technically it'll be today in an hour... I need sleep) though, so I won't have as much time.
  9. Looks nice! How much did you decrease the explosion/stun radius?
  10. Will part of that include updating the https certificate? It's been expired for a really, really long time. Thanks for the warning.
  11. (OK sorry about necro [and previous one]), but ffmpeg output for a random strreamwave is: $ ffmpeg -i ba02cs001.wav ffmpeg version 3.4.1 Copyright (c) 2000-2017 the FFmpeg developers built with Android clang version 5.0.300080 (based on LLVM 5.0.300080) configuration: --arch=armeabi-v7a --as=arm-linux-androideabi-clang --cc=arm-linux-androideabi-clang --cxx=arm-linux-androideabi-clang++ --cross-prefix=arm-linux-androideabi- --disable-avdevice --disable-ffserver --disable-static --disable-symver --disable-lzma --enable-cross-compile --enable-gnutls --enable-gpl --enable-libmp3lame --enable-libvorbis --enable-libopus --enable-libx264 --enable-libx265 --enable-libxvid --enable-libvpx --enable-shared --prefix=/data/data/com.termux/files/usr --target-os=android --extra-libs=-landroid-glob --enable-neon libavutil 55. 78.100 / 55. 78.100 libavcodec 57.107.100 / 57.107.100 libavformat 57. 83.100 / 57. 83.100 libavfilter 6.107.100 / 6.107.100 libswscale 4. 8.100 / 4. 8.100 libswresample 2. 9.100 / 2. 9.100 libpostproc 54. 7.100 / 54. 7.100 [wav @ 0xb4f3b000] Estimating duration from bitrate, this may be inaccurate Guessed Channel Layout for Input Stream #0.0 : mono Input #0, wav, from 'ba02cs001.wav': Duration: 00:00:00.48, bitrate: 177 kb/s Stream #0:0: Audio: pcm_u8 ([1][0][0][0] / 0x0001), 22050 Hz, mono, u8, 176 kb/s At least one output file must be specified
  12. I hate when two mods have the same file, but in a different case, so no error shows up and I have to check my entire override for conflicts...

    1. DarthParametric

      DarthParametric

      Linux or Mac I take it? It's a non-issue on Windows, so most modders would never even know it's a potential source of conflict.

    2. LewsTherinTelescope

      LewsTherinTelescope

      Android. So of course there's a lot more issues with mods than that, but it's such a simple thing that spending so much time on it is really annoying. I know Windows is case-insensitive, I hate this sort of silly OS conflict.

  13. Good thing KOTOR and TSL awards are merged, because otherwise N-DReW25 would be guaranteed to win 2 awards not just one (though maybe he'd prefer that )
  14. Thanks, awesome, I'll look at that. The thing is, since my project is GPL licensed, I think the code needs to be under an open license, not just with permission. (Not a lawyer, so not 100% sure).
  15. Update a1.1.0 Changelog in OP I changed the signing key for releases from the default debug key, so you must uninstall and reinstall. Debug builds are not affected. You can use the new file chooser to select the TSLPatcher.exe file in the same directory as the tslpatchdata (NOT a file in the tslpatchdata itself). Updates are NOT automatic, you must choose the Check for update menu item. If you have downloaded a debug build for this update, checking for updates will fetch the latest debug build, which I upload as soon as I get a functional build, and are signed with the default android debug key. (I wouldn't reccommed them.) Release builds are uploaded once I feel it deserves an update, and are signed with my key. You cannot install one over the other, you must uninstall to switch. The letter before the version number (like a in a1.1.0) stands for alpha, beta or release. Alpha is what I am calling all builds until I complete 2DA support. After that, builds will be called beta. Release will be once all features are added or marked will not add. I was told by DrMcCoy on GitHub that due to a problem with the build script, compiling xoreos-tools statically would mean recompiling Boost, which I can't/have no clue how to do (see the GitHub issue for details), so I am starting work on b1.0.0 hopefully this weekend, and will just use dynamic builds (and ship a bunch of libraries, which is why I hoped for static, but it'll at least work).
  16. Unrelated, but is there a way to disable code block coloring? And why don't newlines stick in code blocks? Do I need to do \n or something?
  17. So far, this app is very basic, and lacks most of TSLPatcher's features. The only thing it currently can do is copy files from tslpatchdata to the proper folders, and patch 2DA files. However, I plan to try to add more features from TSLPatcher. You can download the latest release version of the app here, or contribute here. The app is licensed under the GPLv3 (not 3+, just 3). For more details, press the licenses button in-app, or look on the source repo. Bugs: • Buttons in menu have no margin • Please report! Features: • Copying files... ✔ • Editing 2DAs... ✔ • Editing TLKs... ❌ • Editing GFFs... ❌ • Editing MODs... ❌ • File selector... ✔ • Namespaces... ❌ • Show info.rtf... ❌ • Other TSLPatcher features?... ❌ Changelog: b1.1.0 {146} • Theme UI • New launcher icon • Changed minimum API level from 14 to 7 BTS: • Switch from MarkdownView to txtmark • Moved files from assets to raw resources • No longer uses Xdroid.Toaster • Now uses AppCompat support library and VectorDrawables • Switch from official aFileChooser to Zhuowei Zang's version
  18. I was browsing through the forum pages on the web archive, and found the tester list here. Archive.org actually has a bunch of threads saved (not a ton of stuff, but maybe someone might be interested) here.
  19. EDIT: No longer compiling anything, I haven't used or even thought of this for months. Note: I am not affiliated with the xoreos team in any way, this was just because I was using this for a bit and decided to share it. I've compiled xoreos-tools for armv7, and collected all the necessary libraries, and packaged them all into a .deb package for Termux (a really cool terminal for Android). You can install it in Termux (will not work on Debian or Ubuntu) by running wget https://gitlab.com/PorygonZRocks/xoreos-tools-termux/raw/master/xoreos-tools-termux_armhf_0.0.5.1_arm.deb && apt install ./xoreos-tools-termux_armhf_0.0.5.1_arm.deb . After doing that, you also need to install an app I made, because the xoreos-tools require the file "/lib/ld-linux.so.3". I've hex edited it to another path, but Termux home is too long, so I had to make an app with a really short package name. (Apk coming soon.) EDIT: Apk uploaded here. The source for my deb is here. Also, the package includes a bunch of man pages with licenses, run "man xoreos-tools-termux-sources" to see more. The tools also come with man pages, run "man [tool]" to see how to use it. The source for my app is here. I've put this under WIP instead of general because I'm hoping that I can get arm(el/v6), x86 and x64 (maybe MIPS, anybody know if KOTOR for Android supports MIPS?), so that it works for all devices. Currently, I only have armhf/armv7. I need a /lib/ld-linux.so* from each arch (I think MIPS is /lib/ld.so*), and xoreos-tools compiled, and all the libs (see source for list) used (xoreos-tools provides x86 and x64 binaries, if anybody could run ldd on them and let me know, it would help.) Since these are just tools, you have to still manually do things like editing, but it's a lot easier using text and XML (still hard). Note that after editing, you do NOT need to convert 2das back (KOTOR can parse plaintext 2das), but you DO need to convert back all other formats, like tlk or gff. I mainly did this for convert2da, but the others could help, and I thought I'd share it. Also, hopefully, someone more skilled than I might be able to make some sort of tool that will automatically edit. EDIT: Sorry, after installing the deb, thentools area not set executable. Run "chmod -R 755 ~/../usr/bin/" to fix that, I'll see what I can do in the deb.
  20. Character Startup Changes (to install, you have to copy all the "new*.2da" files and remove the "new" part [ex copy "newskills.2da" and then rename it to "skills.2da"])
  21. What lightsaber is that?Also, you said you think you fixed it. Didn't you have to revert to an old version? Maybe you didn't have the fix in this version.