aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Common/OpenSim.Framework/UserProfile.cs
diff options
context:
space:
mode:
authorMW2007-05-24 12:35:32 +0000
committerMW2007-05-24 12:35:32 +0000
commitf95b6081cba084d1b067acea99c0effa2b3bf42c (patch)
tree7a7ab4aa037f75afa54f403c701a735acb101575 /Common/OpenSim.Framework/UserProfile.cs
parentDie ServiceManager! (Not really Gareth, just the old directory, new directory... (diff)
downloadopensim-SC_OLD-f95b6081cba084d1b067acea99c0effa2b3bf42c.zip
opensim-SC_OLD-f95b6081cba084d1b067acea99c0effa2b3bf42c.tar.gz
opensim-SC_OLD-f95b6081cba084d1b067acea99c0effa2b3bf42c.tar.bz2
opensim-SC_OLD-f95b6081cba084d1b067acea99c0effa2b3bf42c.tar.xz
Renamed the new Directories. (removed the "-Source" from the end of them)
Diffstat (limited to 'Common/OpenSim.Framework/UserProfile.cs')
-rw-r--r--Common/OpenSim.Framework/UserProfile.cs62
1 files changed, 62 insertions, 0 deletions
diff --git a/Common/OpenSim.Framework/UserProfile.cs b/Common/OpenSim.Framework/UserProfile.cs
new file mode 100644
index 0000000..f95a8fa
--- /dev/null
+++ b/Common/OpenSim.Framework/UserProfile.cs
@@ -0,0 +1,62 @@
1using System;
2using System.Collections.Generic;
3using System.Text;
4using libsecondlife;
5using OpenSim.Framework.Inventory;
6using System.Security.Cryptography;
7
8namespace OpenSim.Framework.User
9{
10 public class UserProfile
11 {
12
13 public string firstname;
14 public string lastname;
15 public ulong homeregionhandle;
16 public LLVector3 homepos;
17 public LLVector3 homelookat;
18
19 public bool IsGridGod = false;
20 public bool IsLocal = true; // will be used in future for visitors from foreign grids
21 public string AssetURL;
22 public string MD5passwd;
23
24 public LLUUID CurrentSessionID;
25 public LLUUID CurrentSecureSessionID;
26 public LLUUID UUID;
27 public Dictionary<LLUUID, uint> Circuits = new Dictionary<LLUUID, uint>(); // tracks circuit codes
28
29 public AgentInventory Inventory;
30
31 public UserProfile()
32 {
33 Circuits = new Dictionary<LLUUID, uint>();
34 Inventory = new AgentInventory();
35 homeregionhandle = Helpers.UIntsToLong((997 * 256), (996 * 256));
36 homepos = new LLVector3();
37 homelookat = new LLVector3();
38 }
39
40 public void InitSessionData()
41 {
42 RNGCryptoServiceProvider rand = new RNGCryptoServiceProvider();
43
44 byte[] randDataS = new byte[16];
45 byte[] randDataSS = new byte[16];
46
47 rand.GetBytes(randDataS);
48 rand.GetBytes(randDataSS);
49
50 CurrentSecureSessionID = new LLUUID(randDataSS,0);
51 CurrentSessionID = new LLUUID(randDataS,0);
52
53 }
54
55 public void AddSimCircuit(uint circuitCode, LLUUID regionUUID)
56 {
57 if (this.Circuits.ContainsKey(regionUUID) == false)
58 this.Circuits.Add(regionUUID, circuitCode);
59 }
60
61 }
62}