-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmonpoc_printable.htm
115 lines (105 loc) · 2.66 KB
/
monpoc_printable.htm
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
114
115
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Untitled</title>
<style>
* {
margin: 0;
padding: 0;
}
.page {
width: 3150px;
height: 2397px;
overflow: hidden;
border-bottom: 3px dashed black;
position: relative;
background-color: #f8f8f8
}
.group {
width: 3152px;
height: 2176px;
position: absolute;
top: 100px;
}
.overlay {
position: absolute;
background-image: url("assets/cards/8.5x11_template.png");
width: 3152px;
height: 2176px;
top: 100px;
}
</style>
</head>
<body>
<?php
include('include/monpoc_functions.php');
include('include/monpoc_figures.php');
if(!isset($language) || $language == ""){
$language = "english";
}
$display = array();
if($type=='monster' && uscore($faction) != 'neutral'){
foreach($figures as $name => $stats){
if( strpos(uscore($stats['faction']),uscore($faction)) !== false && $stats['type'] === 'monster' ){
$display[] = $name;
}
}
foreach($figures as $name => $stats){
if( strpos(uscore($stats['faction']),uscore($faction)) !== false && $stats['type'] === 'building' ){
$display[] = $name;
}
}
foreach($figures as $name => $stats){
if( strpos(uscore($stats['faction']),uscore($faction)) !== false && $stats['type'] === 'character' ){
$display[] = $name;
}
}
}elseif(uscore($faction) == 'neutral'){
if($type!="ref"){
foreach($figures as $name => $stats){
if( strpos(uscore($stats['faction']),uscore($faction)) !== false && $stats['type'] === 'building' ){
$display[] = $name;
}
}
foreach($figures as $name => $stats){
if( strpos(uscore($stats['faction']),uscore($faction)) !== false && $stats['type'] === 'unit' ){
$display[] = $name;
}
}
}else{
foreach($figures as $name => $stats){
if( strpos(uscore($stats['faction']),uscore($faction)) !== false && $stats['type'] === 'reference' ){
$display[] = $name;
}
}
foreach($figures as $name => $stats){
if( strpos(uscore($stats['faction']),uscore($faction)) !== false && $stats['type'] === 'map' ){
$display[] = $name;
}
}
}
}else{
foreach($figures as $name => $stats){
if( strpos(uscore($stats['faction']),uscore($faction)) !== false && ( $stats['type'] === $type || !isset($type) ) ){
$display[] = $name;
}
}
}
for($i=0;$i<count($display);$i+=8){
print('
<div class="page">
<div class="group">
');
foreach($display as $k => $v){
if($k >= $i && $k <= ($i+7)){
print('<img src="assets/cards_original/'.$language.'/'.uscore($figures[$v]['faction']).'/'.$v.'.jpg">');
}
}
print('
</div>
<div class="overlay"> </div>
</div>');
}
?>
</body>
</html>