diff options
author | alondria | 2008-01-31 06:59:48 +0000 |
---|---|---|
committer | alondria | 2008-01-31 06:59:48 +0000 |
commit | 62ae3c9bf58ec5e1d9d1e2ce125f662f1994b41f (patch) | |
tree | 2942655d37bea6d64d2c79af56a0322d771c4a6f | |
parent | * Add asset/texture cache statistics to region server console (diff) | |
download | opensim-SC_OLD-62ae3c9bf58ec5e1d9d1e2ce125f662f1994b41f.zip opensim-SC_OLD-62ae3c9bf58ec5e1d9d1e2ce125f662f1994b41f.tar.gz opensim-SC_OLD-62ae3c9bf58ec5e1d9d1e2ce125f662f1994b41f.tar.bz2 opensim-SC_OLD-62ae3c9bf58ec5e1d9d1e2ce125f662f1994b41f.tar.xz |
Hit a dead end with llParticleSystem (libsecondlife issues) so no functionality added yet, but did not want to loose work.
3 files changed, 50 insertions, 25 deletions
diff --git a/OpenSim/Region/ScriptEngine/Common/LSL_BaseClass.cs b/OpenSim/Region/ScriptEngine/Common/LSL_BaseClass.cs index bd64ee0..7073830 100644 --- a/OpenSim/Region/ScriptEngine/Common/LSL_BaseClass.cs +++ b/OpenSim/Region/ScriptEngine/Common/LSL_BaseClass.cs | |||
@@ -1322,7 +1322,7 @@ namespace OpenSim.Region.ScriptEngine.Common | |||
1322 | // | 1322 | // |
1323 | // DO NOT MODIFY HERE: MODIFY IN LSL_BuiltIn_Commands.cs | 1323 | // DO NOT MODIFY HERE: MODIFY IN LSL_BuiltIn_Commands.cs |
1324 | // | 1324 | // |
1325 | public void llParticleSystem(List<Object> rules) | 1325 | public void llParticleSystem(LSL_Types.list rules) |
1326 | { | 1326 | { |
1327 | m_LSL_Functions.llParticleSystem(rules); | 1327 | m_LSL_Functions.llParticleSystem(rules); |
1328 | } | 1328 | } |
diff --git a/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs b/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs index 7fce827..9cdec11 100644 --- a/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs +++ b/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs | |||
@@ -2139,95 +2139,120 @@ namespace OpenSim.Region.ScriptEngine.Common | |||
2139 | PSYS_SRC_ANGLE_END = 23 | 2139 | PSYS_SRC_ANGLE_END = 23 |
2140 | } | 2140 | } |
2141 | 2141 | ||
2142 | public void llParticleSystem(List<Object> rules) | 2142 | // AL: This does not actually do anything yet. There are issues within Libsecondlife revolving around PSYS_PART_FLAGS |
2143 | // (need to OR the values, but currently stores this within an enum) as well as discovery of how the CRC works and the | ||
2144 | // actual packet. | ||
2145 | public void llParticleSystem(LSL_Types.list rules) | ||
2143 | { | 2146 | { |
2144 | Primitive.ParticleSystem prules = new Primitive.ParticleSystem(); | 2147 | Primitive.ParticleSystem prules = new Primitive.ParticleSystem(); |
2145 | for (int i = 0; i < rules.Count; i += 2) | 2148 | LSL_Types.Vector3 tempv = new LSL_Types.Vector3(); |
2149 | |||
2150 | for (int i = 0; i < rules.Length; i += 2) | ||
2146 | { | 2151 | { |
2147 | switch ((int)rules[i]) | 2152 | switch ((int)rules.Data[i]) |
2148 | { | 2153 | { |
2149 | case (int)LSL_BaseClass.PSYS_PART_FLAGS: | 2154 | case (int)LSL_BaseClass.PSYS_PART_FLAGS: |
2150 | prules.PartFlags = (uint)rules[i + 1]; | 2155 | prules.PartFlags = (uint)rules.Data[i + 1]; |
2151 | break; | 2156 | break; |
2152 | 2157 | ||
2153 | case (int)LSL_BaseClass.PSYS_PART_START_COLOR: | 2158 | case (int)LSL_BaseClass.PSYS_PART_START_COLOR: |
2154 | prules.PartStartColor = (LLColor)rules[i + 1]; | 2159 | tempv = (LSL_Types.Vector3)rules.Data[i + 1]; |
2160 | prules.PartStartColor.R = (float)tempv.x; | ||
2161 | prules.PartStartColor.G = (float)tempv.y; | ||
2162 | prules.PartStartColor.B = (float)tempv.z; | ||
2155 | break; | 2163 | break; |
2156 | 2164 | ||
2157 | case (int)LSL_BaseClass.PSYS_PART_START_ALPHA: | 2165 | case (int)LSL_BaseClass.PSYS_PART_START_ALPHA: |
2158 | //what is the cast? prules.PartStartColor = (LSL_Types.Vec)rules[i + 1]; | 2166 | prules.PartStartColor.A = (float)rules.Data[i + 1]; |
2159 | break; | 2167 | break; |
2160 | 2168 | ||
2161 | case (int)LSL_BaseClass.PSYS_PART_END_COLOR: | 2169 | case (int)LSL_BaseClass.PSYS_PART_END_COLOR: |
2162 | prules.PartEndColor = (LLColor)rules[i + 1]; | 2170 | prules.PartEndColor = (LLColor)rules.Data[i + 1]; |
2171 | tempv = (LSL_Types.Vector3)rules.Data[i + 1]; | ||
2172 | prules.PartEndColor.R = (float)tempv.x; | ||
2173 | prules.PartEndColor.G = (float)tempv.y; | ||
2174 | prules.PartEndColor.B = (float)tempv.z; | ||
2163 | break; | 2175 | break; |
2164 | 2176 | ||
2165 | case (int)LSL_BaseClass.PSYS_PART_END_ALPHA: | 2177 | case (int)LSL_BaseClass.PSYS_PART_END_ALPHA: |
2166 | //what is the cast? prules.PartStartColor = (LLColor)rules[i + 1]; | 2178 | prules.PartEndColor.A = (float)rules.Data[i + 1]; |
2167 | break; | 2179 | break; |
2168 | 2180 | ||
2169 | case (int)LSL_BaseClass.PSYS_PART_START_SCALE: | 2181 | case (int)LSL_BaseClass.PSYS_PART_START_SCALE: |
2170 | //what is the cast? prules.PartStartColor = (LLColor)rules[i + 1]; | 2182 | tempv = (LSL_Types.Vector3)rules.Data[i + 1]; |
2183 | prules.PartStartScaleX = (float)tempv.x; | ||
2184 | prules.PartStartScaleY = (float)tempv.y; | ||
2171 | break; | 2185 | break; |
2172 | 2186 | ||
2173 | case (int)LSL_BaseClass.PSYS_PART_END_SCALE: | 2187 | case (int)LSL_BaseClass.PSYS_PART_END_SCALE: |
2174 | //what is the cast? prules.PartStartColor = (LLColor)rules[i + 1]; | 2188 | tempv = (LSL_Types.Vector3)rules.Data[i + 1]; |
2189 | prules.PartEndScaleX = (float)tempv.x; | ||
2190 | prules.PartEndScaleY = (float)tempv.y; | ||
2175 | break; | 2191 | break; |
2176 | 2192 | ||
2177 | case (int)LSL_BaseClass.PSYS_PART_MAX_AGE: | 2193 | case (int)LSL_BaseClass.PSYS_PART_MAX_AGE: |
2178 | prules.MaxAge = (float)rules[i + 1]; | 2194 | prules.MaxAge = (float)rules.Data[i + 1]; |
2179 | break; | 2195 | break; |
2180 | 2196 | ||
2181 | case (int)LSL_BaseClass.PSYS_SRC_ACCEL: | 2197 | case (int)LSL_BaseClass.PSYS_SRC_ACCEL: |
2182 | //what is the cast? prules.PartStartColor = (LLColor)rules[i + 1]; | 2198 | tempv = (LSL_Types.Vector3)rules.Data[i + 1]; |
2199 | prules.PartAcceleration.X = (float)tempv.x; | ||
2200 | prules.PartAcceleration.Y = (float)tempv.y; | ||
2201 | prules.PartAcceleration.Z = (float)tempv.z; | ||
2183 | break; | 2202 | break; |
2184 | 2203 | ||
2185 | case (int)LSL_BaseClass.PSYS_SRC_PATTERN: | 2204 | case (int)LSL_BaseClass.PSYS_SRC_PATTERN: |
2186 | //what is the cast? prules.PartStartColor = (LLColor)rules[i + 1]; | 2205 | int tmpi = (int)rules.Data[i + 1]; |
2206 | prules.Pattern = (Primitive.ParticleSystem.SourcePattern)tmpi; | ||
2187 | break; | 2207 | break; |
2188 | 2208 | ||
2189 | case (int)LSL_BaseClass.PSYS_SRC_TEXTURE: | 2209 | case (int)LSL_BaseClass.PSYS_SRC_TEXTURE: |
2190 | prules.Texture = (LLUUID)rules[i + 1]; | 2210 | prules.Texture = new LLUUID(rules.Data[i + 1].ToString()); |
2191 | break; | 2211 | break; |
2192 | 2212 | ||
2193 | case (int)LSL_BaseClass.PSYS_SRC_BURST_RATE: | 2213 | case (int)LSL_BaseClass.PSYS_SRC_BURST_RATE: |
2194 | prules.BurstRate = (float)rules[i + 1]; | 2214 | prules.BurstRate = (float)rules.Data[i + 1]; |
2195 | break; | 2215 | break; |
2196 | 2216 | ||
2197 | case (int)LSL_BaseClass.PSYS_SRC_BURST_PART_COUNT: | 2217 | case (int)LSL_BaseClass.PSYS_SRC_BURST_PART_COUNT: |
2198 | prules.BurstPartCount = (byte)rules[i + 1]; | 2218 | prules.BurstPartCount = (byte)rules.Data[i + 1]; |
2199 | break; | 2219 | break; |
2200 | 2220 | ||
2201 | case (int)LSL_BaseClass.PSYS_SRC_BURST_RADIUS: | 2221 | case (int)LSL_BaseClass.PSYS_SRC_BURST_RADIUS: |
2202 | prules.BurstRadius = (float)rules[i + 1]; | 2222 | prules.BurstRadius = (float)rules.Data[i + 1]; |
2203 | break; | 2223 | break; |
2204 | 2224 | ||
2205 | case (int)LSL_BaseClass.PSYS_SRC_BURST_SPEED_MIN: | 2225 | case (int)LSL_BaseClass.PSYS_SRC_BURST_SPEED_MIN: |
2206 | prules.BurstSpeedMin = (float)rules[i + 1]; | 2226 | prules.BurstSpeedMin = (float)rules.Data[i + 1]; |
2207 | break; | 2227 | break; |
2208 | 2228 | ||
2209 | case (int)LSL_BaseClass.PSYS_SRC_BURST_SPEED_MAX: | 2229 | case (int)LSL_BaseClass.PSYS_SRC_BURST_SPEED_MAX: |
2210 | prules.BurstSpeedMax = (float)rules[i + 1]; | 2230 | prules.BurstSpeedMax = (float)rules.Data[i + 1]; |
2211 | break; | 2231 | break; |
2212 | 2232 | ||
2213 | case (int)LSL_BaseClass.PSYS_SRC_MAX_AGE: | 2233 | case (int)LSL_BaseClass.PSYS_SRC_MAX_AGE: |
2214 | prules.MaxAge = (float)rules[i + 1]; | 2234 | prules.MaxAge = (float)rules.Data[i + 1]; |
2215 | break; | 2235 | break; |
2216 | 2236 | ||
2217 | case (int)LSL_BaseClass.PSYS_SRC_TARGET_KEY: | 2237 | case (int)LSL_BaseClass.PSYS_SRC_TARGET_KEY: |
2218 | prules.Target = (LLUUID)rules[i + 1]; | 2238 | prules.Target = new LLUUID(rules.Data[i + 1].ToString()); |
2219 | break; | 2239 | break; |
2220 | 2240 | ||
2221 | case (int)LSL_BaseClass.PSYS_SRC_OMEGA: | 2241 | case (int)LSL_BaseClass.PSYS_SRC_OMEGA: |
2242 | // AL: This is an assumption, since it is the only thing that would match. | ||
2243 | tempv = (LSL_Types.Vector3)rules.Data[i + 1]; | ||
2244 | prules.AngularVelocity.X = (float)tempv.x; | ||
2245 | prules.AngularVelocity.Y = (float)tempv.y; | ||
2246 | prules.AngularVelocity.Z = (float)tempv.z; | ||
2222 | //cast?? prules.MaxAge = (float)rules[i + 1]; | 2247 | //cast?? prules.MaxAge = (float)rules[i + 1]; |
2223 | break; | 2248 | break; |
2224 | 2249 | ||
2225 | case (int)LSL_BaseClass.PSYS_SRC_ANGLE_BEGIN: | 2250 | case (int)LSL_BaseClass.PSYS_SRC_ANGLE_BEGIN: |
2226 | prules.InnerAngle = (float)rules[i + 1]; | 2251 | prules.InnerAngle = (float)rules.Data[i + 1]; |
2227 | break; | 2252 | break; |
2228 | 2253 | ||
2229 | case (int)LSL_BaseClass.PSYS_SRC_ANGLE_END: | 2254 | case (int)LSL_BaseClass.PSYS_SRC_ANGLE_END: |
2230 | prules.OuterAngle = (float)rules[i + 1]; | 2255 | prules.OuterAngle = (float)rules.Data[i + 1]; |
2231 | break; | 2256 | break; |
2232 | } | 2257 | } |
2233 | } | 2258 | } |
diff --git a/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands_Interface.cs b/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands_Interface.cs index 8e63924..419398f 100644 --- a/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands_Interface.cs +++ b/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands_Interface.cs | |||
@@ -439,7 +439,7 @@ namespace OpenSim.Region.ScriptEngine.Common | |||
439 | //wiki: double llGetRegionFPS() | 439 | //wiki: double llGetRegionFPS() |
440 | double llGetRegionFPS(); | 440 | double llGetRegionFPS(); |
441 | //wiki: llParticleSystem(List<Object> rules | 441 | //wiki: llParticleSystem(List<Object> rules |
442 | void llParticleSystem(List<object> rules); | 442 | void llParticleSystem(LSL_Types.list rules); |
443 | //wiki: llGroundRepel(double height, integer water, double tau) | 443 | //wiki: llGroundRepel(double height, integer water, double tau) |
444 | void llGroundRepel(double height, int water, double tau); | 444 | void llGroundRepel(double height, int water, double tau); |
445 | void llGiveInventoryList(); | 445 | void llGiveInventoryList(); |