-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathAccount Vault
361 lines (260 loc) · 6.92 KB
/
Account Vault
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
Account Vaults are a shared chest between all characters on your account. This allows you to safely transfer goods between characters without having to hide them somewhere, or drop them into a house.
The command to summon your account vault only works in town.
Account vault will show up for 20 seconds before it disappears.
You can only use the command once every five minutes.
Usage
[accountvault (while in town, as stated above)
============
Tresdni submitted a new resource:
Account Vaults - Safely transfer goods between characters on the same account!
Account Vaults are a shared chest between all characters on your account. This allows you to safely transfer goods between characters without having to hide them somewhere, or drop them into a house.
The command to summon your account vault only works in town.
Account vault will show up for 20 seconds before it disappears.
You can only use the command once every five minutes.
I have also included a cleanup system that deletes empty account vaults every four hours....
Click to expand...
Read more about this resource...
Tresdni, Nov 18, 2014
Edit
Delete
Warn
Report
#1
+ Quote
Reply
Like Like x 3 Winner Winner x 2 List
Like Dislike Agree Disagree Funny Winner Informative Friendly Useful Optimistic Creative Old Bad Spelling
Dian
Devilish
Dian
Administrator
Oh wow, that is just excellent!
I had the idea to make Bank box's accessible between any character on the same account, but this is a terrific idea too!
Dian, Nov 18, 2014
Edit
Delete
IP
Report
#2
+ Quote
Reply
Like Like x 1 List
Like Dislike Agree Disagree Funny Winner Informative Friendly Useful Optimistic Creative Old Bad Spelling
zerodowned
Spaced
zerodowned
Administrator
Moderator
JustUO Developer
Gold Star Member
Et Cetera, Et Cetera
I think I saw this at work on Imperium about two years ago. Maybe not the same code, but something similar.
It's awesome and beats having to drop items on the ground in an immediate logout area.
//avatar art used with permission by julien148
C# tutorials - http://www.playuo.org/emu/index.php?threads/c-tutorials.236/
BB Codes for posts - http://www.playuo.org/emu/index.php?help/bb-codes
My Stuff on Github
zerodowned, Nov 19, 2014
Edit
History
Delete
IP
Report
#3
+ Quote
Reply
Tresdni
Paranoid
Tresdni
Illustrious Member
JustUO Developer
Definitely not the same code, I wrote this about two years ago myself for the shard Freedom. Glad you enjoy it :)
Tresdni, Nov 19, 2014
Edit
Delete
IP
Warn
Report
#4
+ Quote
Reply
Like Like x 1 List
Undo Rating
Tresdni
Paranoid
Tresdni
Illustrious Member
JustUO Developer
Tresdni updated Account Vaults with a new update entry:
No need for cleanup timer at all.
Vorspire pointed out a blatant fact to me this morning, smh. I've updated this system to just delete the empty box after the hide timer, instead of running a non-stop timer checking every box in the world.
Efficiency ftw.
Read the rest of this update entry...
Tresdni, Nov 20, 2014
Edit
Delete
Warn
Report
#5
+ Quote
Reply
Like Like x 2 List
Undo Rating
Ravenwolfe
Fine
Ravenwolfe
Administrator
Staff Member
JustUO Developer
Very nice!
Ravenwolfe, Nov 20, 2014
Edit
Delete
IP
Report
#6
+ Quote
Reply
Like Dislike Agree Disagree Funny Winner Informative Friendly Useful Optimistic Creative Old Bad Spelling
Fenris
Sunshine
Fenris
Super Contributor
I test this scripts (on justuo publish 3) by use command and put couple of items in the box but next I still received information that "you can only summon your vault once every 5 minuts". I awaiting 20 minuts, reloging between character on account and problem still exist. Same on two another accounts.
Are this DataTime lines in AccountVaultCommand.cs correct ?
if (acctv != null)
{
if (DateTime.UtcNow + TimeSpan.FromMinutes(5.0) > DateTime.UtcNow)
{
from.SendMessage("You may only summon your account vault once every five minutes.");
return;
}
acctv.Z = toZ;
acctv.X = toX;
acctv.Y = toY;
acctv.Map = @from.Map;
acctv.Visible = true;
acctv.DisplayTo(@from);
acctv.DoContainerHideTimer(acctv);
acctv.LastSummoned = DateTime.UtcNow;
}
Click to expand...
Last edited: Dec 25, 2014
Fenris, Dec 25, 2014
Edit
History
Delete
IP
Warn
Report
#7
+ Quote
Reply
Like Dislike Agree Disagree Funny Winner Informative Friendly Useful Optimistic Creative Old Bad Spelling
Ravenwolfe
Fine
Ravenwolfe
Administrator
Staff Member
JustUO Developer
That statement would always be true. I think he meant to have it:
Code:
if(acctv.LastSummoned + TimeSpan.FromMinutes(5.0) > DateTime.UtcNow)
Ravenwolfe, Dec 25, 2014
Edit
Delete
IP
Report
#8
+ Quote
Reply
Like Like x 1 List
Like Dislike Agree Disagree Funny Winner Informative Friendly Useful Optimistic Creative Old Bad Spelling
Fenris
Sunshine
Fenris
Super Contributor
Solved. I changed line like you wrote
if (DateTime.UtcNow + TimeSpan.FromMinutes(5.0) > DateTime.UtcNow)
to
if (acctv.LastSummoned + TimeSpan.FromMinutes(5.0) > DateTime.UtcNow)
and now everything works correct.
Nice addon :)
Many thanks for your post Ravenwolfe !
Fenris, Dec 25, 2014
Edit
History
Delete
IP
Warn
Report
#9
+ Quote
Reply
Like Dislike Agree Disagree Funny Winner Informative Friendly Useful Optimistic Creative Old Bad Spelling
Ravenwolfe
Fine
Ravenwolfe
Administrator
Staff Member
JustUO Developer
Glad to help!
Ravenwolfe, Dec 25, 2014
Edit
Delete
IP
Report
#10
+ Quote
Reply
Like Dislike Agree Disagree Funny Winner Informative Friendly Useful Optimistic Creative Old Bad Spelling
Tresdni
Paranoid
Tresdni
Illustrious Member
JustUO Developer
Smh, it's always the little things. I'll update the post.
Tresdni, Dec 25, 2014
Edit
Delete
IP
Warn
Report
#11
+ Quote
Reply
Funny Funny x 1 List
Like Dislike Agree Disagree Funny Winner Informative Friendly Useful Optimistic Creative Old Bad Spelling
Tresdni
Paranoid
Tresdni
Illustrious Member
JustUO Developer
Tresdni updated Account Vaults with a new update entry:
Fixed Time Restriction
The time restriction was broken, good catch Fenris and Ravenwolfe.
Read the rest of this update entry...
Tresdni, Dec 25, 2014
Edit
Delete
Warn
Report
#12
+ Quote
Reply
Like Like x 1 List
Like Dislike Agree Disagree Funny Winner Informative Friendly Useful Optimistic Creative Old Bad Spelling
Joshua
Joshua
Renowned Member
Has anyone got this to work with 'Custom Regions in a Box' I'm not sure how to approach this one.
Joshua, Aug 14, 2015
Edit
Delete
IP
Warn
Report
#13
+ Quote
Reply
Like Dislike Agree Disagree Funny Winner Informative Friendly Useful Optimistic Creative Old Bad Spelling