Compare commits
	
		
			10 Commits
		
	
	
		
			542616cb0b
			...
			51123ecd8e
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 51123ecd8e | |||
| 4d77265b2f | |||
| c91d57f049 | |||
| 8f151836bd | |||
| 9d862011a7 | |||
| d068620c3f | |||
| 6660c11306 | |||
| 1d8896d1ad | |||
| 252c1c244d | |||
| ef3a6026f5 | 
| @ -22,5 +22,7 @@ jobs: | |||||||
|           ls -al target/debian |           ls -al target/debian | ||||||
|           UPLOAD_FILE=$(ls target/debian/*.deb) |           UPLOAD_FILE=$(ls target/debian/*.deb) | ||||||
|           curl --user jlusiardi:${{ secrets.UPLOAD_TOKEN }} --upload-file ${UPLOAD_FILE} https://gitea.intern.haus-in-hirschaid.de/api/packages/jlusiardi/debian/pool/bionic/main/upload           |           curl --user jlusiardi:${{ secrets.UPLOAD_TOKEN }} --upload-file ${UPLOAD_FILE} https://gitea.intern.haus-in-hirschaid.de/api/packages/jlusiardi/debian/pool/bionic/main/upload           | ||||||
|           echo ${DEPLOY_PRIVATE_KEY} > /tmp/ssh_key |           echo -e "${{ secrets.DEPLOY_PRIVATE_KEY }}" > /tmp/ssh_key | ||||||
|           scp -i /tmp/ssh_key ${UPLOAD_FILE} jlusiardi@april2023.lusiardi.de:/var/www/p17.lusiardi.de/el_diabolo |           chmod 0600 /tmp/ssh_key | ||||||
|  |           scp -o StrictHostKeyChecking=no -i /tmp/ssh_key ${UPLOAD_FILE} jlusiardi@april2023.lusiardi.de:/var/www/p17.lusiardi.de/el_diabolo | ||||||
|  |           ssh -o StrictHostKeyChecking=no -i /tmp/ssh_key jlusiardi@april2023.lusiardi.de /var/www/p17.lusiardi.de/el_diabolo/generate_index.sh | ||||||
							
								
								
									
										2
									
								
								Cargo.lock
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										2
									
								
								Cargo.lock
									
									
									
										generated
									
									
									
								
							| @ -147,7 +147,7 @@ checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" | |||||||
| 
 | 
 | ||||||
| [[package]] | [[package]] | ||||||
| name = "el_diabolo" | name = "el_diabolo" | ||||||
| version = "0.2.1" | version = "0.2.2" | ||||||
| dependencies = [ | dependencies = [ | ||||||
|  "crossterm", |  "crossterm", | ||||||
|  "macros", |  "macros", | ||||||
|  | |||||||
| @ -3,7 +3,7 @@ members = ["macros"] | |||||||
| 
 | 
 | ||||||
| [package] | [package] | ||||||
| name = "el_diabolo" | name = "el_diabolo" | ||||||
| version = "0.2.1" | version = "0.2.2" | ||||||
| edition = "2021" | edition = "2021" | ||||||
| 
 | 
 | ||||||
| # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | ||||||
|  | |||||||
| @ -10,9 +10,9 @@ impl Iterator for LevelLadder { | |||||||
|         let current = self.curr; |         let current = self.curr; | ||||||
| 
 | 
 | ||||||
|         self.curr = self.next; |         self.curr = self.next; | ||||||
|         self.next = current + self.next; |         self.next += current; | ||||||
| 
 | 
 | ||||||
|         // Since there's no endpoint to a Fibonacci sequence, the `Iterator` 
 |         // Since there's no endpoint to a Fibonacci sequence, the `Iterator`
 | ||||||
|         // will never return `None`, and `Some` is always returned.
 |         // will never return `None`, and `Some` is always returned.
 | ||||||
|         Some(current * 30) |         Some(current * 30) | ||||||
|     } |     } | ||||||
|  | |||||||
							
								
								
									
										23
									
								
								src/main.rs
									
									
									
									
									
								
							
							
						
						
									
										23
									
								
								src/main.rs
									
									
									
									
									
								
							| @ -14,7 +14,6 @@ use crossterm::{ | |||||||
|     ExecutableCommand, |     ExecutableCommand, | ||||||
| }; | }; | ||||||
| use ratatui::prelude::*; | use ratatui::prelude::*; | ||||||
| use ratatui::widgets::block::{Position, Title}; |  | ||||||
| use ratatui::widgets::{Block, BorderType, Borders, Wrap}; | use ratatui::widgets::{Block, BorderType, Borders, Wrap}; | ||||||
| use ratatui::{ | use ratatui::{ | ||||||
|     prelude::{CrosstermBackend, Terminal}, |     prelude::{CrosstermBackend, Terminal}, | ||||||
| @ -32,12 +31,12 @@ mod constants; | |||||||
| mod game; | mod game; | ||||||
| mod level; | mod level; | ||||||
| mod level_generator; | mod level_generator; | ||||||
|  | mod level_ladder; | ||||||
| mod level_widget; | mod level_widget; | ||||||
| mod monster; | mod monster; | ||||||
| mod player; | mod player; | ||||||
| mod position; | mod position; | ||||||
| mod room; | mod room; | ||||||
| mod level_ladder; |  | ||||||
| 
 | 
 | ||||||
| //
 | //
 | ||||||
| fn main() -> Result<()> { | fn main() -> Result<()> { | ||||||
| @ -101,10 +100,8 @@ fn main() -> Result<()> { | |||||||
|                 height: map_area.height / 2 + 1, |                 height: map_area.height / 2 + 1, | ||||||
|             }; |             }; | ||||||
|             let block = Block::default() |             let block = Block::default() | ||||||
|                 .title( |                 .title_top( | ||||||
|                     Title::from(format!(" {} ", game.get_player().get_name())) |                     Line::from(format!(" {} ", game.get_player().get_name())).centered() | ||||||
|                         .alignment(Alignment::Center) |  | ||||||
|                         .position(Position::Top), |  | ||||||
|                 ) |                 ) | ||||||
|                 .borders(Borders::TOP) |                 .borders(Borders::TOP) | ||||||
|                 .border_style(Style::default().fg(Color::White)) |                 .border_style(Style::default().fg(Color::White)) | ||||||
| @ -134,10 +131,8 @@ fn main() -> Result<()> { | |||||||
|             }; |             }; | ||||||
|             // Display the latest messages from the game to the user
 |             // Display the latest messages from the game to the user
 | ||||||
|             let block = Block::default() |             let block = Block::default() | ||||||
|                 .title( |                 .title_top( | ||||||
|                     Title::from(" messages ") |                     Line::from(" messages ").centered() | ||||||
|                         .alignment(Alignment::Center) |  | ||||||
|                         .position(Position::Top), |  | ||||||
|                 ) |                 ) | ||||||
|                 .borders(Borders::TOP) |                 .borders(Borders::TOP) | ||||||
|                 .border_style(Style::default().fg(Color::White)) |                 .border_style(Style::default().fg(Color::White)) | ||||||
| @ -219,12 +214,8 @@ fn main() -> Result<()> { | |||||||
|             area.width = 40; |             area.width = 40; | ||||||
|             area.height = 20; |             area.height = 20; | ||||||
|             let block = Block::default() |             let block = Block::default() | ||||||
|                 .title( |                 .title_top(Line::from(" Game ended ").centered()) | ||||||
|                     Title::from(" Game ended ") |                 .title_bottom(Line::from("Press `q` to quit!")) | ||||||
|                         .alignment(Alignment::Center) |  | ||||||
|                         .position(Position::Top), |  | ||||||
|                 ) |  | ||||||
|                 .title(Title::from("Press `q` to quit!").position(Position::Bottom)) |  | ||||||
|                 .borders(Borders::ALL) |                 .borders(Borders::ALL) | ||||||
|                 .border_style(Style::default().fg(Color::White)) |                 .border_style(Style::default().fg(Color::White)) | ||||||
|                 .border_type(BorderType::Rounded) |                 .border_type(BorderType::Rounded) | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user