Jump to content
  • Advertisement
  • entries
  • comments
  • views

Engine Updates and More Bugs

Sign in to follow this  


Demo Coming Soon

I was hoping on having a small demo done up and available Sunday, but I royally screwed up the nodes and links (I completely missed a node, which basically broke all of the links) and I've kind of been reluctant to go through and redo them all by hand. I'm planning on spending some time working on the editor so that something like this will be a lot easier to identify and fix (so far I've been doing it via MS Paint and a pad of paper) and the demo will have to wait until after that. I'm not exactly sure how quickly I'll be able to get that done as I don't want to just toss it together.

New Feature - State Variables

This actually isn't all that new; everything was set up, I just hadn't added the ability to interact with them via scripting. Every object in the game has a single state value, an integer, that allows you to tell the state of an object. These are nice, but sometimes are not practical; especially when trying to work with flags between objects. Currently only strings, numbers, and booleans are supported as I don't really think I'll need to store more than that (honestly, only numbers are really needed, but you could do some fun things having strings available too.)

As an example, below is the OnHand() script function from one of the bookshelves in the scene I'm working on. Each of the three has a similar function which basically just has the player say 'Just like the other one' or 'Just like the others' depending on how many have been checked.
function bookshelf1:OnHand()
player:Say('Its completely empty', 3, true)

local BookshelvesChecked = 0
if Engine.CheckStateValue('Bookshelf2Checked', true) then
BookshelvesChecked = BookshelvesChecked + 1

if Engine.CheckStateValue('Bookshelf3Checked', true) then
BookshelvesChecked = BookshelvesChecked + 1

if BookshelvesChecked == 1 then
player:Say('Just like the other one', 3, true)
elseif BookshelvesChecked == 2 then
player:Say('Just like the others', 3, true)

Engine.SetStateValue('Bookshelf1Checked', true)

New Bug - Unreachable Objects are Interactive

The whole point of the linking system is for pathing and connecting paths to objects. An object without a path to it is unreachable and should not be interactive...except they are. As there is no place in the logic that I actually check that an object can be reached, it is reasonable that it still seems like an interactive object. However, I apparently forgot to include logic to cancel out the actual interaction if the object isn't reachable, so basically the character stays put, faces the object, and scripts engage.

Minor Update - Verb Selector Goes Offscreen

Just a minor update that I need to make: the verb selector will appear off screen. Shouldn't be that huge as it should just require some clamping.
[edit] Apparently not as easy as I thought. For some reason clamping the anchor is causing the selector to not always work. [/edit]
[edit] I was explaining the issue to Cierra and came to realization that this is not new, I just had not tested it before. The verb selector works perfectly with the exception that the hovering text doesn't show up after the first time you hover over a verb.[/edit]
[edit] Resolved! I kind of figured that my mouse-enter/mouse-exit system wasn't working properly; the exit wasn't being recognized, so the enter wasn't going to be recognized (first entry worked, but all subsequent entries didn't.) I kind of noticed a symptom of this the other day as the hover text is supposed to disappear as soon as the mouse exits, but it didn't. Anyway, as I said, resolved: the verb controls were only receiving input when the mouse was inside of them. The selector also clamps so that it stays inside the screen. [/edit]

I think I'm off to bed.
Sign in to follow this  


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!