專業版肯定比個人版功能強大并且要穩定。增加了很多功能的同時也測驗封號的App,對于封號的App,給予剔除。雖然App數量減少了但是都是穩定的且收益比較高的。并且一天也就刷那么十幾個而已。專業版比較個人版增加了按照時間刷刷刷。同時每個app的時間可以設定,時間到達后自動進入下一個App。時間是一天之內的時間,也就是說一天之內不超過100分鐘,即使間斷執行程式也會按照設定時間執行。最后執行的時間就是100分鐘。
專業版增加清理快取的功能。每次看視頻結束后都會清理快取。這樣保證手機內容小的的福音。同時也是對老手機防卡的一個操作。
專業版增加自動評論功能,這個功能是最難的,操作很多且再輸入的時候經常出現錯誤,一般使用的輸入代碼是setText和Input。另外有的APP沒有評論功能。
專業版簽到較之前個人版簽到做了個大改版,每個App的簽到都和App刷刷放到了一起。無論是簽到、自動清理快取、自動答復都使用了wateFor函式。(其實要慎用)
專業版增加最實用的功能就是自動提現。目前提現的金額是最低額度。(接受定制)
專業版修復了一些bug,同時也增加了一些功能。如:
修復了點贊和關注的BUG
增加了點贊和關注功能的概率(個人版是將代碼寫成了硬代碼)
自動評論也增加了概率
專業版最大的改動其實是代碼的優化。對代碼做了整體規劃也采用了中文名稱。這樣對對于閱讀和修改都是非常便利的。看下截圖:
薅羊毛專業版用到技術頗多。因為打包成Apk肯定有和用戶互動的地方那也就意味著有UI界面。列舉一下技術有需要技術的也可以查看本檔案來復制代碼。
AutoJs UI技術。List、button、checkbox、input、swich等控制元件。
AutoJs UI技術復雜頁面布局。抽屜、headermenu、tab頁面、垂直布局、水平布局等。
Image圖示使用base64格式顯示。
AutoJs 懸浮框。
AutoJs 開啟無障礙權限代碼。
AutoJs 開啟懸浮窗權限代碼。
多執行緒。
Http訪問網路。
控制臺。
本地存盤。
按鍵模擬。
事件與監聽。
對話框。
設備資訊。
App常用函式。
先不吹牛技術了,咱們直接看薅羊毛個人版APP的截圖。如下:
這個是寫的JS腳本在AutoJs里面的效果。咱們看一看薅羊毛UI版的截圖。
薅羊毛首頁,Splash頁面。可以做很多東西……
薅羊毛配置頁面
前2項我就不多說了,友情提醒先開啟無障礙在開啟懸浮否則App會掛掉。
控制臺還是不建議開啟,有的App簽到會失敗。
是否開Toast提示,其實是無所謂的。
是否自動簽到,這個還是很意義的,之前我放自動刷的前面發現有的app會卡住,防止萬一我把簽到放到自動刷的后面了和清理記憶體一起
自動評論,在我看來整個app最難的就是這個,太難了…….另外不是所有的App都讓評論。
自動清理快取,整個說過了。
自動提現,目前都是最小金額。
執行天數,大于1天就行反正我們手機少,如果是作業室多幾天還行不過別指望無障礙玩作業室那樣你會很崩潰,
滑動螢屏間隔,這個我默認是8秒。
隨機概率,默認是十分之一,該不該無所謂吧,主要是隨機點贊、隨機關注、隨機評論、隨機上滑、隨機下滑。控制著幾個事件的隨機概率。
薅羊毛專業版系統頁面:
日志,我會將更新的日志發到這里
此版本將支持在線更新
教程還是我CSDN博客地址(以后會改)
關于就是著作權說明,強調一下,我之前發布的代碼有很多人轉載也沒寫著作權我就不追究了,如果有人利用我的原始碼和Apk檔案在網路上販賣我一定會追究。
退出……沒啥說的吧
接下來我把整個App比較難寫的地方寫貼出來給大家提個醒,可能你們認為不是問題。獻丑了不要見笑。之后我會將所有代碼求全部貼出。
部局的時候出現了點問題,一直找不到合理的部局且很難看(現在也不怎么好看)。后來在AutoJs中示例看到了復雜部局就學了一下,效果還可以吧。
代碼如下:
資料系結代碼:
function initializeFirstFrame() {
for (let i = 0; i < videoArray.length; i++) {
let appName = videoArray[i];
let signMessage = "未簽";
let signValue = getSignTime(appName);
let signColor = "#FF0000";
if (getDate() == signValue) {
signMessage = "已簽";
signColor = "#228B22";
}
//今日薅羊毛時間 1440 1400 1605-20=1585-1440=145-60=85-20=65-60
let execTimesMessage = "";
let key = appName + storageSign + getDate();
let havedRunTimes = woolStorage.get("" + key + "");
if (havedRunTimes == null) {
execTimesMessage = ("已刷:0分");
} else {
if (parseInt(havedRunTimes) < 1000 * 60) {
execTimesMessage = ("已刷時間小于1分鐘");
}
let havedMinute = (havedRunTimes / 1000) / 60;//讀取到的時間是毫秒需要轉換成秒,轉換成秒后在轉換成分鐘
execTimesMessage = ("已刷:" + havedMinute.toFixed(2) + "分");
}
if (appName == "微視") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "65", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "抖音極速版") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "30", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "快手極速版") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "180", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "火山極速版") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "120", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "閃電盒子極速版") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "50", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "歡樂盒子") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "50", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "火火視頻極速版") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "120", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "刷寶短視頻") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "60", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "彩蛋視頻") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "120", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "快音") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "120", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "中青看點") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "100", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "趣鈴聲") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "120", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "愛走路") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "120", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "閃鴨短視頻") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "60", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else if (appName == "長豆短視頻") {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "80", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
} else {
let row = { SignColor: signColor, AppName: videoArray[i], AppIndex: (i + 1), ExecTimes: "15", IsSign: signMessage, done: false, ExecTimesMessage: execTimesMessage };
videoItems.push(row);
}
}
ui.videoList.setDataSource(videoItems);
//小視頻系結check事件 火火視頻極速版 長豆短視頻
ui.videoList.on("item_bind", function (itemView, itemHolder) {
itemView.done.on("check", function (checked) {
let item = itemHolder.item;
item.done = checked;
let appName = item.AppName;
let appIndex = itemView.appIndex.getText();
item.AppIndex = appIndex;
item.ExecTimes = itemView.execTimes.getText();
let brushTimes = itemView.execTimes.getText();
if (checked) {
havedVideoChecked.put(appName, appIndex);
havedVideoTimes.put(appName, brushTimes);
} else {
havedVideoChecked.remove(appName);
havedVideoTimes.remove(appName);
}
});
});
ui.videoList.on("item_click", function (item, i, itemView, listView) {
itemView.done.checked = !itemView.done.checked;
});
}
保存配置采用的是storage,這個是不安全的只要知道名稱就可以訪問,敏感資料不建議使用它。保存配置代碼:
ui.btnSaveWoolConfig.click(function () {
woolStorage.put("isShowConsole", "" + ui.switchIsShowConsole.isChecked() + "");
woolStorage.put("timesInterval", "" + ui.txtScreenSileTimesInterval.getText() + "");
woolStorage.put("IsAutoSign", "" + ui.switchIsAutoSign.isChecked() + "");
woolStorage.put("IsClearCache", "" + ui.switchIsClearCache.isChecked() + "");
woolStorage.put("IsCashOut", "" + ui.switchIsCashOut.isChecked() + "");
woolStorage.put("IsAutoComment", "" + ui.switchIsAutoComment.isChecked() + "");
woolStorage.put("IsShowToast", "" + ui.switchIsShowToast.isChecked() + "");
woolStorage.put("ForeachDays", "" + ui.txtForeachDays.getText() + "");
//txtForeachDays
toast("薅羊毛專業版配置保存成功!");
});
具體業務代碼在我之前的文章里面已經寫過了,我現在把完整代碼貼一下,服務器資訊是我的大家別亂搞就好了哈
轉載請註明出處,本文鏈接:https://www.uj5u.com/houduan/99275.html
標籤:Java相關
