diff options
author | Melanie | 2012-01-05 08:15:33 +0000 |
---|---|---|
committer | Melanie | 2012-01-05 08:15:33 +0000 |
commit | 1ebc9d04aa33e18e22ee2f03465bc5950c3544ce (patch) | |
tree | 3e7e39255ad455b59434979d47db7da243ac3dd6 /OpenSim/Region/OptionalModules | |
parent | Merge branch 'master' into careminster (diff) | |
parent | Merge branch 'master' of melanie@opensimulator.org:/var/git/opensim (diff) | |
download | opensim-SC-1ebc9d04aa33e18e22ee2f03465bc5950c3544ce.zip opensim-SC-1ebc9d04aa33e18e22ee2f03465bc5950c3544ce.tar.gz opensim-SC-1ebc9d04aa33e18e22ee2f03465bc5950c3544ce.tar.bz2 opensim-SC-1ebc9d04aa33e18e22ee2f03465bc5950c3544ce.tar.xz |
Merge branch 'master' into careminster
Conflicts:
OpenSim/Region/CoreModules/Avatar/AvatarFactory/AvatarFactoryModule.cs
OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
Diffstat (limited to 'OpenSim/Region/OptionalModules')
-rw-r--r-- | OpenSim/Region/OptionalModules/Avatar/Appearance/AppearanceInfoModule.cs | 40 |
1 files changed, 39 insertions, 1 deletions
diff --git a/OpenSim/Region/OptionalModules/Avatar/Appearance/AppearanceInfoModule.cs b/OpenSim/Region/OptionalModules/Avatar/Appearance/AppearanceInfoModule.cs index 1ce24f1..7e15718 100644 --- a/OpenSim/Region/OptionalModules/Avatar/Appearance/AppearanceInfoModule.cs +++ b/OpenSim/Region/OptionalModules/Avatar/Appearance/AppearanceInfoModule.cs | |||
@@ -114,6 +114,16 @@ namespace OpenSim.Region.OptionalModules.Avatar.Appearance | |||
114 | "Send appearance data for each avatar in the simulator to other viewers.", | 114 | "Send appearance data for each avatar in the simulator to other viewers.", |
115 | "Optionally, you can specify that only a particular avatar's appearance data is sent.", | 115 | "Optionally, you can specify that only a particular avatar's appearance data is sent.", |
116 | HandleSendAppearanceCommand); | 116 | HandleSendAppearanceCommand); |
117 | |||
118 | scene.AddCommand( | ||
119 | this, "appearance rebake", | ||
120 | "appearance rebake <first-name> <last-name>", | ||
121 | "Send a request to the user's viewer for it to rebake and reupload its appearance textures.", | ||
122 | "This is currently done for all baked texture references previously received, whether the simulator can find the asset or not." | ||
123 | + "\nThis will only work for texture ids that the viewer has already uploaded." | ||
124 | + "\nIf the viewer has not yet sent the server any texture ids then nothing will happen" | ||
125 | + "\nsince requests can only be made for ids that the client has already sent us", | ||
126 | HandleRebakeAppearanceCommand); | ||
117 | } | 127 | } |
118 | 128 | ||
119 | private void HandleSendAppearanceCommand(string module, string[] cmd) | 129 | private void HandleSendAppearanceCommand(string module, string[] cmd) |
@@ -210,6 +220,34 @@ namespace OpenSim.Region.OptionalModules.Avatar.Appearance | |||
210 | } | 220 | } |
211 | } | 221 | } |
212 | } | 222 | } |
213 | } | 223 | } |
224 | |||
225 | private void HandleRebakeAppearanceCommand(string module, string[] cmd) | ||
226 | { | ||
227 | if (cmd.Length != 4) | ||
228 | { | ||
229 | MainConsole.Instance.OutputFormat("Usage: appearance rebake <first-name> <last-name>"); | ||
230 | return; | ||
231 | } | ||
232 | |||
233 | string firstname = cmd[2]; | ||
234 | string lastname = cmd[3]; | ||
235 | |||
236 | lock (m_scenes) | ||
237 | { | ||
238 | foreach (Scene scene in m_scenes.Values) | ||
239 | { | ||
240 | ScenePresence sp = scene.GetScenePresence(firstname, lastname); | ||
241 | if (sp != null && !sp.IsChildAgent) | ||
242 | { | ||
243 | MainConsole.Instance.OutputFormat( | ||
244 | "Requesting rebake of uploaded textures for {0}", | ||
245 | sp.Name, scene.RegionInfo.RegionName); | ||
246 | |||
247 | scene.AvatarFactory.RequestRebake(sp, false); | ||
248 | } | ||
249 | } | ||
250 | } | ||
251 | } | ||
214 | } | 252 | } |
215 | } \ No newline at end of file | 253 | } \ No newline at end of file |