Hi all! I've always been fascinated with text interfaces, so I decided my next (well first real) game should be an interactive text adventure. In doing this I implemented a complete terminal emulator! As of now its not easily embedable inside another game, however if there is enough interest I might work on that (a la quake terminal perhaps).
Update 3/31/14:
Made some huge improvements to the handling of the terminal and completely changed the tech demo. The terminal is now custom sizable so my demo now showcases how to implement a quake style drop-down terminal. Use the tab key to activate and deactivate the terminal. I have implemented one valid command: set. You can use this to change the values of the bouncing ball object like so:
set ball.xVel 100
The ball has an x, y, r (radius), xVel, yVel values that you can change using the set command. Any other input will just bring up the list of commands.
The one main bug is that the input line is not wrapped to the terminal width like the output is. I will hopefully have this fixed soon.
Update 4/4/14:
This is just about a full featured terminal emulator now! Output scrolling and line breaking is handled better, the input line supports overflow if you type beyond the terminal width, and output text scrolling can be disabled if you don't want it. I also added some basic comments for usability, but it still needs a wiki.
Demo now supports: set outputScrolling [true, false]
Grab it on bitbucket: https://bitbucket.org/draetheus/lovetty
LOVE Terminal Emulator
LOVE Terminal Emulator
Last edited by Draetheus on Fri Apr 04, 2014 9:38 pm, edited 3 times in total.
-
- Party member
- Posts: 712
- Joined: Fri Jun 22, 2012 4:54 pm
- Contact:
Re: LOVE Terminal Emulator
Hi,
It's looking nice!
I had to open the scripts to find out what you meant by "try killing". Coming from Linux, I am used to "killing" being CTRL+X or CTRL+Q or typing q and then enter (for "quit") and none of those worked.
Two other things I'd implement if I were you: You definitely should print something when "help" is entered. Even if it's just a welcome text... it feels weird when no help is printed. Maybe you should wait until you have more commands running though - then you can actually display the commands.
The easter egg appears before I press enter. That's weird - a console should not respond before I press enter.
The typing effect looks really nice. For using it in a "real" terminal kind of way, that would be somewhat annoying, but for a game this can work out really well.
Looking forward to seeing more about your game!
It's looking nice!
I had to open the scripts to find out what you meant by "try killing". Coming from Linux, I am used to "killing" being CTRL+X or CTRL+Q or typing q and then enter (for "quit") and none of those worked.
Two other things I'd implement if I were you: You definitely should print something when "help" is entered. Even if it's just a welcome text... it feels weird when no help is printed. Maybe you should wait until you have more commands running though - then you can actually display the commands.
The easter egg appears before I press enter. That's weird - a console should not respond before I press enter.
The typing effect looks really nice. For using it in a "real" terminal kind of way, that would be somewhat annoying, but for a game this can work out really well.
Looking forward to seeing more about your game!
trAInsported - Write AI to control your trains
Bandana (Dev blog) - Platformer featuring an awesome little ninja by Micha and me
GridCars - Our jam entry for LD31
Germanunkol.de
Bandana (Dev blog) - Platformer featuring an awesome little ninja by Micha and me
GridCars - Our jam entry for LD31
Germanunkol.de
Re: LOVE Terminal Emulator
Thanks for the feedback! I may end up implementing some more keyboard commands, especially copy paste now that LOVE supports grabbing the clipboard.
This is just a tech demo, so basically all it does is echo your input. Its up to the person implementing it in their game what commands to listen for and parse. Also that's the point of the easter egg: to do something you don't expect. My game is going to be a very out of the box text adventure with lots of whacky OMG moments.
This is just a tech demo, so basically all it does is echo your input. Its up to the person implementing it in their game what commands to listen for and parse. Also that's the point of the easter egg: to do something you don't expect. My game is going to be a very out of the box text adventure with lots of whacky OMG moments.
Re: LOVE Terminal Emulator
I too thought it was a little odd that the easter egg started running before I pressed return, also random text and then entering the command worked too.
I was contemplating something like this as the "ships computer" for my game, so I threw it into the game using my set font, looked good! Was actually pretty simple to integrate, just localized terminal, and the callbacks in main.lua.
I like the simplicity of the design, maybe use a list and commands as keys so you can get the most out of the commands.
I was contemplating something like this as the "ships computer" for my game, so I threw it into the game using my set font, looked good! Was actually pretty simple to integrate, just localized terminal, and the callbacks in main.lua.
I like the simplicity of the design, maybe use a list and commands as keys so you can get the most out of the commands.
Re: LOVE Terminal Emulator
Shameless self promotion bump for my update! I'm also calling the project LOVETTY now.
-
- Prole
- Posts: 1
- Joined: Tue Apr 01, 2014 2:12 pm
Re: LOVE Terminal Emulator
Gonna have to try this after I get LÖVE 0.9.0 compiled.
Re: LOVE Terminal Emulator
This terminal is a great idea and it can be very useful not only for end-users but as a development tool as well. For instance logging/printing (especially with the current version of love for android which doesn't have console output) or debugging your game.
Re: LOVE Terminal Emulator
There is currently no way to make it function as an output only device like a debugging console, however if there is demand I could make the appropriate changes. I'm thinking about putting it up on bitbucket if enough people want to use it.Izzo wrote:This terminal is a great idea and it can be very useful not only for end-users but as a development tool as well. For instance logging/printing (especially with the current version of love for android which doesn't have console output) or debugging your game.
Re: LOVE Terminal Emulator
Bump for update, nearing production ready I think!
Re: LOVE Terminal Emulator
The link no longer works.
Who is online
Users browsing this forum: No registered users and 1 guest