Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

Passed
Branch master (0a752f)
by Dan
03:57
created
templates/Default/engine/Default/includes/CommonMessageSend.inc 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,10 +1,10 @@
 block discarded – undo
1
-<?php if(isset($Preview)) { ?><table class="standard"><tr><td><?php echo bbifyMessage($Preview); ?></td></tr></table><?php } ?>
1
+<?php if (isset($Preview)) { ?><table class="standard"><tr><td><?php echo bbifyMessage($Preview); ?></td></tr></table><?php } ?>
2 2
 <form name="MessageSendForm" method="POST" action="<?php echo $MessageSendFormHref; ?>">
3 3
 	<p>
4 4
 		<b>From: </b><?php echo $ThisPlayer->getDisplayName(); ?><br />
5
-		<b>To: </b><?php if(isset($Receiver) && is_object($Receiver)) {	echo $Receiver->getDisplayName(); } else { echo $Receiver; } ?>
5
+		<b>To: </b><?php if (isset($Receiver) && is_object($Receiver)) {	echo $Receiver->getDisplayName(); } else { echo $Receiver; } ?>
6 6
 	</p>
7
-	<textarea spellcheck="true" name="message" class="InputFields"><?php if(isset($Preview)) { echo $Preview; } ?></textarea><br />
7
+	<textarea spellcheck="true" name="message" class="InputFields"><?php if (isset($Preview)) { echo $Preview; } ?></textarea><br />
8 8
 	<br />
9 9
 	<input type="submit" name="action" value="Send message" class="InputFields" />&nbsp;<input type="submit" name="action" value="Preview message" class="InputFields" />
10 10
 </form>
Please login to merge, or discard this patch.
templates/Default/engine/Default/beta_functions.php 1 patch
Braces   +14 added lines, -4 removed lines patch added patch discarded remove patch
@@ -76,8 +76,13 @@  discard block
 block discarded – undo
76 76
 	<input type="number" name="amount" value="0" min="<?php echo MIN_GLOBAL_RELATIONS; ?>" max="<?php echo MAX_GLOBAL_RELATIONS; ?>" style="width:75px" />&nbsp;
77 77
 	<select name="race" class="InputFields"><?php
78 78
 		foreach (Globals::getRaces() as $race) {
79
-			if ($race['Race ID'] == $ThisPlayer->getRaceID()) continue;
80
-			if ($race['Race ID'] == RACE_NEUTRAL) continue; ?>
79
+			if ($race['Race ID'] == $ThisPlayer->getRaceID()) {
80
+				continue;
81
+			}
82
+			if ($race['Race ID'] == RACE_NEUTRAL) {
83
+				continue;
84
+			}
85
+			?>
81 86
 			<option value="<?php echo $race['Race ID']; ?>"><?php echo $race['Race Name']; ?></option><?php
82 87
 		} ?>
83 88
 	</select>&nbsp;&nbsp;
@@ -88,8 +93,13 @@  discard block
 block discarded – undo
88 93
 <form method="POST" action="<?php echo $ChangeRaceHREF; ?>">
89 94
 	<select name="race" class="InputFields"><?php
90 95
 		foreach (Globals::getRaces() as $race) {
91
-			if ($race['Race ID'] == $ThisPlayer->getRaceID()) continue;
92
-			if ($race['Race ID'] == RACE_NEUTRAL) continue; ?>
96
+			if ($race['Race ID'] == $ThisPlayer->getRaceID()) {
97
+				continue;
98
+			}
99
+			if ($race['Race ID'] == RACE_NEUTRAL) {
100
+				continue;
101
+			}
102
+			?>
93 103
 			<option value="<?php echo $race['Race ID']; ?>"><?php echo $race['Race Name']; ?></option><?php
94 104
 		} ?>
95 105
 	</select>&nbsp;&nbsp;
Please login to merge, or discard this patch.
templates/Default/engine/Default/includes/PlanetCombatResults.inc 2 patches
Spacing   +45 added lines, -45 removed lines patch added patch discarded remove patch
@@ -1,9 +1,9 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 $CombatPlanet = $PlanetCombatResults['Planet'];
3 3
 $TotalDamage = $PlanetCombatResults['TotalDamage'];
4
-if($MinimalDisplay) {
4
+if ($MinimalDisplay) {
5 5
 	echo $CombatPlanet->getDisplayName();
6
-	if($TotalDamage > 0) {
6
+	if ($TotalDamage > 0) {
7 7
 		?> hit for a total of <span class="red"><?php echo $TotalDamage; ?></span> damage in this round of combat of which <span class="red"><?php echo $PlanetCombatResults['TotalDamagePerTargetPlayer'][$ThisPlayer->getAccountID()]; ?></span> was done to you<?php
8 8
 	}
9 9
 	else {
@@ -11,33 +11,33 @@  discard block
 block discarded – undo
11 11
 	} ?>. <?php echo $AttackLogLink;
12 12
 	return;
13 13
 }
14
-if(isset($PlanetCombatResults['Weapons']) && is_array($PlanetCombatResults['Weapons'])) {
15
-	foreach($PlanetCombatResults['Weapons'] as $WeaponResults) {
16
-		$ShootingWeapon =& $WeaponResults['Weapon'];
17
-		$ShotHit =& $WeaponResults['Hit'];
18
-		$ActualDamage =& $WeaponResults['ActualDamage'];
19
-		$WeaponDamage =& $WeaponResults['WeaponDamage'];
20
-		$TargetPlayer =& $WeaponResults['TargetPlayer'];
14
+if (isset($PlanetCombatResults['Weapons']) && is_array($PlanetCombatResults['Weapons'])) {
15
+	foreach ($PlanetCombatResults['Weapons'] as $WeaponResults) {
16
+		$ShootingWeapon = & $WeaponResults['Weapon'];
17
+		$ShotHit = & $WeaponResults['Hit'];
18
+		$ActualDamage = & $WeaponResults['ActualDamage'];
19
+		$WeaponDamage = & $WeaponResults['WeaponDamage'];
20
+		$TargetPlayer = & $WeaponResults['TargetPlayer'];
21 21
 		$DamageTypes = 0;
22
-		if($ActualDamage['Shield'] > 0){ $DamageTypes = $DamageTypes+1; }
23
-		if($ActualDamage['NumCDs'] > 0){ $DamageTypes = $DamageTypes+1; }
24
-		if($ActualDamage['Armour'] > 0){ $DamageTypes = $DamageTypes+1; }
22
+		if ($ActualDamage['Shield'] > 0) { $DamageTypes = $DamageTypes + 1; }
23
+		if ($ActualDamage['NumCDs'] > 0) { $DamageTypes = $DamageTypes + 1; }
24
+		if ($ActualDamage['Armour'] > 0) { $DamageTypes = $DamageTypes + 1; }
25 25
 		
26
-		echo $CombatPlanet->getDisplayName() ?> fires a <?php echo $ShootingWeapon->getName(); ?> at <?php if($ShotHit && $ActualDamage['TargetAlreadyDead']){ ?> the debris that was once <?php } echo $TargetPlayer->getDisplayName();
27
-		if(!$ActualDamage['TargetAlreadyDead']) {
28
-			if(!$ShotHit) {
26
+		echo $CombatPlanet->getDisplayName() ?> fires a <?php echo $ShootingWeapon->getName(); ?> at <?php if ($ShotHit && $ActualDamage['TargetAlreadyDead']) { ?> the debris that was once <?php } echo $TargetPlayer->getDisplayName();
27
+		if (!$ActualDamage['TargetAlreadyDead']) {
28
+			if (!$ShotHit) {
29 29
 				?> and misses<?php
30 30
 			}
31
-			else if($ActualDamage['TotalDamage'] == 0) {
32
-				if($WeaponDamage['Shield'] > 0) {
33
-					if($ActualDamage['HasCDs']) {
31
+			else if ($ActualDamage['TotalDamage'] == 0) {
32
+				if ($WeaponDamage['Shield'] > 0) {
33
+					if ($ActualDamage['HasCDs']) {
34 34
 						?> which proves ineffective against their combat drones<?php
35 35
 					}
36 36
 					else {
37 37
 						?> which washes harmlessly over their hull<?php
38 38
 					}
39 39
 				}
40
-				else if($WeaponDamage['Armour'] > 0) {
40
+				else if ($WeaponDamage['Armour'] > 0) {
41 41
 					?> which is deflected by their shields<?php
42 42
 				}
43 43
 				else {
@@ -46,52 +46,52 @@  discard block
 block discarded – undo
46 46
 			}
47 47
 			else {
48 48
 				?> destroying <?php
49
-				if($ActualDamage['Shield'] > 0) {
49
+				if ($ActualDamage['Shield'] > 0) {
50 50
 					?><span class="shields"><?php echo number_format($ActualDamage['Shield']); ?></span> shields<?php
51 51
 					$this->doDamageTypeReductionDisplay($DamageTypes);
52 52
 				}
53
-				if($ActualDamage['NumCDs'] > 0) {
53
+				if ($ActualDamage['NumCDs'] > 0) {
54 54
 					?><span class="cds"><?php echo number_format($ActualDamage['NumCDs']); ?></span> combat drones<?php
55 55
 					$this->doDamageTypeReductionDisplay($DamageTypes);
56 56
 				}
57
-				if($ActualDamage['Armour'] > 0) {
57
+				if ($ActualDamage['Armour'] > 0) {
58 58
 					?><span class="red"><?php echo number_format($ActualDamage['Armour']); ?></span> plates of armour<?php
59 59
 				}
60 60
 			}
61 61
 		} ?>.
62 62
 		<br /><?php
63
-		if($ActualDamage['KillingShot']) {
64
-			$this->includeTemplate('includes/TraderCombatKillMessage.inc',array('KillResults'=>$WeaponResults['KillResults'],'TargetPlayer'=>$TargetPlayer));
63
+		if ($ActualDamage['KillingShot']) {
64
+			$this->includeTemplate('includes/TraderCombatKillMessage.inc', array('KillResults'=>$WeaponResults['KillResults'], 'TargetPlayer'=>$TargetPlayer));
65 65
 		}
66 66
 	}
67 67
 }
68
-if(isset($PlanetCombatResults['Drones'])) {
69
-	$Drones =& $PlanetCombatResults['Drones'];
70
-	$ActualDamage =& $Drones['ActualDamage'];
71
-	$WeaponDamage =& $Drones['WeaponDamage'];
72
-	$TargetPlayer =& $Drones['TargetPlayer'];
68
+if (isset($PlanetCombatResults['Drones'])) {
69
+	$Drones = & $PlanetCombatResults['Drones'];
70
+	$ActualDamage = & $Drones['ActualDamage'];
71
+	$WeaponDamage = & $Drones['WeaponDamage'];
72
+	$TargetPlayer = & $Drones['TargetPlayer'];
73 73
 	$DamageTypes = 0;
74
-	if($ActualDamage['Shield'] > 0){ $DamageTypes = $DamageTypes+1; }
75
-	if($ActualDamage['NumCDs'] > 0){ $DamageTypes = $DamageTypes+1; }
76
-	if($ActualDamage['Armour'] > 0){ $DamageTypes = $DamageTypes+1; }
74
+	if ($ActualDamage['Shield'] > 0) { $DamageTypes = $DamageTypes + 1; }
75
+	if ($ActualDamage['NumCDs'] > 0) { $DamageTypes = $DamageTypes + 1; }
76
+	if ($ActualDamage['Armour'] > 0) { $DamageTypes = $DamageTypes + 1; }
77 77
 	
78 78
 	echo $CombatPlanet->getDisplayName();
79
-	if($WeaponDamage['Launched'] == 0) {
79
+	if ($WeaponDamage['Launched'] == 0) {
80 80
 		?> fails to launch it's combat drones<?php
81 81
 	}
82 82
 	else {
83
-		?> launches <span class="cds"><?php echo $WeaponDamage['Launched'] ?></span> combat drones at <?php if($ActualDamage['TargetAlreadyDead']){ ?>the debris that was once <?php } echo $TargetPlayer->getDisplayName();
84
-		if(!$ActualDamage['TargetAlreadyDead']) {
85
-			if($ActualDamage['TotalDamage'] == 0) {
86
-				if($WeaponDamage['Shield'] > 0) {
87
-					if($ActualDamage['HasCDs']) {
83
+		?> launches <span class="cds"><?php echo $WeaponDamage['Launched'] ?></span> combat drones at <?php if ($ActualDamage['TargetAlreadyDead']) { ?>the debris that was once <?php } echo $TargetPlayer->getDisplayName();
84
+		if (!$ActualDamage['TargetAlreadyDead']) {
85
+			if ($ActualDamage['TotalDamage'] == 0) {
86
+				if ($WeaponDamage['Shield'] > 0) {
87
+					if ($ActualDamage['HasCDs']) {
88 88
 						?> which prove ineffective against their combat drones<?php
89 89
 					}
90 90
 					else {
91 91
 						?> which washes harmlessly over their hull<?php
92 92
 					}
93 93
 				}
94
-				else if($WeaponDamage['Armour'] > 0) {
94
+				else if ($WeaponDamage['Armour'] > 0) {
95 95
 					?> which is deflected by their shields<?php
96 96
 				}
97 97
 				else {
@@ -100,28 +100,28 @@  discard block
 block discarded – undo
100 100
 			}
101 101
 			else {
102 102
 				?> destroying <?php
103
-				if($ActualDamage['Shield'] > 0) {
103
+				if ($ActualDamage['Shield'] > 0) {
104 104
 					?><span class="shields"><?php echo number_format($ActualDamage['Shield']); ?></span> shields<?php
105 105
 					$this->doDamageTypeReductionDisplay($DamageTypes);
106 106
 				}
107
-				if($ActualDamage['NumCDs'] > 0) {
107
+				if ($ActualDamage['NumCDs'] > 0) {
108 108
 					?><span class="cds"><?php echo number_format($ActualDamage['NumCDs']); ?></span> combat drones<?php
109 109
 					$this->doDamageTypeReductionDisplay($DamageTypes);
110 110
 				}
111
-				if($ActualDamage['Armour'] > 0) {
111
+				if ($ActualDamage['Armour'] > 0) {
112 112
 					?><span class="red"><?php echo number_format($ActualDamage['Armour']); ?></span> plates of armour<?php
113 113
 				}
114 114
 			}
115 115
 		}
116 116
 	} ?>.
117 117
 	<br /><?php
118
-	if($ActualDamage['KillingShot']) {
119
-		$this->includeTemplate('includes/TraderCombatKillMessage.inc',array('KillResults'=>$Drones['KillResults'],'TargetPlayer'=>$TargetPlayer));
118
+	if ($ActualDamage['KillingShot']) {
119
+		$this->includeTemplate('includes/TraderCombatKillMessage.inc', array('KillResults'=>$Drones['KillResults'], 'TargetPlayer'=>$TargetPlayer));
120 120
 	}
121 121
 }
122 122
 
123 123
 echo $CombatPlanet->getDisplayName();
124
-if($TotalDamage > 0) {
124
+if ($TotalDamage > 0) {
125 125
 	?> hit for a total of <span class="red"><?php echo $TotalDamage; ?></span> damage in this round of combat<?php
126 126
 }
127 127
 else {
Please login to merge, or discard this patch.
Braces   +12 added lines, -24 removed lines patch added patch discarded remove patch
@@ -5,8 +5,7 @@  discard block
 block discarded – undo
5 5
 	echo $CombatPlanet->getDisplayName();
6 6
 	if($TotalDamage > 0) {
7 7
 		?> hit for a total of <span class="red"><?php echo $TotalDamage; ?></span> damage in this round of combat of which <span class="red"><?php echo $PlanetCombatResults['TotalDamagePerTargetPlayer'][$ThisPlayer->getAccountID()]; ?></span> was done to you<?php
8
-	}
9
-	else {
8
+	} else {
10 9
 		?> does no damage this round<?php
11 10
 	} ?>. <?php echo $AttackLogLink;
12 11
 	return;
@@ -27,24 +26,19 @@  discard block
 block discarded – undo
27 26
 		if(!$ActualDamage['TargetAlreadyDead']) {
28 27
 			if(!$ShotHit) {
29 28
 				?> and misses<?php
30
-			}
31
-			else if($ActualDamage['TotalDamage'] == 0) {
29
+			} else if($ActualDamage['TotalDamage'] == 0) {
32 30
 				if($WeaponDamage['Shield'] > 0) {
33 31
 					if($ActualDamage['HasCDs']) {
34 32
 						?> which proves ineffective against their combat drones<?php
35
-					}
36
-					else {
33
+					} else {
37 34
 						?> which washes harmlessly over their hull<?php
38 35
 					}
39
-				}
40
-				else if($WeaponDamage['Armour'] > 0) {
36
+				} else if($WeaponDamage['Armour'] > 0) {
41 37
 					?> which is deflected by their shields<?php
42
-				}
43
-				else {
38
+				} else {
44 39
 					?> but it cannot do any damage<?php
45 40
 				}
46
-			}
47
-			else {
41
+			} else {
48 42
 				?> destroying <?php
49 43
 				if($ActualDamage['Shield'] > 0) {
50 44
 					?><span class="shields"><?php echo number_format($ActualDamage['Shield']); ?></span> shields<?php
@@ -78,27 +72,22 @@  discard block
 block discarded – undo
78 72
 	echo $CombatPlanet->getDisplayName();
79 73
 	if($WeaponDamage['Launched'] == 0) {
80 74
 		?> fails to launch it's combat drones<?php
81
-	}
82
-	else {
75
+	} else {
83 76
 		?> launches <span class="cds"><?php echo $WeaponDamage['Launched'] ?></span> combat drones at <?php if($ActualDamage['TargetAlreadyDead']){ ?>the debris that was once <?php } echo $TargetPlayer->getDisplayName();
84 77
 		if(!$ActualDamage['TargetAlreadyDead']) {
85 78
 			if($ActualDamage['TotalDamage'] == 0) {
86 79
 				if($WeaponDamage['Shield'] > 0) {
87 80
 					if($ActualDamage['HasCDs']) {
88 81
 						?> which prove ineffective against their combat drones<?php
89
-					}
90
-					else {
82
+					} else {
91 83
 						?> which washes harmlessly over their hull<?php
92 84
 					}
93
-				}
94
-				else if($WeaponDamage['Armour'] > 0) {
85
+				} else if($WeaponDamage['Armour'] > 0) {
95 86
 					?> which is deflected by their shields<?php
96
-				}
97
-				else {
87
+				} else {
98 88
 					?> but they cannot do any damage<?php
99 89
 				}
100
-			}
101
-			else {
90
+			} else {
102 91
 				?> destroying <?php
103 92
 				if($ActualDamage['Shield'] > 0) {
104 93
 					?><span class="shields"><?php echo number_format($ActualDamage['Shield']); ?></span> shields<?php
@@ -123,7 +112,6 @@  discard block
 block discarded – undo
123 112
 echo $CombatPlanet->getDisplayName();
124 113
 if($TotalDamage > 0) {
125 114
 	?> hit for a total of <span class="red"><?php echo $TotalDamage; ?></span> damage in this round of combat<?php
126
-}
127
-else {
115
+} else {
128 116
 	?> does no damage this round. You call that a planet? It needs a better builder<?php
129 117
 } ?>.
Please login to merge, or discard this patch.
lib/Default/hof.functions.inc 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -55,9 +55,9 @@
 block discarded – undo
55 55
 function applyHofVisibilityMask($amount, $vis, $gameID, $accountID) {
56 56
 	global $account, $player;
57 57
 	if (($vis == HOF_PRIVATE && $account->getAccountID() != $accountID) ||
58
-	    ($vis == HOF_ALLIANCE && isset($gameID) &&
59
-	     !SmrGame::getGame($gameID)->hasEnded() &&
60
-	     !SmrPlayer::getPlayer($accountID, $gameID)->sameAlliance($player)))
58
+		($vis == HOF_ALLIANCE && isset($gameID) &&
59
+		 !SmrGame::getGame($gameID)->hasEnded() &&
60
+		 !SmrPlayer::getPlayer($accountID, $gameID)->sameAlliance($player)))
61 61
 	{
62 62
 		return '-';
63 63
 	} else {
Please login to merge, or discard this patch.
admin/Default/1.6/game_edit_processing.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
 // Get the dates ("|" sets hr/min/sec to 0)
4 4
 $join = DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_join']);
5 5
 $start = empty($_REQUEST['game_start']) ? $join :
6
-         DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_start']);
6
+		 DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_start']);
7 7
 $end = DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_end']);
8 8
 
9 9
 $game = SmrGame::getGame($var['game_id']);
Please login to merge, or discard this patch.
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -2,8 +2,7 @@
 block discarded – undo
2 2
 
3 3
 // Get the dates ("|" sets hr/min/sec to 0)
4 4
 $join = DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_join']);
5
-$start = empty($_REQUEST['game_start']) ? $join :
6
-         DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_start']);
5
+$start = empty($_REQUEST['game_start']) ? $join : DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_start']);
7 6
 $end = DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_end']);
8 7
 
9 8
 $game = SmrGame::getGame($var['game_id']);
Please login to merge, or discard this patch.
admin/Default/1.6/game_create_processing.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
 // Get the dates ("|" sets hr/min/sec to 0)
19 19
 $join = DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_join']);
20 20
 $start = empty($_REQUEST['game_start']) ? $join :
21
-         DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_start']);
21
+		 DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_start']);
22 22
 $end = DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_end']);
23 23
 
24 24
 $game = SmrGame::createGame($newID);
Please login to merge, or discard this patch.
Spacing   +26 added lines, -27 removed lines patch added patch discarded remove patch
@@ -1,22 +1,21 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3 3
 //first create the game
4
-$db->query('SELECT game_id FROM game WHERE game_name='.$db->escapeString($_REQUEST['game_name']).' LIMIT 1');
4
+$db->query('SELECT game_id FROM game WHERE game_name=' . $db->escapeString($_REQUEST['game_name']) . ' LIMIT 1');
5 5
 if ($db->nextRecord()) {
6 6
 	create_error('That game name is already taken.');
7 7
 }
8 8
 
9 9
 $db->query('SELECT game_id FROM game ORDER BY game_id DESC LIMIT 1');
10 10
 if ($db->nextRecord()) {
11
-	$newID = $db->getInt('game_id')+1;
11
+	$newID = $db->getInt('game_id') + 1;
12 12
 } else {
13 13
 	$newID = 1;
14 14
 }
15 15
 
16 16
 // Get the dates ("|" sets hr/min/sec to 0)
17 17
 $join = DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_join']);
18
-$start = empty($_REQUEST['game_start']) ? $join :
19
-         DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_start']);
18
+$start = empty($_REQUEST['game_start']) ? $join : DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_start']);
20 19
 $end = DateTime::createFromFormat('d/m/Y|', $_REQUEST['game_end']);
21 20
 
22 21
 $game = SmrGame::createGame($newID);
@@ -84,7 +83,7 @@  discard block
 block discarded – undo
84 83
 	7) Contact Newbie Help Leader for help, advice or with any questions you have.<br />
85 84
 	<br />
86 85
 	8) Most of all - have fun out there!';
87
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 1, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
86
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 1, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
88 87
 	
89 88
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 2, \'What the Newbie Help Alliance (NHA) can do for you\')');
90 89
 	$text = 'There are a number of ways this alliance can help you as a new player, and you are welcome to make use of as many or as few of these as you wish:<br />
@@ -98,7 +97,7 @@  discard block
 block discarded – undo
98 97
 	4) If you stay in NHA, stay active, try to learn, and keep in touch with the Newbie Help Leader then this alliance can be a stepping stone to the more established alliances. Every game I get alliance leaders asking me to recommend newbies who are active and have potential.<br />
99 98
 	<br />
100 99
 	5) Newbie Help Leader will work with each of you individually on specific questions and game goals if you want. If resources allow it (I am dependent on my own trading income for cash) I try to reward players for achieving the game goals they work towards. I also try to make sure that members have at least a mid-level tradeship after they have been killed, although I try to make sure that they have learned from their mistakes before buying replacement ships (to be fair to the rest of the players in the game, you can no longer get cash or new ships after reaching fledgling status, although you are welcome to stay in the alliance as long as you like).';
101
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 2, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
100
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 2, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
102 101
 	
103 102
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 3, \'Turns\')');
104 103
 	$text = 'Many of the basic actions performed in SMR cost turns, the most common examples being moving, trading &amp; attacking. One of the keys to success in the game is good turn management, no matter what you are busing the turns to accomplish. If you are a trader, you want to get as much cash and xp as possible per turn used. If you are a hunter, you want to spend as many turns as possible efficiently locating targets and getting kills, and as few as possible chasing traders around without getting the final trigger shot off. In an alliance, you will often be expected to save turns for op\'s, where it is often crucial to have plenty of alliance members show up with plenty of turns.<br />
@@ -106,7 +105,7 @@  discard block
 block discarded – undo
106 105
 	Turns are accumulated constantly, whether you are logged in or not, and are a product of ship speed and game speed. When you click the Trader link on the left of your screen, one of the things you will see is how many turns you get per hour in the ship you are in, and also the maximum number of turns you can accumulate in the current game. It is important to manage your turns carefully - make sure to always leave yourself enough turns to get back to somewhere you can park safely (preferably with some to spare in case you run into trouble on the way). It can sometimes be a good idea to save up a large number of turns so you can use them all in one session, but be aware that this is not always possible or even ideal. You should try to avoid reaching the maximum number of turns, since you will then stop getting more and will basically be wasting the turns you would usually have accumulated.<br />
107 106
 	<br />
108 107
 	A good way to get a few extra turns and help the game at the same time is to click on the voting links at the bottom of your screen. Voting for SMR helps our rankings, which brings more players to the game - making it better for all of us.';
109
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 3, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
108
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 3, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
110 109
 	
111 110
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 4, \'How to trade\')');
112 111
 	$text = 'In SMR, trading is the easiest and most fundamental way to accumulate both cash and experience points. The basic principles of trading are easy, but getting really good at it takes time and experience.<br />
@@ -120,7 +119,7 @@  discard block
 block discarded – undo
120 119
 	The experience you get from a trade depends on your relations with that race, and on how good a deal you make. With perfect relations (1000) you will automatically be offered the best possible deal by a port and will not need to bargain at all. At less than 1000 relations, you get experience depending on how well you bargain, where bargaining means offering a little less than the port asks for when you are buying and asking for a little more than the port is offering when you are selling. relations go up with successful trades, and they go down when a port refuses the bargain you offer them. If you are trading with your own race, it is often a good idea not to worry too much about making the best bargains at first and try to get maximum relations as quickly as possible.<br />
121 120
 	<br />
122 121
 	One of the major contributing factors to how well you can trade is the ship you are using. Profit and experience depend on the number of goods you are able to trade which depends in turn on the number of cargo holds you have and the speed of your ship. A general guide to how efficient a tradeship is is to multiply the number of holds by the ship speed to give you the trade potential. It is important to note, however, that trade potential is not the only important factor in choosing a tradeship. For example, the planetary super freighter is a very efficient trader with good defenses but is very slow and therefore very inefficient if you have to travel a lot between traderoutes and parking spots; whereas the Interstellar trader has pretty good trade potential and a jump drive to allow you to travel easily but has very weak defenses and is easily killed.';
123
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 4, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
122
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 4, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
124 123
 	
125 124
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 5, \'Safe trading\')');
126 125
 	$text = 'This topic is extensive, and there is no substitute for playing the game, probably dying a few times, and learning through experience. However, it doesn\'t hurt to keep a few tips and tricks in mind:<br />
@@ -136,7 +135,7 @@  discard block
 block discarded – undo
136 135
 	4) Watch the CPL. Before and during trading, keep an eye on the current player list and the news, and look for hunters who you think may come for you. It is sometimes better to leave trading for another time, but at least stay alive.<br />
137 136
 	<br />
138 137
 	5) Use local map. It can sometimes be useful to enter your port sectors using local map, especially if you suspect there may be trouble close by. This allows you to see ships sitting in neighbouring sectors waiting to ambush you, but it only works if you have a scanner.';
139
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 5, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
138
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 5, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
140 139
 	
141 140
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 6, \'Get a scanner\')');
142 141
 	$text = ' 	If your ship can equip with a scanner, then get one and learn how to use it. Scanners are very useful for moving around safely and for gathering information about local sectors. Some examples:<br />
@@ -146,19 +145,19 @@  discard block
 block discarded – undo
146 145
 	Scanners can warn you of cloaked ships. Scanning a sector (from a neighbouring sector) will give you a reading on the number of ships there. Enemy ships scan as their defensive value x 10. For example, if you scan a sector and get a reading of 300, then enter and see only a planetary super freighter there (def value of 15) then you know there is a 150 scan unaccounted for, which means a cloaked ship. At this point, you will probably want to get out of there fast! (Note that ship scans can sometimes also be off due to Illusion generator ships pretending to be something they are not).<br />
147 146
 	<br />
148 147
 	Scanners will give you force readings. Scanning a neighbouring sector will tell you the total number of forces in the sector (scouts scan as 1, drones as 2, mines as 3). This allows you to avoid sectors with heavy force scans (which usually means a lot of mines) when navigating.';
149
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 6, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
148
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 6, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
150 149
 	
151 150
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 7, \'Logging off safely\')');
152 151
 	$text = 'Before logging off, it is very important to ALWAYS check that your are as safe as you can be. Until you join a major alliance, you should all be parking safely in federally protected space every time you log off (sectors with a "Federal Beacon"). Before leaving SMR, ALWAYS check your main screen protection message and/or click the "Trader" link to make sure you are in fact protected.<br />
153 152
 	<br />
154 153
 	The two things that can prevent you from having federal protection are carrying illegal goods (slaves, weapons or narcotics) or having an attack rating that is too high. At neutral alignment, that is +/-149, you can park safely with an attack rating of 3 or less. The attack rating you can park with increases with increasing alignment and decreases with decreasing alignment.';
155
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 7, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
154
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 7, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
156 155
 	
157 156
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 8, \'Merchant\\\'s Guide to the Universe\')');
158 157
 	$text = 'MGU, as everyone calls it, is an extremely valuable tool to use alongside SMR. Details on how to get the software (as well as instructions and discussions) can be found on the SMR Webboard at http://smrcnn.smrealms.de/viewforum.php?f=32<br />
159 158
 	<br />
160 159
 	Basically, after you have installed MGU, you need to download your game maps using the link on the left side of the SMR page, and save them into your MGU directory. From MGU, you can then open the game maps and access the map information to do may useful things. MGU functions include things like finding traderoutes (listed by experience or cash), finding locations, plotting arming routes, finding safe course plots, etc.';
161
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 8, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
160
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 8, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
162 161
 		
163 162
 // remove newbie gals
164 163
 //	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 9, \'Racial galaxies\')');
@@ -171,19 +170,19 @@  discard block
 block discarded – undo
171 170
 	If you do get killed, it can be useful to politely message your killer and ask what you did wrong - most veteran players will be more than happy to advise you on how to avoid the same thing happening again, plus it shows them that you want to learn how to improve at the game. If you get a kill, it is considered impolite to send messages gloating over the fact, although some veteran players will sometimes message newbies they have killed with offers of cash to get them back on their feet or advice on how to avoid the same thing happening again.<br />
172 171
 	<br />
173 172
 	There are all kinds of ways to play and enjoy this game, different players choose to emphasize different aspects of gameplay - but whatever choices you make, the bottom line is that if you treat your fellow players (both allies and enemies) with respect, then they will respect you.';
174
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 10, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
173
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 10, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
175 174
 		
176 175
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 11, \'Talk to the players\')');
177 176
 	$text = 'SMR has a very active community, and it is always a good idea to talk to the other players. You can do this in the #smr chatroom, or by messaging them ingame. Most players will be happy to talk to you or help you if you send them polite messages.<br />
178 177
 	<br />
179 178
 	It is also a good idea to talk to veteran players, especially alliance leaders, about their alliances and what they look for in their team members. You probably won\'t be asked to join a major alliance right away, but many of them have training alliances and they are always looking for active players who are willing to learn and contribute to an alliance.';
180
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 11, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
179
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 11, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
181 180
 	
182 181
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 12, \'The Webboard\')');
183 182
 	$text = 'The SMR webboard (often referred to simply as the WB) is full of all kinds of advice and discussions, and I recommend stopping by to take a look every so often. It will all seem a bit much at first, but start with the sections that seem most useful to you and you will quickly learn to recognize what is important and what is not.<br />
184 183
 	<br />
185 184
 	You should also contribute to the webboard if you have an opinion or something you feel needs discussed, but please use the search function before starting new topics to make sure you are not repeating what someone else has posted somewhere else.';
186
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 12, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
185
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 12, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
187 186
 	
188 187
 	
189 188
 	
@@ -196,7 +195,7 @@  discard block
 block discarded – undo
196 195
 	If you are good (alignment 100 or higher) you can buy federal ships (Federal Discovery, Warrant and Ultimatum which all have jump drive and take half damage from forces) and buy the federal level 5 weapon (holy hand grenade). If you are neutral (between -99 and 99 alignment) you can become good by deputizing at any racial HQ. Good players cannot enter the underground HQ.<br />
197 196
 	<br />
198 197
 	Alignment also affects the attack ratings you can have and still be federally protected in fed space. At neutral alignment you can park with an attack rating of 3, and the protected rating goes up 1 for every +150 alignment and down 1 for every -150 alignment. You are always protected with an attack rating of zero.';
199
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 13, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
198
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 13, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
200 199
 	
201 200
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 14, \'Watching the news and CPL\')');
202 201
 	$text = 'Whether you are a trader or a hunter, it is very valuable to know as much as possible about who is currently active in the game, and where they might be. Two of the resources you need to learn to use, but also know the limitations of, are the news and the current player list (CPL).<br />
@@ -204,7 +203,7 @@  discard block
 block discarded – undo
204 203
 	Reading the news before you trade can be valuable in letting you know which hunters are currently active in the game, even if they don\'t show on the CPL. If there has been a recent kill near your traderoute, or a hunter that knows where you like to trade has recently been active, it is often a good idea to wait and trade another time.<br />
205 204
 	<br />
206 205
 	The CPL will let you know who has recently accessed the database, and also how many players are "lurking" (logged into the game, but not moving). It is a good idea to check the CPL for hunters you believe are a threat to you before you trade, and also every so often while you trade (especially if you are trading over a scout drone).';
207
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 14, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
206
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 14, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
208 207
 	
209 208
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 15, \'IRC chat\')');
210 209
 	$text = ' 	It is very helpful to learn to use IRC chat often while playing this game. The first step is to simply use the IRC chat link on the left of your screen and just spend some time in the #smr room getting to know some of the players. This is also a good time to ask questions - not just about technical or tactical aspects of the game, but about what the players like about the game, about the alliances, about pretty much anything. Getting to know the players and the community is part of getting to know SMR.<br />
@@ -212,7 +211,7 @@  discard block
 block discarded – undo
212 211
 	When you end up in an alliance, playing with a team, you will find that they pretty much all use dedicated alliance chatrooms that they use for conducting alliance operations. These rooms are also a place to simply hang out and chat, which is a great way to get to know your teammates.<br />
213 212
 	<br />
214 213
 	In time, if you are able to do so, it is useful to install an IRC client on the computer(s) you use. mIRC is free and works well. If you have trouble getting your IRC client to work, there are instructions and help to be found on the webboard.';
215
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 15, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
214
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 15, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
216 215
 	
217 216
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 16, \'Avoiding mines\')');
218 217
 	$text = 'Enemy mines are something you will encounter on a regular basis in SMR, and there are a couple of things that can help prevent you dying to them.<br />
@@ -224,11 +223,11 @@  discard block
 block discarded – undo
224 223
 	3) Work from UNO. If you are travelling a long way, it is often a very good idea not to plot your route directly from A to B, but to plan it so that you pass UNO shops along the way - this will allow you to refill your defenses as you go if you take some damage. This is especially important when travelling through large neutral galaxies.<br />
225 224
 	<br />
226 225
 	4) Use your maps. If you encounter heavily mined sectors, retreat to safety, then take the time to look carefully at your maps to see if the area you were in is close to something an alliance would want to protect (usually a galaxy warp or a Combat Accessories shop). Then plan a new route avoiding this area.';
227
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 16, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
226
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 16, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
228 227
 	
229 228
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 17, \'Port raiding\')');
230 229
 	$text = 'It\'s simple - don\'t do it! Raiding small ports will gain you nothing and will often get you killed, and raiding big ports is impossible without a well-armed fleet of warships.';
231
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 17, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
230
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 17, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
232 231
 	
233 232
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 18, \'Operations guide\')');
234 233
 	$text = ' 	http://smrcnn.smrealms.de/viewtopic.php?t=3922<br />
@@ -236,13 +235,13 @@  discard block
 block discarded – undo
236 235
 	Once you graduate to alliances that are more active in the bigger picture of a game, you will want to take part in alliance operations. SMR op\'s come in all kinds of shapes &amp; sizes and flavours, and involve things like territory wars, planet busts, port raids and fleet battles.<br />
237 236
 	<br />
238 237
 	The link I posted here is a rough guide to what you might expect, and what will be expected of you, in alliance op\'s.';
239
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 18, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
238
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 18, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
240 239
 	
241 240
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 19, \'Multiple accounts\')');
242 241
 	$text = 'Multiple accounts are NOT permitted in SMR. The game has admins who actively look for multiple accounts and suspicious activity. If you are caught playing more than one account, you risk losing all your accumulated stats and being banned from the game.<br />
243 242
 	<br />
244 243
 	One of the results of this strict policy on multiple accounts is that you should try to avoid logging into your account from any computer also used by other SMR players. Even though you are not actually playing more than one account, it can seem as though you are when the connection logs are checked.';
245
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 19, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
244
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 19, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
246 245
 	
247 246
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 20, \'Moving on to a new alliance\')');
248 247
 	$text = 'When you feel you are ready to move on from this alliance to a new one, it is a good idea to take the time to talk to the alliance leaders out there, When you do, don\'t be afraid to talk to the major alliances as well as the small ones - they probably won\'t offer you a spot right away, but they can give good advice and it also puts your name on their radar for future games.<br />
@@ -256,7 +255,7 @@  discard block
 block discarded – undo
256 255
 	5) Since you are still learning, what can you expect to learn from flying with a given alliance.<br />
257 256
 	<br />
258 257
 	There is no right time to leave this alliance and join a new one, but I recommend that you do not jump hastily or blindly into a random small alliance. Apart from anything else, some of the small ones are made up of new players who have as little game knowledge as you and are not doing anything remotely organized or coordinated.';
259
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 20, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
258
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 20, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
260 259
 			
261 260
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 21, \'Experience\')');
262 261
 	$text = 'There are many ways to play SMR, and many different aspects of the game to enjoy - but experience points are important whether you play with a high ranking as a goal in itself, or whether you see it as just another tool to help achieve other goals.<br />
@@ -267,7 +266,7 @@  discard block
 block discarded – undo
267 266
 	1) Higher weapon accuracy when you fire, and lower weapon accuracy for your opponents.<br />
268 267
 	2) The ability to cloak from lower ranked players.<br />
269 268
 	3) Demonstrating the ability to accumulate and keep a good experience level. This last benefit is especially important for new players since climbing the rankings and avoiding too many deaths will get you noticed.';
270
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 21, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
269
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 21, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
271 270
 	
272 271
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 22, \'Ships\')');
273 272
 	$text = 'Everything you do in SMR is done while you are flying some kind of ship - it can be anything from an escape pod to a huge IkThorne mothership, but you are always the pilot of something. In addition to the neutral ships, each race also has unique ships that only race members can purchase. You can find the SMR shiplist <a href="ship_list.php" target="_blank"><b><u>here</u></b></a>.<br />
@@ -294,7 +293,7 @@  discard block
 block discarded – undo
294 293
 	- Speed. Ship speed determines how fast your ship will accumulate turns. Faster ships gain more turns per hour and vice versa.<br />
295 294
 	- Hardware. Most ships can use one or more hardware items, each of which adds certain capabilities to the ship. These are Scanners (see scanner thread), Cloaks (invisibility from lower ranked traders when activated), Illusion Generators (the ability to disguise your ship), Jump Drives (allows you to jump from place to place without travelling through the sectors between), and Drone Scramblers (improved defense against combat drones).<br />
296 295
 	- Restricted ships. There are restrictions on who can buy certain ships. These include racial restrictions, top racial restrictions (the top racial ships cannot be purchased until you reach fledgling status), and alignment restrictions (Underground and Federal ships require you to be evil or good respectively, Federal ships also take half damage from forces).';
297
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 22, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
296
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 22, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
298 297
 	
299 298
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 23, \'Weapons\')');
300 299
 	$text = 'SMR has a wide variety of weapons with which to arm your ships, and information on weapon capabilities can be found <a href="weapon_list.php" target="_blank"><b><u>here</b></u></a>.<br />
@@ -306,7 +305,7 @@  discard block
 block discarded – undo
306 305
 	- Accuracy. Weapon accuracy (modified by trader level) determines how likely it is that your weapon will hit your target on any shot. In ship to ship combat, higher ranked traders get accuracy benefits over their lower ranked opponents. There is (and always has been since the dawn of this game) an ongoing debate about when it is better to use either high accuracy low damage weapons or low accuracy high damage weapons.<br />
307 306
 	- Rating. There are restrictions on how many weapons of certain ratings you are allowed to arm yourself with. Weapon rating is determined by accuracy and damage, and higher is better. You are allowed up to one level 5 weapon, up to 2 level 4 weapons, and up to 3 level 3 weapons.<br />
308 307
 	- Availability.Weapon choice when arming is sometimes determined by the availability of certain weapons. Racial weapons are only available to the owner race or races that have peaceful relations with them; weapons may be sold at weapon shops that are not safely accessible; or the number of turns it would take to acquire all the weapons you would like may be too high.';
309
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 23, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
308
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 23, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
310 309
 	
311 310
 	$db->query('REPLACE INTO alliance_thread_topic (game_id, alliance_id, thread_id, topic) VALUES (' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 24, \'Planets and Territory\')');
312 311
 	$text = 'Except for your ship and what it carries, a planet is the only thing in SMR that you can claim for yourself or your alliance. This means that planets and planet galaxies are often the main focus of the rivalries and wars between alliances.<br />
@@ -316,5 +315,5 @@  discard block
 block discarded – undo
316 315
 	Kill counts and experience are important measures of success, but many veteran players feel that the only true measure of success in alliance wars is the ability to hold and/or take territory from enemy alliances.<br />
317 316
 	<br />
318 317
 	It is important to note that weakly defended planets should NOT be considered safe parking spots.';
319
-	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 24, 1, '.$db->escapeString($text).', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
318
+	$db->query('REPLACE INTO alliance_thread (game_id, alliance_id, thread_id, reply_id, text, sender_id, time) VALUES(' . $db->escapeNumber($gameID) . ', ' . $db->escapeNumber(NHA_ID) . ', 24, 1, ' . $db->escapeString($text) . ', ' . $db->escapeNumber(ACCOUNT_ID_NHL) . ', ' . $db->escapeNumber(TIME) . ')');
320 319
 }
Please login to merge, or discard this patch.
admin/Default/manage_draft_leaders.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -7,7 +7,7 @@  discard block
 block discarded – undo
7 7
 $db->query('SELECT game_id, game_name FROM game WHERE game_type=' . $db->escapeNumber(SmrGame::GAME_TYPE_DRAFT) . ' AND join_time < ' . $db->escapeNumber(TIME) . ' AND end_time > ' . $db->escapeNumber(TIME) . ' ORDER BY start_time DESC');
8 8
 while ($db->nextRecord()) {
9 9
 	$activeGames[] = array('game_name' => $db->getField('game_name'),
10
-	                       'game_id' => $db->getInt('game_id'));
10
+						   'game_id' => $db->getInt('game_id'));
11 11
 }
12 12
 $template->assign('ActiveGames', $activeGames);
13 13
 
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
 	$db->query('SELECT account_id FROM draft_leaders WHERE game_id=' . $db->escapeNumber($var['selected_game_id']));
27 27
 	while ($db->nextRecord()) {
28 28
 		$editor = SmrPlayer::getPlayer($db->getInt('account_id'),
29
-		                               $var['selected_game_id']);
29
+									   $var['selected_game_id']);
30 30
 		$currentLeaders[] = $editor->getDisplayName();
31 31
 	}
32 32
 	$template->assign('CurrentLeaders', $currentLeaders);
Please login to merge, or discard this patch.
admin/Default/manage_post_editors.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -7,7 +7,7 @@
 block discarded – undo
7 7
 $db->query('SELECT game_id, game_name FROM game WHERE join_time < ' . $db->escapeNumber(TIME) . ' AND end_time > ' . $db->escapeNumber(TIME) . ' ORDER BY start_time DESC');
8 8
 while ($db->nextRecord()) {
9 9
 	$activeGames[] = array('game_name' => $db->getField('game_name'),
10
-	                       'game_id' => $db->getInt('game_id'));
10
+						   'game_id' => $db->getInt('game_id'));
11 11
 }
12 12
 $template->assign('ActiveGames', $activeGames);
13 13
 
Please login to merge, or discard this patch.
admin/Default/permission_manage.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -46,5 +46,5 @@
 block discarded – undo
46 46
 	$template->assign('ProcessingHREF', $processingHREF);
47 47
 
48 48
 	$template->assign('PermissionCategories',
49
-	                  AdminPermissions::getPermissionsByCategory());
49
+					  AdminPermissions::getPermissionsByCategory());
50 50
 }
Please login to merge, or discard this patch.