Theoretical Gameplay and Lua Script Ideas

From The Official Visionaire Studio: Adventure Game Engine Wiki

I have decided to set up a page for me to post (& possibly muse over) potential Lua Script & Gameplay functions & ideas for Visionaire Studio.


Character

Collision detection

I have been contemplating on whether or not it would be too difficult to add a bit of basic collision detection for characters. If I were to add some border or non-walkable object around a character & then have the border/object polygon move with the character, would it force the current character to walk around the other character?

Even the early games by Revolution Soft. in the early 90's such as "Lure of the Temptress", "Beneath a steel sky" & "Broken Sword" featured collision detection of a sort. In Lure of the Temptress for example: if the main player & an npc came into contact then they would stop, exchange some kind of greeting or one would step aside or walk around the other - this of course should also be noted in regards to basic character AI below. In Divo's drag & drop script he has managed to make an objects polygon move with the object while you are dragging the objects animation around the screen & thus I am wondering if I could do something similar with the characters...


Basic AI

Basic character AI for npc characters can already be done with the use of conditions, values & if queries; like for instance: when you interact with an npc that is currently talking to another npc or is currently doing something on screen & you have to wait until the action/animation has finished before the dialog or interaction can begin. Now I am thinking more in terms of having the npc's choose a random destination from x amount of choices & then have them do some kind of action/animation at said destination & then have them wait for x amount of time & choose another random destination etc to give the game a sense of something more natural, realistic rather than having static npc's scattered about here & there in a scene. I was thinking that Divo's random flight script could be particularly useful in achieving this, as in the script he had a parrot randomly choose from a list of destinations & then it performed a take off animation & then a flying animation while flying & then change to a landing then perched animation when it reached said destination & waited for a random amount of time before moving on to another destination.


Character Rotation

I believe that with a bit of Lua trickery & controlling the character animation frames that we could probably add character rotation support into a game. I am not sure if it would be possible to create fluid rotation movement while a character is currently walking but it could quite easily be done before a character sets off walking. My theory on fluid rotation while a character is walking & drastically changes course, would be to store the current walk animation frame value & then slow the character speed down to about a 3rd or a quarter of current walking speed & then force the frame value of each direction so that it doesn't play/reset the animation while we make the character rotate.


Begin/End Walk Animation

I believe that we could could control the characters walk cycle by forcing the first & last animation frame values & then using a query to check what frame we got to when the character stopped & quickly play x animation from x point based on which leg the character ended the walk on. The same could be said about forcing character walk based on individual leg movement by controlling the frames that are playing & whether or not character is still walking when it gets to x frame & if so then move onto the next leg animation & rinse & repeat.


Environment

Crowd Control

One of the things I have noticed in point & click games is that the vast majority of them only contain a handful of characters of which most of them are static & pretty much 99% of them can be interacted with due to them factoring into the games storyline in some way or other. Take for instance Broken Sword 5, - I have no bloody idea what they were thinking - which had only a handful of scenes but featured hardly any background animations or human/car traffic in the outside scenes which made the game feel flat & lifeless. I think that open world games such as the GTA or Assassin's Creed franchise do really well in creating a living, breathing world in which we, the players can immerse ourselves into as pretty much all the people can be interacted with in some way or other. In GTA you can talk to, push & attack people etc & in Assassin's Creed games you can shove people aside, pick pocket them, collide with them & knock whatever they might be carrying out of their hands. I'm not saying that adventure games should contain this amount of detail but it would make the games more interesting if we had more non-interactive npc's walking about certain scenes performing everyday trivial life stuff. If I remember correctly, then Revolution Soft. first game "Lure of the Temptress" featured this to a degree with characters randomly walking around the screen. (See my reference to Lure of the Temptress, in regards to collision detection above)