aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine
diff options
context:
space:
mode:
authorCharles Krinke2008-11-19 18:30:16 +0000
committerCharles Krinke2008-11-19 18:30:16 +0000
commit44c56a974c428379ebf82386aac7b7443fd82a7d (patch)
tree5b22c54174a6489563cd2ac79162ada4c6f79ba3 /OpenSim/Region/ScriptEngine
parentAdjust to the Helpers->Utils rename (diff)
downloadopensim-SC-44c56a974c428379ebf82386aac7b7443fd82a7d.zip
opensim-SC-44c56a974c428379ebf82386aac7b7443fd82a7d.tar.gz
opensim-SC-44c56a974c428379ebf82386aac7b7443fd82a7d.tar.bz2
opensim-SC-44c56a974c428379ebf82386aac7b7443fd82a7d.tar.xz
Mantis#2656. Thank you kindly, Nlin for a patch that:
Attached patch implements llCollisionSound. Thanks T. Sado.
Diffstat (limited to 'OpenSim/Region/ScriptEngine')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs18
1 files changed, 17 insertions, 1 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index 968581b..a06ed9b 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -3490,7 +3490,23 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
3490 public void llCollisionSound(string impact_sound, double impact_volume) 3490 public void llCollisionSound(string impact_sound, double impact_volume)
3491 { 3491 {
3492 m_host.AddScriptLPS(1); 3492 m_host.AddScriptLPS(1);
3493 NotImplemented("llCollisionSound"); 3493 //NotImplemented("llCollisionSound");
3494
3495 // TODO: Parameter check logic required.
3496 UUID soundId = UUID.Zero;
3497 if (!UUID.TryParse(impact_sound, out soundId))
3498 {
3499 foreach (TaskInventoryItem item in m_host.TaskInventory.Values)
3500 {
3501 if (item.Type == (int)AssetType.Sound && item.Name == impact_sound)
3502 {
3503 soundId = item.AssetID;
3504 break;
3505 }
3506 }
3507 }
3508 m_host.CollisionSound = soundId;
3509 m_host.CollisionSoundVolume = (float)impact_volume;
3494 } 3510 }
3495 3511
3496 public void llCollisionSprite(string impact_sprite) 3512 public void llCollisionSprite(string impact_sprite)