-
Notifications
You must be signed in to change notification settings - Fork 161
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
44 changed files
with
555 additions
and
173 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -67,7 +67,7 @@ Further information and artwork: | |
An Nvidia graphics card with compute capability 6.0 or higher is needed. Please check [https://en.wikipedia.org/wiki/CUDA#GPUs_supported](https://en.wikipedia.org/wiki/CUDA#GPUs_supported). | ||
|
||
# 💽 Installer | ||
Installer for Windows: [alien-installer.msi](https://alien-project.org/media/files/alien-installer.msi) (Updated: 2024-03-16) | ||
Installer for Windows: [alien-installer.msi](https://alien-project.org/media/files/alien-installer.msi) (Updated: 2024-04-22) | ||
|
||
In the case that the program crashes for an unknown reason, please refer to the troubleshooting section in [alien-project.org/downloads.html](https://alien-project.org/downloads.html). | ||
|
||
|
@@ -137,9 +137,10 @@ A short architectural overview of the source code can be found in the [documenta | |
|
||
ALIEN has been initiated, mainly developed and maintained by [Christian Heinemann](mailto:[email protected]). Thanks to all the others who contributed to this repository: | ||
- [tlemo](https://github.com/tlemo) | ||
- [TheBarret](https://github.com/TheBarret) | ||
- [mpersano](https://github.com/mpersano) | ||
- [dguerizec](https://github.com/dguerizec) | ||
- [Will Allen](https://github.com/willjallen) | ||
- [TheBarret](https://github.com/TheBarret) | ||
|
||
The following external libraries are used: | ||
- [CUDA Toolkit](https://developer.nvidia.com/cuda-toolkit) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule vcpkg
updated
10499 files
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
<?php | ||
require './helpers.php'; | ||
require './hooks.php'; | ||
|
||
function closeAndExit($db) { | ||
echo json_encode(["result"=>false]); | ||
$db->close(); | ||
exit; | ||
} | ||
|
||
|
||
$db = connectToDB(); | ||
$db->begin_transaction(); | ||
|
||
$userName = $_POST["userName"]; | ||
$pw = $_POST["password"]; | ||
|
||
if (!checkPw($db, $userName, $pw)) { | ||
closeAndExit($db); | ||
} | ||
|
||
$obj = $db->query("SELECT u.ID as id FROM user u WHERE u.NAME='".addslashes($userName)."'")->fetch_object(); | ||
if (!$obj) { | ||
closeAndExit($db); | ||
} | ||
|
||
$success = false; | ||
$particles = (int)$_POST['particles']; | ||
$version = $_POST['version']; | ||
$width = (int)$_POST['width']; | ||
$height = (int)$_POST['height']; | ||
$content = $_POST['content']; | ||
$settings = $_POST['settings']; | ||
$simId = $_POST['simId']; | ||
$size = strlen($content); | ||
$statistics = array_key_exists('statistics', $_POST) ? $_POST['statistics'] : ""; | ||
|
||
$obj = $db->query("SELECT sim.NAME as name, sim.TYPE as type, sim.FROM_RELEASE as workspace FROM simulation sim WHERE sim.ID='".addslashes($simId)."'")->fetch_object(); | ||
if (!$obj) { | ||
closeAndExit($db); | ||
} | ||
|
||
if ($userName != 'alien-project' && $obj->workspace == ALIEN_PROJECT_WORKSPACE_TYPE) { | ||
closeAndExit($db); | ||
} | ||
|
||
$stmt = $db->prepare("UPDATE simulation SET PARTICLES=?, VERSION=?, CONTENT=?, WIDTH=?, HEIGHT=?, SETTINGS=?, SIZE=?, STATISTICS=?, CONTENT2=?, CONTENT3=?, CONTENT4=?, CONTENT5=?, CONTENT6=? WHERE ID=?"); | ||
if (!$stmt) { | ||
closeAndExit($db); | ||
} | ||
|
||
$emptyString = ''; | ||
$stmt->bind_param("issiisissssssi", $particles, $version, $content, $width, $height, $settings, $size, $statistics, $emptyString, $emptyString, $emptyString, $emptyString, $emptyString, $simId); | ||
|
||
if (!$stmt->execute()) { | ||
closeAndExit($db); | ||
} | ||
|
||
// create Discord message | ||
if ($obj->workspace != PRIVATE_WORKSPACE_TYPE) { | ||
$discordPayload = createUpdateResourceMessage($obj->type, $obj->name, $userName, $simDesc, $width, $height, $particles); | ||
sendDiscordMessage($discordPayload); | ||
} | ||
|
||
echo json_encode(["result"=>true]); | ||
|
||
$db->commit(); | ||
$db->close(); | ||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.