Lua Scripting The UI For Pocket MUD Pro

18
06

2013
05:10

I have just updated my MUD client [Pocket MUD Pro] to be a universal library. It was surprisingly easy to add the iPad support as most of the application was comprised of UITableViews.

The main “MUD” view was the most challenging part as it contains a couple UIWebViews, UIButons, and a UITextField. However, I chose to do something I feel is pretty cool.

Scripting The UI With Lua

If I haven’t said it enough, I love lua. Especially in the context of scripting within other applications. Pocket MUD Pro already has complete lua support in triggers in aliases, so I figured I might as well apply that same logic to the UI.

Pocket MUD Pro has 3 core sections for the UI not counting the text input field. The main view (UIWebview), the prompt view (UIWebview), and the button bar (custom UIView).

One of the core challenges I faced on the iPhone, was resizing/reorienting all of these views on orientation change as well as when the keyboard was visible and when it wasn’t. To be honest, I spent most of my cycles getting this part right. On the iPad, I decided to things a little differently which improved the speed of my development overall and paved the way for future updates that will allow user-scripted UIs.

The UI Script

I want to start by showing you the lua code that is used to script the UI by default.

–MUD
mudFrame = Frame:new("mud_frame")
mudFrame.type = FrameTypeMUD
mudFrame.portraitFrame = {0,0,768,931}
mudFrame.portraitFrameKeyboard = {0,0,768,667}
mudFrame.landscapeFrame = {0,0,1024,675}
mudFrame.landscapeFrameKeyboard = {0,0,1024,323}
createFrame(mudFrame)

What’s happening here is, I have created a Frame class that has some properties (type, name, etc…) and injected it into the global lua space for use inside of the UIScripts. Then when the interface gets drawn, I reference the UI script for each of the MUD servers and use it to render the interface.

One interesting thing here is, I set the frames for each of the possible layout scenarios. Portrait, Landscape, with and without the keyboard. That way, when the keyboard hides/dismisses or the user rotates the device, I just reference the this script again and re-render the frame accordingly. This could have been achieved with auto-resizing masks however, it gets much more complex and things get tricky when you want to have a dynamic number of windows.

I follow this exact pattern for the button frames and the prompt frames. As you might have guessed, in a future release, I will open this script area up to MUDders and give the user the ability to script the interface however they would like. Some examples might be:

  • Dedicated map window
  • Dedicated chat window
  • Customized movement buttons
  • Customized backgrounds/borders/themes
  • Custom health/status/mana

Given this powerful UI Scripting style, a user will be able to create complex interfaces such as the one below from inside the app:

I still have a ways to go with exposing various functionalities via my custom lua bridge. But things seem to be moving along quite smoothly.

If you want to learn how I was able to bridge lua into my application, consider checking out my talk on lua scripting at 360iDev 2012 later this year!

Happy Coding!

iPhone Programming Tutorials

Uncategorized | Tags: ,
No comments

June 16th

17
06

2013
17:35

Since Kommandantin Ligman is off attending the Enormous Explosions Expo or some such, it has again fallen to me, humble foreign correspondent, to bring you the latest in quality games writing. Hold on to your fedoras, it’s This Week In Videogame Blogging.

theletterethreetim.es

Speaking of the Egregious Enthusiasm Expo, Jordan Mammo wrote about corporate claims that new technology fosters creativity and advances storytelling, and the actual bland and samey games offered.

Even this year’s uncontested E3 winner seems a little confused. Speaking to the giddy reception his company was bathed in following its press conference, Sony’s Scott Rohde said that, “In a way it’s a little bit sad in that what we’ve been doing all along gets such a big cheer.”

No kidding. Rohde was referring specifically to Sony’s decision to allow people to continue trading in used games, but he might as well have been talking about next-gen systems in general. As much as some developers have stated the need for new consoles to spur innovation, E3 2013 has been all about wildly different reactions to status quo products.

Meanwhile, Mitch Alexander explains why the rape joke at Microsoft’s press conference was offensive.

Oh, and presumably they also showed some games there, but for all I know this is pretty much what happened.

storytim.es

Continuing the disillusionment over promises of more emotigons, John Walker considered why games might just not be a very good medium for storytelling.

John Walker responded to this ridiculous position and wrote in favor of the narrative capacity of play.

In other narrative news, Mike Joffe wrote about the many and potentially unreliable narrators of Final Fantasy Tactics.

Mark Filipowich on the stories emerging from random mechanics.

videogam.es

The Last of Us came out this week (you might have heard) and Tom Bramwell wrote about it providing an experience that cannot be adequately represented in trailers or short demos.

Tom Bissell is quite smitten by its commitment to storytelling, while Tom Chick loathes the mechanics that get in the way of said plot and Chris Suellentrop wonders if it doesn’t focus on the wrong character, Joel.

Leaving the daily hotness again, Brendan Keogh listed his various thoughts on Max Payne 3.

dangerousdam.es

After HappyPlayTime announced its plans to rebrand female masturbation, Patricia Hernandez wondered about its problematic ‘More is better‘ approach: “What can be seen as “normal” amounts of masturbation? As compared to men?”

Anna Anthropy also had something to say about its notions of sex positivity, and the cissexism of equating women with vaginas.

look through the infographics on the game’s page. look at how masturbation is being framed. “46.6% of women masturbate less than once a month every year. gals, you can do better!” the way to overcome shame is definitely not to shame women for what they don’t do with their bodies. there’s this unfortunate idea of “sex positivity” i encounter all the time that essentially just shames people for not having enough sex and pressures them into doing it more. making masturbation into a universal competition is going to achieve only that: people are going to get pressured into using their bodies in the ways that are arbitrarily defined as normative.

Apps, you can do better.

Assorted Other Things

Rob Rath has some suggestions for how to do a better job of representing muslims.

Denis Farr on queer culture and videogames, specifically Mass Effect.

Jordan Young examining the role of religion in Skyward Sword.

Dale Dobson on videogame doors.

Nina Kiel shaming German games sites with E3 booth babe galleries.

Stephan Günther discovered the perfect game for anybody suffering from Candy Box withdrawal.

Write Us Many Emails Please

That’s it for this week! If you have suggestions for next week and want to rub delicious articles in our faces, you can either hit us up on Twitter or use the email submission form. Make sure to check out the current Blogs of the Round Table prompt over yonder, and stay frosty.

We out.


Critical Distance

Video Game Story Writing | Tags: ,
No comments

Damon Bard website update.

17
06

2013
06:03

Damon Bard has updated his website with some new sculptures from DreamWorks The Croods and other shows he has worked on.  If you haven’t seen his website before, go check it out here… http://www.bardsculpturestudio.com/

Character Design | Artist Interviews

Video Game Character Development | Tags: , , ,
No comments

If There Was Ever A Time To Submit A Show HN Article, It’s Right Now

16
06

2013
18:27

Earlier today a post titled ”I Try to Up Vote Every ‘Show HN’ Post and You Should Too” made it to the top of HN.  It basically talked about people posting “Show HN” posts are putting themselves out there and the least we can do is give them an up vote.  Well, people are listening and as of this posting, there are currently 15 Show HN posts in the top 30.  That’s incredible.

So, if you have recently created something cool.  Head over to HN’s submission page and add your link making sure to add “Show HN” in the title.  You might get some great traffic/feedback out of it.

iPhone Programming Tutorials

Uncategorized | Tags: , , , , , , ,
No comments

Paper Art installations by Yuko Takada Keller

15
06

2013
19:19

Paper Art installations by Yuko Takada Keller

Yuko Takada Keller is a Japanese Artist living in Helsinge, Denmark since 1997. She usually shows her work in different European countries as well as Japan. She also curates some exhibitions to intoduce Japanese artists in Denmark. Yuko Takada Keller uses tracing paper for her art. When in University, she majored in weaving, then after a first trip in Europe she started using paper, looking for a sense of transparency…

Paper Art installations by Yuko Takada Keller
Paper Art installations by Yuko Takada Keller
Paper Art installations by Yuko Takada Keller
Paper Art installations by Yuko Takada Keller
Paper Art installations by Yuko Takada Keller
Paper Art installations by Yuko Takada Keller


Partfaliaz | A selection of illustration and graphic design portfolios

Video Game Graphic Design | Tags: , , , ,
No comments

Angels from Hell by Raid71

13
06

2013
21:03

Angels from Hell by Raid71

Raid71 is Chris Thornley’s online portfolio. He is an illustrator and designer from Darwen, United Kingdom. Angels from Hell is a series of illustrations, (a study of classic motorbikes and their riders) available as a set of prints on artvcancer.com.

Angels from Hell by Raid71
Angels from Hell by Raid71
Angels from Hell by Raid71


Partfaliaz | A selection of illustration and graphic design portfolios

Video Game Graphic Design | Tags: , , ,
No comments

Back To My Roots

12
06

2013
21:56

I wrote my very first blog post back in July of 2008 when I start iCodeBlog.com.  I started the blog because I saw a huge need for iOS development tutorials on the web and really wanted to help others as I progressed in my development.

Well, quite a bit has changed since then.  I have written books, spoken at conferences, and built and shipped over 40 iOS applications.  Since selling iCodeblog in 2009, I have really let my passion for blogging fizzle.  For the first 2 years of the iCode sale, I wasn’t allowed to write tutorials on any other site.  This was very discouraging.

Over the years, I have guest blogged iOS tutorials on several sites including mobile.tutsplus.com and raywenderlich.com.  This has been pretty hit or miss for me.

As of recent, I have become an independent iOS developer and have been solving quite a few hard problems and coming up with some interesting solutions on projects that I have been a part of.  I now want to share some of those solutions with the iOS community in the form of tutorial blog posts.  These come in all shapes in sizes from cool UIKit hacks to building simple backend services.

So, when I say that I want to “get back to my roots”, I really want to start consistently blogging again and educating other developers using the knowledge I have gained over the years.  So stick around, subscribe, follow me, and please don’t hesitate to suggest tutorial ideas.

Happy hacking…

Tweet

iPhone Programming Tutorials

Uncategorized | Tags: ,
No comments

Drawing bold portraits by Todd Borka

12
06

2013
10:20

Drawing bold portraits by Todd Borka

Todd Borka is an illustrator currently working freelance and living in Lyon, France. His line is very bold, drawing or painting people with a quite universal and sometime childish style. His choices are trendy and cool, street art or wall painting, large format and magazine illustration, Todd Borka is comfortable everywhere.

Drawing bold portraits by Todd Borka
Drawing bold portraits by Todd Borka
Drawing bold portraits by Todd Borka
Drawing bold portraits by Todd Borka
Drawing bold portraits by Todd Borka


Partfaliaz | A selection of illustration and graphic design portfolios

Video Game Graphic Design | Tags: , , , ,
No comments

The Style Matters With ATX Wheels

11
06

2013
00:21

ATX rims have created an identity for appearing aesthetically amazing in addition to being well developed. The advantage of the ATX line is that you’re not restricted to one specific overall look or surface finish in terms of choosing the wheels for your vehicle. There is an opportunity to choose between probably the most versatile product lines of rims obtainable when you elect to purchase the ATX selection of wheels.

An excellent option for rough landscape

Something which enables ATX so extremely versatile is the a number of surface finishes that your particular business uses on its own items. There are actually the basic looks that are included with chrome and stainless steel, however this business now offers matte black coatings and even Teflon finishes. If you’re doing a lot of running through the mud utilizing your vehicle, then this Teflon layer can help you save plenty of headaches and it may even help to safeguard your car or truck. Almost all of the Teflon painted rims also offer very encapsulated designs that will keep the dirt, liquid and debris away from your rims and away from important matters just like your brakes.

ATX wheels add design to your vehicle

As soon as you examine an ATX wheel, you can easily note that there’s a lot occurring. This can be a organization that’s not scared to set out styles that have multiple spokes followed by attractive decorations surrounding the outside wheels. If you are planning for a fashionable overall look, then you might as well go the entire way utilizing your appearance and get something which talks to your sense of structure. From the 1st minute which you see these ATX rims, you will know that they can share your perception of style as well as your need to make an argument where you go.

Several layouts

Regardless of whether you get the ATX wheels with the spoke patterns or the much more encapsulated wheels, you’re going to be making an investment in products that will help your vehicle to look good and also will protect your vehicle. There is a lot to be said about a collection of wheels that can countless crucial design factors under consideration.

ATX wheels are the ideal expenditure

The ATX selection of wheels supplies a substantial number of dimensions, styles and coatings here at http://www.hubcap-tire-wheel.com/custom-wheels-rims.html. They’re rims that happen to be manufactured to last for many years. When you invest in a set of these kinds of ATX wheels, you’re investing in something that you definately will take pleasure in for the whole life span of your car or pickup and beyond.

Uncategorized
No comments

Meet Robin Hunicke, Executive Producer on Journey and Co-Founder, Funomena

10
06

2013
12:05

Game Careers was thrilled to chat with game designer and producer Robin Hunicke, perhaps best known for her role as executive producer on blockbuster PSN game Journey. Her game titles include family-friendly franchises like The Sims2, MySims, whimsical online game Glitch and Steven Spielberg’s Boom Blox for Nintendo Wii. She is currently co-founder of the independent game studio, Funomena. There, alongside fellow Journey developer Martin Middleton, she is building a team to work on experimental gameplay projects and games for social good. An artist and computer scientist by training, Robin’s goal is to bring positive, new and unexpected gaming experiences to the public. A passionate advocate of Experimental Gameplay, she organizes the Experimental Gameplay Workshop, and has acted as chair of LA’s annual IndieCade festival. Through her public speaking, volunteer work and academic studies, she evangelizes fresh, broadly-accessible ideas, sustainable work practices and increased diversity in our industry.

Robin offers this suggestion to the Game Careers audience who are considering a career in games: “My best and most important piece of advice to someone who is seeking work in the games industry is to live a full and genuine life…to follow your heart, to have passions, to be curious, to travel. When I look at a resume, I just don’t just look at where they have worked. I look at where they have travelled to, the kinds of things they have built. I want to have a community of peers that isn’t just all about video games. Although those are important, I want to hear about the life you want to live and the world you want to live in.” Watch the full interview in the video that follows:

 

 

Share

Game Careers .BIZ – Games Industry Career Guidance

Video Game Programming | Tags: , , , , , , ,
No comments