• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 10:44
CEST 16:44
KST 23:44
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
Code S RO8 Preview: herO, Zoun, Bunny, Classic7Code S RO8 Preview: Rogue, GuMiho, Solar, Maru3BGE Stara Zagora 2025: Info & Preview27Code S RO12 Preview: GuMiho, Bunny, SHIN, ByuN3The Memories We Share - Facing the Final(?) GSL47
Community News
BGE Stara Zagora 2025 - Replay Pack2Weekly Cups (June 2-8): herO doubles down1[BSL20] ProLeague: Bracket Stage & Dates9GSL Ro4 and Finals moved to Sunday June 15th13Weekly Cups (May 27-June 1): ByuN goes back-to-back0
StarCraft 2
General
The SCII GOAT: A statistical Evaluation Jim claims he and Firefly were involved in match-fixing Code S RO8 Preview: herO, Zoun, Bunny, Classic DreamHack Dallas 2025 - Official Replay Pack BGE Stara Zagora 2025 - Replay Pack
Tourneys
[GSL 2025] Code S: Season 2 - Ro8 - Group B [GSL 2025] Code S: Season 2 - Ro8 - Group A RSL: Revival, a new crowdfunded tournament series SOOPer7s Showmatches 2025 Sparkling Tuna Cup - Weekly Open Tournament
Strategy
[G] Darkgrid Layout Simple Questions Simple Answers [G] PvT Cheese: 13 Gate Proxy Robo
Custom Maps
[UMS] Zillion Zerglings
External Content
Mutation # 477 Slow and Steady Mutation # 476 Charnel House Mutation # 475 Hard Target Mutation # 474 Futile Resistance
Brood War
General
BGH auto balance -> http://bghmmr.eu/ FlaSh Witnesses SCV Pull Off the Impossible vs Shu BW General Discussion StarCraft & BroodWar Campaign Speedrun Quest Will foreigners ever be able to challenge Koreans?
Tourneys
[ASL19] Grand Finals [BSL20] GosuLeague RO16 - Tue & Wed 20:00+CET NA Team League 6/8/2025 [Megathread] Daily Proleagues
Strategy
I am doing this better than progamers do. [G] How to get started on ladder as a new Z player
Other Games
General Games
Path of Exile Stormgate/Frost Giant Megathread Nintendo Switch Thread Beyond All Reason What do you want from future RTS games?
Dota 2
Official 'what is Dota anymore' discussion
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Heroes of StarCraft mini-set
TL Mafia
TL Mafia Community Thread Vanilla Mini Mafia
Community
General
UK Politics Mega-thread US Politics Mega-thread Things Aren’t Peaceful in Palestine Russo-Ukrainian War Thread Vape Nation Thread
Fan Clubs
Maru Fan Club Serral Fan Club
Media & Entertainment
Korean Music Discussion [Manga] One Piece
Sports
TeamLiquid Health and Fitness Initiative For 2023 2024 - 2025 Football Thread Formula 1 Discussion NHL Playoffs 2024
World Cup 2022
Tech Support
Computer Build, Upgrade & Buying Resource Thread
TL Community
The Automated Ban List
Blogs
A Better Routine For Progame…
TrAiDoS
StarCraft improvement
iopq
Heero Yuy & the Tax…
KrillinFromwales
I was completely wrong ab…
jameswatts
Need Your Help/Advice
Glider
Trip to the Zoo
micronesia
Customize Sidebar...

Website Feedback

Closed Threads



Active: 28703 users

Student Game Dev Part Seven - User Interface

Blogs > Soan
Post a Reply
Soan
Profile Blog Joined August 2010
New Zealand194 Posts
January 10 2014 06:14 GMT
#1
Part One - It begins
Part Two - Technical Foundation
Part Three - Game Design
Part Four - Input and Physics
Part Five - More Physics Things
Part Six - Even More Physics

This Week
Hello again TeamLiquid!

Welcome back to my blog about the development of The Adventures of Sam the Pirate, the 2D platformer I'm creating as the final game project for my Bachelor of Software Engineering degree. Hope you all had a great Christmas and New Years, I spent far too much time playing Hearthstone, a bit of Civ5, and spending time with my family to do any work. I have managed to get a bit of work done on some user interface related things over this past week, and have a new piece of concept art to show off today as well. I had some thoughts over the holidays on fixing the remaining physics issues, but have not got around to implementing any of them yet.

User Interface
Most of the work done on the user interface so far has been pretty basic low level stuff, setting up for the more interesting stuff later. At the moment, an interface layout will be stored in a file, and be loaded when needed. When the player forces the displayed interface to change, through starting a game from the main menu for example, the displayed interface will simply be switched. In the case of opening a menu while in a level with the level interface displayed, I'll be able to directly force an separate interface to be displayed over the top of that. So basically I'll have interface layouts stored in different files, and be able to display multiple layouts at once.

As well as creating the basics mentioned above, I've created a generic button class, with normal, hover, and click states. Creating this generic class has given me a little bit of a problem however. If I want to create multiple buttons that each take different actions, I'll have to create extra class, each inheriting from the generic button class. While this would work, I don't really want to do it as it is inefficient, and I want the user interface system to be fairly generic, so I can more easily reuse it in future projects. As I've used Lua scripting on my debug console, allowing me to add commands without changing code, I'm considering doing something similar here. As the interface layouts are stored in files, I could also store the name of a Lua file, and function within that file for each button, allowing me to ensure that each button has unique functionality without creating tons of different classes. Still thinking about how best to implement this however, so we'll see how it goes.

The user interface system in general will also need to scale based on display resolution. I have a target resolution of 1920x1080 (art will be created with this resolution in mind), but it's unrealistic to assume that everyone uses that resolution. It should be relatively easy to compare the resolution the game is running in, with the target resolution, and make adjustments based on that.

New Concept Art
[image loading]

What's next?
Officially back to class next week, where we'll also be getting a new capstone assignment. We finished a research based capstone before Christmas, and this new capstone will be development focused. With any luck, I'll be able to use the capstone to create a level editor, which I was planning to do already! I have a feeling the tutors might want me to do a bit more though, so I'm also considering turning it into more of a general engine editor. So as well as creating levels, it'd be able to create interface layouts, preview sprites in the game engine, etc. It would certainly make things easier, as currently levels and interface layouts are created by hand in text files!

So until Monday, and I know what I'm doing on the capstone, I won't know 100% what I'll be working on next. Likely I'll be continuing with the user interface stuff, planning out the level editor, and continuing to adjust/fix the physics.

Keep up to date!
Be sure to follow me on Twitter, and like the Facebook page to stay up to date on future content and blog posts when they happen. If you have any questions don't hesitate to ask, either through Twitter or Facebook!

****
MrShankly
Profile Blog Joined October 2009
United Kingdom371 Posts
January 10 2014 22:44 GMT
#2
Never noticed your blog before! Rated 5 stars!

I graduated as games programmer but I switched to doing regular software development. At the moment I work for a company that builds 3d Visualisations for mobile tablets and stuff so i still get to use my 3D/gfx skills and do regular mobile Dev.

Sometimes I kinda miss working on games though. I'm currently building an iOS app in my spare time. Maybe when it is done I will try build a game.
DONATE SC2 BETA KEY TO ME PLEASE
Yferi
Profile Joined April 2010
United States90 Posts
January 14 2014 09:59 GMT
#3
For your buttons, you could use the observer model and have all classes that you want to respond to the button click implement a certain function (like onButtonClicked() or something). When you create the button, register each listener and when the button is clicked, call the onButtonClicked() method for each listener. That way, what the button does (receiving input) is decoupled from your listeners (doing stuff once you've received input).

By the way, it would be cool if you could post some videos/screenshots of your game so far. Keep up the work!
Soan
Profile Blog Joined August 2010
New Zealand194 Posts
January 15 2014 19:24 GMT
#4
haha, I totally forgot about using the Observer pattern like that. I'm using it elsewhere in the project, so I did know it existed, just didn't occur to me to use it like that, even though I've seen it used elsewhere. Ended up going with a similar Lua implementation to what I used for my debug console, and I'll probably talk about it in this weeks blog.

I do want to do videos/screenshots of the game, but there isn't much to look at at the moment. Currently the tiles and character are just white boxes with black letters to indicate what type of tile/what animation should be playing.
Please log in or register to reply.
Live Events Refresh
Next event in 6h 17m
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
Harstem 304
Hui .277
trigger 240
ProTech105
StarCraft: Brood War
Calm 11220
Sea 3627
Hyuk 3088
Snow 499
Light 384
Stork 269
Soulkey 217
Zeus 142
PianO 126
Rush 52
[ Show more ]
TY 50
ToSsGirL 46
sorry 40
hero 40
Nal_rA 28
Noble 19
scan(afreeca) 17
Yoon 16
Terrorterran 13
IntoTheRainbow 11
HiyA 10
zelot 7
Dota 2
Gorgc5636
qojqva3210
syndereN414
Fuzer 257
League of Legends
Dendi859
Counter-Strike
fl0m985
olofmeister867
Foxcn188
Heroes of the Storm
Khaldor120
Other Games
singsing3081
B2W.Neo1396
FrodaN573
C9.Mang0569
crisheroes448
DeMusliM323
Beastyqt283
Mlord206
Mew2King146
ArmadaUGS127
XaKoH 106
elazer95
KnowMe42
Organizations
StarCraft 2
WardiTV675
Other Games
BasetradeTV16
StarCraft: Brood War
Kim Chul Min (afreeca) 6
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 16 non-featured ]
StarCraft 2
• poizon28 25
• AfreecaTV YouTube
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
Dota 2
• C_a_k_e 3421
• lizZardDota239
League of Legends
• Nemesis6022
• Jankos2410
• TFBlade891
Upcoming Events
OSC
6h 17m
ArT vs ReBellioN
HonMonO vs Ziomek
Shameless vs LunaSea
MilkiCow vs GgMaChine
Moja vs HiGhDrA
Jumy vs TBD
Demi vs NightPhoenix
Solar vs Cham
Replay Cast
9h 17m
OSC
9h 17m
WardiTV Invitational
20h 17m
OSC
22h 17m
Korean StarCraft League
1d 12h
SOOP
1d 18h
sOs vs Percival
CranKy Ducklings
1d 19h
WardiTV Invitational
1d 20h
Cheesadelphia
2 days
[ Show More ]
CSO Cup
2 days
GSL Code S
2 days
Rogue vs herO
Classic vs GuMiho
Sparkling Tuna Cup
2 days
Replay Cast
3 days
Wardi Open
3 days
Replay Cast
4 days
Replay Cast
4 days
RSL Revival
4 days
Cure vs Percival
ByuN vs Spirit
RSL Revival
5 days
herO vs sOs
Zoun vs Clem
Replay Cast
6 days
The PondCast
6 days
RSL Revival
6 days
Serral vs SHIN
Solar vs Cham
Liquipedia Results

Completed

CSL Season 17: Qualifier 2
BGE Stara Zagora 2025
Heroes 10 EU

Ongoing

JPL Season 2
BSL 2v2 Season 3
BSL Season 20
KCM Race Survival 2025 Season 2
NPSL S3
Rose Open S1
CSL 17: 2025 SUMMER
2025 GSL S2
BLAST.tv Austin Major 2025
ESL Impact League Season 7
IEM Dallas 2025
PGL Astana 2025
Asian Champions League '25
BLAST Rivals Spring 2025
MESA Nomadic Masters
CCT Season 2 Global Finals
IEM Melbourne 2025
YaLLa Compass Qatar 2025
PGL Bucharest 2025
BLAST Open Spring 2025

Upcoming

Copa Latinoamericana 4
CSLPRO Last Chance 2025
CSLPRO Chat StarLAN 3
K-Championship
SEL Season 2 Championship
Esports World Cup 2025
HSC XXVII
Championship of Russia 2025
Murky Cup #2
Esports World Cup 2025
BLAST Bounty Fall 2025
BLAST Bounty Fall Qual
IEM Cologne 2025
FISSURE Playground #1
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2025 TLnet. All Rights Reserved.