This thread is a few years old. Some details may refer to an earlier version of Visionaire Studio. Current tutorials
The free version covers up to 25 scenes per project. For more scenes and to sell your game, you need a license. Until 1 Dec 2026 all licenses are 30 % off, for example the Indie Bundle for €69.30 instead of €99. The code BLACKFRIDAY is applied automatically at checkout.
See licenses Try it for freeAnd is it possible to make a volume of the music based on the distance? Let say there is a guitarist on the street (one big scrolling scene) and he is playing the guitar. When player stands right in front of him, then the music volume is 100%, but when he starts walking away from the guitarist along the street, then the music volume fading away... and player keeps walking off and music is weaker and weaker... 80%.. 70%.. Do you know what I mean? Is it possible to do so in the Visionaire?
--[[
Character sound & property functions (v1.0)
Written by AFRLme
-- * --
label@alternatingfrequencies.com, aim/skype: AFRLme
--]]
function playCharSound(char, sound)
local tbl = {} -- create an empty table
tbl["_temporary_"] = "" -- set table as temporary
tbl["character"] = getObject("Characters[" .. char .. "]") -- store current character
tbl["character_size"] = tbl["character"]:getInt(VCharacterSize) -- get linked characters current scale
tbl["character_pos"] = tbl["character"]:getPoint(VCharacterPosition).x -- get linked characters current x pos
tbl["random_val"] = math.random(-5, 5) -- for adding/subtracting from sound volume (dynamic reasons)
tbl["volume"] = tbl["character_size"] + tbl["random_val"] -- adds or subtracts random value from volume level
tbl["screen_center"] = (game:getPoint(VGameWindowResolution).x / 2) + game:getPoint(VGameScrollPosition).x -- find current scene center x pos
-- * check if position of character to screen center to determine if audio balance % should be a positive or negative value
if tbl["character_pos"] < tbl["screen_center"] then tbl["balance"] = - ((tbl["screen_center"] - tbl["character_pos"]) / (game:getPoint(VGameWindowResolution).x / 2) * 100) end -- inverse balance %
if tbl["character_pos"] >= tbl["screen_center"] then tbl["balance"] = ((tbl["character_pos"] - tbl["screen_center"]) / (game:getPoint(VGameWindowResolution).x / 2) * 100) end -- positive balance %
-- * break * --
startSound(tblSounds[sound][1], {flags=1, volume=tbl["volume"], balance=tbl["balance"]})
-- * debug * --
--print("character name: " .. char .. ", size: " .. tbl["character_size"] .. ", x pos: " .. tbl["character_pos"])
--print("volume: " .. tbl["volume"] .. ", original volume: " .. tbl["character_size"] .. ", random value: " .. tbl["random_val"])
--print("screen center: " .. tbl["screen_center"])
--print("balance: " .. tbl["balance"] .. "\n")
end
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.
Through December 1: all licenses 30% off, for example the Indie Bundle for €69.30 instead of €99. Applied automatically at checkout.