Enter Rental Room by Aphlux
Description: Quickly enters a rental room at the inn for both owners and co-owners. Must be within 12 spaces to an innkeeper.
1# Enter Inn Room Script for UO Outlands
2#
3# This script will quickly enter your rental inn room
4# as either the room owner or co-owner.
5#
6# You must be in range of an innkeeper or house steward.
7#
8# Written by: Aphlux (aka Aphra)
9# Last updated: August 24, 2022
10hotkey 'Cancel Current Target'
11clearsysmsg
12
13@setvar rentalGumpID 2393832411
14
15if gumpexists rentalGumpID
16 gumpclose
17 wait 100
18endif
19
20say 'room'
21waitforgump rentalGumpID 3000
22
23if not gumpexists rentalGumpID
24 overhead 'Failed to enter room!' 38
25 overhead 'Are you even near the inn?' 53
26elseif ingump 'Enter Your Room'
27 wait 250
28
29 while not insysmsg 'You enter the rental room'
30 overhead 'Entering room...' 903
31 gumpresponse 4
32 wait 250
33
34 if insysmsg 'That vendor is too far away'
35 overhead 'Innkeeper is too far away!' 38
36 overhead 'Move closer!' 53
37 stop
38 endif
39 endwhile
40
41 overhead 'Welcome home.'
42
43elseif ingump 'Rent This Room'
44 gumpresponse 5
45 waitforgump rentalGumpID 3000
46
47 if ingump 'co-owner'
48 while not insysmsg 'You enter the rental room'
49 wait 250
50 overhead 'Entering co-owned room...' 903
51 gumpresponse 100
52
53 if insysmsg 'That vendor is too far away'
54 overhead 'Innkeeper is too far away!' 38
55 stop
56 endif
57 endwhile
58
59 overhead 'Welcome home.'
60 else
61 overhead 'No access to any rooms!' 38
62 endif
63elseif ingump 'Visit Other Rooms'
64 gumpresponse 2
65 waitforgump rentalGumpID 3000
66
67 while not insysmsg 'You enter the rental room'
68 wait 250
69 overhead 'Entering co-owned room...' 903
70 gumpresponse 100
71 endwhile
72else
73 sysmsg 'Character does not have a room or access to one!' 38
74 overhead 'No room access!' 38
75endif