mirror of
https://github.com/cyberarm/i-mic-fps.git
synced 2025-12-15 07:32:35 +00:00
Tweaked menus, stubbed multiplayer profile menu, updated readme
This commit is contained in:
24
README.md
24
README.md
@@ -10,11 +10,33 @@ Creating a multiplayer first-person-shooter in pure Ruby; Using C extensions onl
|
|||||||

|

|
||||||
|
|
||||||
## Using
|
## Using
|
||||||
Requires a Ruby runtime that supports the gosu and opengl-bindings C-extensions (truffleruby 1.0.0-rc12 did not work when tested. Rubinus was not tested.)
|
Ruby 2.5+ interpeter with support for the Gosu game library C extension.
|
||||||
* Clone or download this repo
|
* Clone or download this repo
|
||||||
* `bundle install`
|
* `bundle install`
|
||||||
* `bundle exec ruby i-mic-fps.rb [options]`
|
* `bundle exec ruby i-mic-fps.rb [options]`
|
||||||
|
|
||||||
|
### System Requirements
|
||||||
|
| Minimum | |
|
||||||
|
| :------ | ----------------------: |
|
||||||
|
| OS | Windows 10 or GNU/Linux |
|
||||||
|
| CPU | Intel Core i5-3320M |
|
||||||
|
| RAM | 512 MB |
|
||||||
|
| GPU | OpenGL 3.30 Capable |
|
||||||
|
| Storage | To Be Determined |
|
||||||
|
| Network | To Be Determined |
|
||||||
|
| Display | 1280x720 |
|
||||||
|
|
||||||
|
| Recommended | |
|
||||||
|
| :---------- | ----------------------------: |
|
||||||
|
| OS | Windows 10 or GNU/Linux |
|
||||||
|
| CPU | AMD Ryzen 5 3600 |
|
||||||
|
| RAM | 1 GB+ |
|
||||||
|
| GPU | AMD Radeon RX 5700 XT |
|
||||||
|
| Storage | To Be Determined (< 4 GB) |
|
||||||
|
| Network | Broadband Internet Connection |
|
||||||
|
| Display | 1920x1080 60Hz |
|
||||||
|
Note: Recommended CPU and GPU are those of the primary development system and are overkill at this point.
|
||||||
|
|
||||||
### Options
|
### Options
|
||||||
* `--native` - Launch in fullscreen using primary displays resolution
|
* `--native` - Launch in fullscreen using primary displays resolution
|
||||||
* `--profile` - Run ruby-prof profiler
|
* `--profile` - Run ruby-prof profiler
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ class IMICFPS
|
|||||||
end
|
end
|
||||||
|
|
||||||
link "Multiplayer" do
|
link "Multiplayer" do
|
||||||
push_state(MultiplayerLobbyMenu)
|
push_state(MultiplayerMenu)
|
||||||
end
|
end
|
||||||
|
|
||||||
link "Settings" do
|
link "Settings" do
|
||||||
@@ -19,7 +19,7 @@ class IMICFPS
|
|||||||
push_state(ExtrasMenu)
|
push_state(ExtrasMenu)
|
||||||
end
|
end
|
||||||
|
|
||||||
link "Exit Game" do
|
link "Quit" do
|
||||||
window.close
|
window.close
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -4,8 +4,13 @@ class IMICFPS
|
|||||||
title IMICFPS::NAME
|
title IMICFPS::NAME
|
||||||
subtitle "Multiplayer"
|
subtitle "Multiplayer"
|
||||||
|
|
||||||
link "Online"
|
link "Quick Join"
|
||||||
link "LAN"
|
link "Server Browser" do
|
||||||
|
push_state(MultiplayerServerBrowserMenu)
|
||||||
|
end
|
||||||
|
link "Profile" do
|
||||||
|
push_state(MultiplayerProfileMenu)
|
||||||
|
end
|
||||||
link "Back" do
|
link "Back" do
|
||||||
pop_state
|
pop_state
|
||||||
end
|
end
|
||||||
|
|||||||
51
lib/ui/menus/multiplayer_profile_menu.rb
Normal file
51
lib/ui/menus/multiplayer_profile_menu.rb
Normal file
@@ -0,0 +1,51 @@
|
|||||||
|
class IMICFPS
|
||||||
|
class MultiplayerProfileMenu < Menu
|
||||||
|
def setup
|
||||||
|
label "Profile", text_size: 100, color: Gosu::Color::BLACK
|
||||||
|
|
||||||
|
flow(width: 1.0, height: 1.0) do
|
||||||
|
stack(width: 0.25, height: 1.0) do
|
||||||
|
button "Edit Profile", width: 1.0
|
||||||
|
button "Log Out", width: 1.0
|
||||||
|
button "Back", width: 1.0, margin_top: 64 do
|
||||||
|
pop_state
|
||||||
|
end
|
||||||
|
end
|
||||||
|
stack(width: 0.5, height: 1.0) do
|
||||||
|
flow(width: 1.0, padding: 4) do
|
||||||
|
background 0x88_222222
|
||||||
|
|
||||||
|
image "#{GAME_ROOT_PATH}/static/logo.png", width: 64
|
||||||
|
|
||||||
|
stack do
|
||||||
|
label "[Clan TAG] Username", text_size: 36
|
||||||
|
label "\"Title Badge Thingy\""
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
flow(margin_top: 4, margin_right: 4) do
|
||||||
|
stack do
|
||||||
|
label "Kiil/Death Ratio"
|
||||||
|
label "Kills"
|
||||||
|
label "Deaths"
|
||||||
|
label "Assists"
|
||||||
|
label "Buildings Destroyed"
|
||||||
|
label "Vehicles Destroyed"
|
||||||
|
label "Repair Points"
|
||||||
|
end
|
||||||
|
|
||||||
|
stack do
|
||||||
|
label "0.72"
|
||||||
|
label "21"
|
||||||
|
label "28"
|
||||||
|
label "14"
|
||||||
|
label "111"
|
||||||
|
label "41"
|
||||||
|
label "4,451"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
class IMICFPS
|
class IMICFPS
|
||||||
class MultiplayerLobbyMenu < Menu
|
class MultiplayerServerBrowserMenu < Menu
|
||||||
def setup
|
def setup
|
||||||
@sample_games = [
|
@sample_games = [
|
||||||
{
|
{
|
||||||
@@ -28,13 +28,13 @@ class IMICFPS
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
label "Multiplayer Lobby", text_size: 100
|
label "Server Browser", text_size: 100
|
||||||
flow width: 1.0, height: 1.0 do
|
flow width: 1.0, height: 1.0 do
|
||||||
stack width: 0.25 do
|
stack width: 0.25 do
|
||||||
button "Host Game", width: 1.0
|
button "Host Game", width: 1.0
|
||||||
button "Direct Connect", width: 1.0
|
button "Direct Connect", width: 1.0
|
||||||
|
|
||||||
button "Back", width: 1.0 do
|
button "Back", width: 1.0, margin_top: 64 do
|
||||||
pop_state
|
pop_state
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
Reference in New Issue
Block a user