wargroundscanberra:character_sheet
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
wargroundscanberra:character_sheet [2024/08/19 20:34] – curufea | wargroundscanberra:character_sheet [2024/08/30 15:32] (current) – curufea | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Character Sheets ====== | ====== Character Sheets ====== | ||
^ Go back to [[start|Wargrounds Canberra]] | ^ Go back to [[start|Wargrounds Canberra]] | ||
+ | |||
+ | |||
+ | ===== No Longer Used ===== | ||
+ | This project has been superseded by NanDeck (makes it much easier). But I'll keep it on my website just because it was fun to do. | ||
+ | |||
+ | ==== Forms ==== | ||
* Working Form: [[form|Fill in Character Sheet]] | * Working Form: [[form|Fill in Character Sheet]] | ||
* Working Location: [[https:// | * Working Location: [[https:// | ||
- | * Test (Fletching, Character Backgrounds) | + | * Test (same as working) |
* Form: [[form test|Fill in Character Sheet]] | * Form: [[form test|Fill in Character Sheet]] | ||
* Location: [[https:// | * Location: [[https:// | ||
+ | |||
+ | ==== Code ==== | ||
<code php> | <code php> | ||
Line 239: | Line 247: | ||
$im4 = imagecreatefromjpeg($photo); | $im4 = imagecreatefromjpeg($photo); | ||
$ratio = imagesy($im4)/ | $ratio = imagesy($im4)/ | ||
+ | |||
+ | $start_x=round($width/ | ||
+ | $start_y= round($width/ | ||
+ | |||
+ | $i_width= round($width*0.4); | ||
+ | $i_height= round($i_width*$ratio); | ||
+ | |||
+ | $end_x= $start_x+$i_width; | ||
+ | $end_y= $start_y+$i_height; | ||
+ | |||
+ | |||
// Draw border | // Draw border | ||
- | imagefilledrectangle($image, | + | imagefilledrectangle($image, |
// Resize and place in character Sheet | // Resize and place in character Sheet | ||
- | imagecopyresized($image, | + | imagecopyresized($image, |
imagedestroy($im4); | imagedestroy($im4); | ||
- | |||
// tell the browser that the content is an image | // tell the browser that the content is an image | ||
Line 257: | Line 275: | ||
</ | </ | ||
- | ===== To do ===== | ||
- | |||
- | * Possibly API use for wherever photos get stored (or just upload them) - may need to edit photos to fit | ||
wargroundscanberra/character_sheet.1724124855.txt.gz · Last modified: 2024/08/19 20:34 by curufea