This thread is a few years old. Some details may refer to an earlier version of Visionaire Studio. Current tutorials
function Myaction(mousePos)
local obj = game:getLink(VGameCurrentObject)
local verb = game:getLink(VGameActiveCommand):getTextStr(VButtonName)
local obj_name = obj:getTextStr(VObjectName)
local targetObjPoint = game:getObject("Characters[Akio]"):getPoint(VCharacterDestinationObject)
if (verb ~= null and game.SavedObject:isEmpty()) then
return verb .. ' ' .. obj_name
else
-- check if character destination object and current position are the same
return 'my custom phrase'
end
end
registerHookFunction("getActionText", "Myaction")Save Object
if object below cursor exist
Execute command on saved object
end if
Save Object
if object below cursor exist
Wait for character to stop
Execute command on saved object
end if..but... (yeah yeah, there is a bug).Not a bug. Unless you use execute immediate commands & begin/end cutscene or hide/show cursor wrappers then the player reserves the right to cancel their current order by left or right clicking anywhere else on the scene.If you clik on an object/character while your character is moving,the action will be perfomed on the second-click target.
if object below cursor exists
Save Object
Execute command on saved object
Wait until character 'Current character' stops
Clear saved object
Set standard command
Else
Clear saved object
Set standard command
End iflocal activateFont = getObject("Fonts[Font_Action_Diag_Highlight]")
local action_interface = getObject("Interfaces[Action_Text_Area]")
action_interface:setValue(VInterfaceActionTextFont, activateFont)local activateFont = getObject("Fonts[Font_Action_Diag]")
local action_interface = getObject("Interfaces[Action_Text_Area]")
action_interface:setValue(VInterfaceActionTextFont, activateFont)
Call script 'blink'
if object below cursor exists
Save Object
Execute command on saved object
Wait until character 'Current character' stops
Clear saved object
Set standard command
Else
Clear saved object
Set standard command
End if
Call script 'blonk'This thread is closed because nobody has replied for more than a year. Feel free to ask your question in a new thread.
New threadDeponia, The Whispered World and more than 160 other games were made with Visionaire Studio. The free version covers up to 25 scenes. For more scenes there is Visionaire Studio PRO from €75, and to sell your game the Indie Bundle for €99.
Until December 1: the Indie Bundle is 30% off with the code BLACKFRIDAY, €69.30 instead of €99.