Classes

Concepts

Libraries

advertisement »

ambientSounds »

bitser »

contentPoints »

eventBoxText »

factValidity »

frameBuffer »

officeBuildingInserter »

priorityRenderer »

randomEvents »

scaling »

spritesheetParser »

statusIcons »

test3 »

util »

Objects

newSoundData

Description

Register new sound data.

Arguments

1 table data

the sound data to register.

2 number sounds

the amount of sounds that can be played back at once.

Example

-- taken from game/sounds.lua


local data = {}
data.name = "place_object"
data.sound = {"sounds/construction/place_object1.ogg", "sounds/construction/place_object2.ogg"}
data.soundType = "static"
data.looping = false
data.volume = sounds.volume
data.volumeType = sound.VOLUME_TYPES.EFFECTS
data.playAlways = true

register.newSoundData(data)