aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/OptionalModules/Asset/AssetInfoModule.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/OptionalModules/Asset/AssetInfoModule.cs32
1 files changed, 16 insertions, 16 deletions
diff --git a/OpenSim/Region/OptionalModules/Asset/AssetInfoModule.cs b/OpenSim/Region/OptionalModules/Asset/AssetInfoModule.cs
index 7639c6c..906e1ee 100644
--- a/OpenSim/Region/OptionalModules/Asset/AssetInfoModule.cs
+++ b/OpenSim/Region/OptionalModules/Asset/AssetInfoModule.cs
@@ -50,36 +50,36 @@ namespace OpenSim.Region.OptionalModules.Asset
50// private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 50// private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
51 51
52 private Scene m_scene; 52 private Scene m_scene;
53 53
54 public string Name { get { return "Asset Information Module"; } } 54 public string Name { get { return "Asset Information Module"; } }
55 55
56 public Type ReplaceableInterface { get { return null; } } 56 public Type ReplaceableInterface { get { return null; } }
57 57
58 public void Initialise(IConfigSource source) 58 public void Initialise(IConfigSource source)
59 { 59 {
60// m_log.DebugFormat("[ASSET INFO MODULE]: INITIALIZED MODULE"); 60// m_log.DebugFormat("[ASSET INFO MODULE]: INITIALIZED MODULE");
61 } 61 }
62 62
63 public void PostInitialise() 63 public void PostInitialise()
64 { 64 {
65// m_log.DebugFormat("[ASSET INFO MODULE]: POST INITIALIZED MODULE"); 65// m_log.DebugFormat("[ASSET INFO MODULE]: POST INITIALIZED MODULE");
66 } 66 }
67 67
68 public void Close() 68 public void Close()
69 { 69 {
70// m_log.DebugFormat("[ASSET INFO MODULE]: CLOSED MODULE"); 70// m_log.DebugFormat("[ASSET INFO MODULE]: CLOSED MODULE");
71 } 71 }
72 72
73 public void AddRegion(Scene scene) 73 public void AddRegion(Scene scene)
74 { 74 {
75// m_log.DebugFormat("[ASSET INFO MODULE]: REGION {0} ADDED", scene.RegionInfo.RegionName); 75// m_log.DebugFormat("[ASSET INFO MODULE]: REGION {0} ADDED", scene.RegionInfo.RegionName);
76 } 76 }
77 77
78 public void RemoveRegion(Scene scene) 78 public void RemoveRegion(Scene scene)
79 { 79 {
80// m_log.DebugFormat("[ASSET INFO MODULE]: REGION {0} REMOVED", scene.RegionInfo.RegionName); 80// m_log.DebugFormat("[ASSET INFO MODULE]: REGION {0} REMOVED", scene.RegionInfo.RegionName);
81 } 81 }
82 82
83 public void RegionLoaded(Scene scene) 83 public void RegionLoaded(Scene scene)
84 { 84 {
85// m_log.DebugFormat("[ASSET INFO MODULE]: REGION {0} LOADED", scene.RegionInfo.RegionName); 85// m_log.DebugFormat("[ASSET INFO MODULE]: REGION {0} LOADED", scene.RegionInfo.RegionName);
@@ -118,27 +118,27 @@ namespace OpenSim.Region.OptionalModules.Asset
118 MainConsole.Instance.OutputFormat("ERROR: {0} is not a valid ID format", rawAssetId); 118 MainConsole.Instance.OutputFormat("ERROR: {0} is not a valid ID format", rawAssetId);
119 return; 119 return;
120 } 120 }
121 121
122 AssetBase asset = m_scene.AssetService.Get(assetId.ToString()); 122 AssetBase asset = m_scene.AssetService.Get(assetId.ToString());
123 if (asset == null) 123 if (asset == null)
124 { 124 {
125 MainConsole.Instance.OutputFormat("ERROR: No asset found with ID {0}", assetId); 125 MainConsole.Instance.OutputFormat("ERROR: No asset found with ID {0}", assetId);
126 return; 126 return;
127 } 127 }
128 128
129 string fileName = rawAssetId; 129 string fileName = rawAssetId;
130 130
131 if (!ConsoleUtil.CheckFileDoesNotExist(MainConsole.Instance, fileName)) 131 if (!ConsoleUtil.CheckFileDoesNotExist(MainConsole.Instance, fileName))
132 return; 132 return;
133 133
134 using (FileStream fs = new FileStream(fileName, FileMode.CreateNew)) 134 using (FileStream fs = new FileStream(fileName, FileMode.CreateNew))
135 { 135 {
136 using (BinaryWriter bw = new BinaryWriter(fs)) 136 using (BinaryWriter bw = new BinaryWriter(fs))
137 { 137 {
138 bw.Write(asset.Data); 138 bw.Write(asset.Data);
139 } 139 }
140 } 140 }
141 141
142 MainConsole.Instance.OutputFormat("Asset dumped to file {0}", fileName); 142 MainConsole.Instance.OutputFormat("Asset dumped to file {0}", fileName);
143 } 143 }
144 144