forked from hafat/hafat.github.io
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathredive_cheat_report.html
113 lines (103 loc) · 5.49 KB
/
redive_cheat_report.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Re:Dive Cheat Report</title>
</head>
<body style="font-family: Courier; font-size:16px;">
<div style="white-space: pre-wrap;font-family: Courier;"> 圖片質素(1最高):<input id="compress_rate" type="number" max="1" min="0.1" step="0.05" value="0.7"/>
1. 資料提供者九碼ID: <input onchange="output(my_id,this.value)"/>
2. 外掛玩家九碼ID: <input onchange="output(cheat_id,this.value)"/>
3. 伺服器名稱: <select onchange="output(server_name,this.value)">
<option></option>
<option value="美食殿堂">美食殿堂</option>
<option value="真步真步王國">真步真步王國</option>
<option value="破曉之星">破曉之星</option>
<option value="小小甜心">小小甜心</option>
</select>
4. 舉報確切時間: <input type="date" onchange="output(the_date,this.value.toString())"/> <input type="time" onchange="output(the_time,this.value.toString())"/>
5. 使用於遊戲內何項目: <select onchange="output(game_item,this.value)">
<option></option>
<option value="戰鬥競技場">戰鬥競技場</option>
<option value="公主競技場">公主競技場</option>
<option value="對戰異常">對戰異常</option>
<option value="推圖檢舉">推圖檢舉</option>
</select>
6. 您為攻擊方/防守方: <select onchange="output(my_state,this.value)">
<option></option>
<option value="攻擊方">攻擊方</option>
<option value="防守方">防守方</option>
</select>
7. 被舉報的玩家的相關截圖:為避免附檔過大及惡意病毒,還請附截圖即可。
個人資訊 <input type="file" onchange="output_img(cheat_info,this.files)" multiple/>
個人進度 <input type="file" onchange="output_img(cheat_progress,this.files)" multiple/>
傷害報告截圖 <input type="file" onchange="output_img(vs_report,this.files)" multiple/>
對戰紀錄詳細資訊 <input type="file" onchange="output_img(vs_detail,this.files)" multiple/>
8. 詳細狀況描述: <input list="detail_list" onchange="output(detail,this.value)" />
<datalist id="detail_list">
<option value="重播都是我勝利">
<option value="通關進度不合理">
</datalist>
以上資訊缺一不可,同時如您所回報的為公主競技場,每一場的傷害報告截圖皆須附上
<hr />
信箱: <span id="redive_mail">[email protected]</span> <button onclick="copyText(redive_mail)">Copy</button>
標題: <span id="subject">外掛檢舉</span> <button onclick="copyText(subject)">Copy</button>
</div>
<!-- -->
<div id="print_data" style="white-space: pre-wrap;font-family: Courier" contenteditable="true">1. 資料提供者九碼ID: <span id="my_id"></span><br>2. 外掛玩家九碼ID: <span id="cheat_id"></span><br>3. 伺服器名稱: <span id="server_name"></span><br>4. 舉報確切時間: <span id="the_date"></span> <span id="the_time"></span><br>5. 使用於遊戲內何項目: <span id="game_item"></span><br>6. 您為攻擊方/防守方: <span id="my_state"></span><br>7. 被舉報的玩家的相關截圖:<br>個人資訊:<br><span id="cheat_info">個人進度:</span><br><span id="cheat_progress">傷害報告截圖: </span><br><span id="vs_report">對戰紀錄詳細資訊:</span><br><span id="vs_detail">8. 詳細狀況描述:</span> <span id="detail"></span>
</div>
<button onclick="copyText(print_data)">Copy Text</button>
<button onclick="download_as_HTML()">Download As HTML</button>
<script>
var print_data = document.getElementById("print_data");
var my_id = document.getElementById("my_id");
var cheat_id = document.getElementById("cheat_id");
var server_name = document.getElementById("server_name");
var the_date = document.getElementById("the_date");
var the_time = document.getElementById("the_time");
var game_item = document.getElementById("game_item");
var my_state = document.getElementById("my_state");
var cheat_info = document.getElementById("cheat_info");
var cheat_progress = document.getElementById("cheat_progress");
var vs_report = document.getElementById("vs_report");
var vs_detail = document.getElementById("vs_detail");
var detail = document.getElementById("detail");
var redive_mail = document.getElementById("redive_mail");
var subject = document.getElementById("subject");
var compress_rate = document.getElementById("compress_rate");
function output(row,data){
row.innerHTML = data;
}
function output_img(row,data){
for(var i=0; i<data.length;i++){
let reader = new FileReader();
reader.readAsDataURL(data[i]);
reader.onload = ()=>{
let image = new Image();
image.src = reader.result;
image.onload = function(){
let canvas = document.createElement('canvas');
let ctx = canvas.getContext('2d');
canvas.width = image.width;
canvas.height = image.height;
ctx.drawImage(image, 0, 0);
let compressed_image = canvas.toDataURL('image/jpeg', parseFloat(compress_rate.value));
row.insertAdjacentHTML("beforebegin", `<img src=${compressed_image} /><br />`)
};
};
}
}
function copyText(ele) {
window.getSelection().selectAllChildren(ele);
document.execCommand("copy");
}
function download_as_HTML(){
var link = document.createElement('a');
link.setAttribute('download', "redive_cheat_report.html");
link.setAttribute('href', 'data:text/html;charset=utf-8,' + encodeURIComponent(`<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> </head>`+print_data.outerHTML));
link.click();
}
</script>
</body>
</html>