nzzrin
-
Posts
19 -
Joined
-
Last visited
Posts posted by nzzrin
-
-
Forgot to close out. Set another } at the end
Thanks, code my code it's working now. But it seems I'm facing another problem.
Quote fro Stackoverflow
If the key does not exist in the user defaults, the result of this method will be NO.I'm facing this issue now. I think /Library/PreferenceBundles/yourtweak.bundle/yourplistname.plist can't be read by Preference.
-
-(bool)istargetmethodActive{ if ([[prefs objectForKey:@"keyFromPlist"] boolValue]){ return true; } else { return %orig; } %endGot this error while processing to package...
Tweak.xm:46: error: %end does not make sense inside a block
-
try with 'else {'
Where do I put that code? Because -(bool) can't run without "return".
-
istargetmethodActive is case sensitive, have you copied it correctly?
Yes. I'm 100% sure and confident. I just want a simple workflow:
1. User turn the switch OFF = The tweak is not working.
2. User turn the switch ON = The tweak is working.
Unfortunately, nothing seems to work according my plan.
-
I don't think you understood me.

Yes I am, but nevermind. I'm compiling using mac now. But I'm facing new issue regarding the code : here
-
%hook targetClass -(bool)istargetmethodActive{ if ([[prefs objectForKey:@"keyFromPlist"] boolValue]){ return true; } return %orig; } %endI've tried running and make countless changes but the results is still the same. The problem is, when I try On or Off my tweak via Preference (in Settings app), the code keep return %orig;
Please help.
-
Tried your tutorial 1 by 1 but got error while compling the code.
<Preferences/Preferences.h> missing.
compiling using Theos via mac OS X yosemite 10.10.
-
Just copy paste the content, no need to upload it.
***BEFORE make package RUN*** obj | folder type theos | folder type control | file type Makefile | file type tinderplus.plist | file type Tweak.xm | file type
***AFTER make package RUN*** control.tar.gz data.tar.xz
-
-
Open your /theos/makefiles/package/deb.mk
Edit Line 33 to this:
$(ECHO_NOTHING)COPYFILE_DISABLE=1 $(FAKEROOT) -r dpkg-deb -Zgzip -b "$(THEOS_STAGING_DIR)" "$(_THEOS_DEB_PACKAGE_FILENAME)" $(STDERR_NULL_REDIRECT)$(ECHO_END)
Recompile the deb and reinstall.Thanks for your tips, but I've got this error:
bash-3.2# make package messages=yes Making all for tweak tinderplusmac... /Applications/Xcode.app/Contents/Developer/usr/bin/make -f Makefile --no-print-directory --no-keep-going \ internal-library-compile \ _THEOS_CURRENT_TYPE=tweak THEOS_CURRENT_INSTANCE=tinderplusmac _THEOS_CURRENT_OPERATION=compile \ THEOS_BUILD_DIR="." _THEOS_MAKE_PARALLEL=yes make[2]: Nothing to be done for `internal-library-compile'. rm -rf "/Users/Nazrin/tinderplusmac/.theos/_" /Users/Nazrin/tinderplusmac/theos/bin/fakeroot.sh -p "/Users/Nazrin/tinderplusmac/.theos/fakeroot" -c mkdir -p "/Users/Nazrin/tinderplusmac/.theos/_" [ -d layout ] && rsync -a "layout/" "/Users/Nazrin/tinderplusmac/.theos/_" --exclude "DEBIAN" --exclude "_MTN" --exclude ".git" --exclude ".svn" --exclude ".DS_Store" --exclude "._*" || true Making stage for tweak tinderplusmac... mkdir -p "/Users/Nazrin/tinderplusmac/.theos/_/Library/MobileSubstrate/DynamicLibraries/" cp ./.theos/obj/tinderplusmac.dylib "/Users/Nazrin/tinderplusmac/.theos/_/Library/MobileSubstrate/DynamicLibraries/" if [ -f tinderplusmac.plist ]; then cp tinderplusmac.plist "/Users/Nazrin/tinderplusmac/.theos/_/Library/MobileSubstrate/DynamicLibraries/"; fi mkdir -p "/Users/Nazrin/tinderplusmac/.theos/_/DEBIAN" sed -e '/^[Vv]ersion:/d' "/Users/Nazrin/tinderplusmac/control" > "/Users/Nazrin/tinderplusmac/.theos/_/DEBIAN/control" echo "Version: 5.0.1-4" >> "/Users/Nazrin/tinderplusmac/.theos/_/DEBIAN/control" echo "Installed-Size: 120" >> "/Users/Nazrin/tinderplusmac/.theos/_/DEBIAN/control" COPYFILE_DISABLE=1 /Users/Nazrin/tinderplusmac/theos/bin/fakeroot.sh -p "/Users/Nazrin/tinderplusmac/.theos/fakeroot" -r dpkg-deb —Zgzip -b "/Users/Nazrin/tinderplusmac/.theos/_" "./com.nazrin.tinderplusmac_5.0.1-4_iphoneos-arm.deb" dpkg-deb: error: need an action option Type dpkg-deb --help for help about manipulating *.deb files; Type dpkg --help for help about installing and deinstalling packages. make: *** [internal-package] Error 2
-
The picture is not working. Copy paste the output.
Sorry I can't copy the error code from [/size]mobileterminal. But here's the i[/size]mage with the new host site. [/size]

make package install: dpkg-deb: file `/tmp/_theos_install.deb' contains ununderstood data member data.tar.xz , giving up
-
You need to copy and paste the error message here in order for us to help.
Here's the results:
-
Now I'm using Theos via mac Terminal. Success in making the .deb file.
Unfortunately failed when I tried to install .deb file via iFile.
Error :
Finished with Result Code : 256 -
You are compiling /var/mobile/projects/tinder
Try compiling a file from /var/mobile/tinder
When making a project it should go to the second location, IDK why yours went to projects, I might be wrong
It is because I put my tweak inside Projects folder.
Tried to move and create the tweak inside /var/mobile but still no luck.
Same error. Error 126, many suggesstions I've tried. Stuck with the same error.
-
Make sure you're doing it right. The error is because of that.
"make package" still got no luck. Still got the same error. Error 126.
Already copied Perl file from usr/local/bin to usr/bin and running nic again, but failed.
-
Also when you do the above, try typing "make package"
Tried this before. Still got "Error 126".
No .deb file generated.
-
Try to make package my tested tweak. But failed.
iOS 8.3
iPhone 5
Results when running "make package messages=yes"

-
1
-
-


Code keep return %orig;
in Help & Support
Posted