Implementing: Housing

EQ2Emulator Development forum.

Moderator: Team Members

bolly
Retired
Posts: 389
Joined: Mon Sep 21, 2009 3:03 pm
Location: Leeds, UK

Implementing: Housing

Post by bolly » Sat Aug 14, 2010 6:07 pm

I really want to get this working. I know it's not at the top of the list or probably anywhere near the list but I would really like to take a stab at it.

My problem is though, I am just not sure how to understand how people like scat look at packets and figure out the order things should be going on. Should I be using something like wireshark? How do you see what's inside the data?

User avatar
Zcoretri
Team Member
Posts: 1642
Joined: Fri Jul 27, 2007 12:55 pm
Location: SoCal

Re: Housing

Post by Zcoretri » Sun Aug 15, 2010 10:29 am

bolly wrote:I really want to get this working. I know it's not at the top of the list or probably anywhere near the list but I would really like to take a stab at it.

My problem is though, I am just not sure how to understand how people like scat look at packets and figure out the order things should be going on. Should I be using something like wireshark? How do you see what's inside the data?
People like scat and LE it seems to come naturally to them, where as I have to work hard at learning stuff. :mrgreen:
If John and myself knew how to code in C++ good, this emulator would have been a lot farther along...but even though we are pretty smart in stuff, we just can't seem to get C++, lol.

You don't really need to look at the low level data (data packets), I can do that and come up with the structs needed...it's using the structs in the C++ code that we really need.

bolly
Retired
Posts: 389
Joined: Mon Sep 21, 2009 3:03 pm
Location: Leeds, UK

Re: Housing

Post by bolly » Sun Aug 15, 2010 12:48 pm

Hey!

Great, ok :-) So I guess to start with we just need the basic logic of buying and entering as well as being able to interface with the door.

------------------

Tasks
-------

Add door type and assign it to a test door (I guess this needs a certain 'type' to show the correct mouse icon when hovering over)

Give the door a house entity command for click

Assign the housing type to that door

Code the entity command to check who the clicker is, show the visitor/owner enter window depending (i guess this is another packet)

If they do not own the instance show BUY, if they do show them ENTER

If they chose Visitor show list of owners that have public visit

If they chose Tour simply enter template instance of the house

----------------

If BUY

Check if they can afford it

Remove the cost

Create an entry for the instance in the database, assign the owner and the zone id template for the house (a table)

Leave wall, floor decorations as blank (another table)

Boot up the instance

Load player into instance

--------------

If ENTER

Check they are still the owner or have the right access

Find the entry for the instance in the database

Check if the instance is already up

If not - start the instance

Load the floor/wall decorations

Load the interiors

Load the player into the house

--------------

bolly
Retired
Posts: 389
Joined: Mon Sep 21, 2009 3:03 pm
Location: Leeds, UK

Re: Housing

Post by bolly » Sun Aug 15, 2010 1:02 pm

To start with, since I need to know about the opcode side of things, how about you tell me how to get my server to tell my client to pop up the House dialog box?

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Re: Housing

Post by John Adams » Sun Aug 15, 2010 9:12 pm

Image had done some Instancing work about 18 mos ago. Never got to test it out, and can't find him anymore to ask if what the status was... but apparently there's code in there to support instancing (somewhat).

Bolly, you could always write the C++ for the routines to do all the logical checking, ignoring client input for the time being... unless that would just be harder. Ie., you could assume some fake data just to get it working.

bolly
Retired
Posts: 389
Joined: Mon Sep 21, 2009 3:03 pm
Location: Leeds, UK

Re: Housing

Post by bolly » Mon Aug 16, 2010 10:11 am

I could do an entity command for the door and hook that into the existing instancing system

Is there a zone entry for the door? Like how do I know which zone file to load as the instance?

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Re: Housing

Post by John Adams » Mon Aug 16, 2010 11:31 am

I imagine it could be any player housing zone in the entire library of player housing zones ;) The Instancing Image set up probably wasn't about player housing though... so I am not sure how much more work is needed. You'd likely need tables for things like `character_house` and the items within `character_house_items` and `character_house_access` etc. These were all a part of the DB design originally, but were removed due to the fact we really didn't have a design yet.

User avatar
Zcoretri
Team Member
Posts: 1642
Joined: Fri Jul 27, 2007 12:55 pm
Location: SoCal

Re: Housing

Post by Zcoretri » Tue Aug 17, 2010 1:15 pm

So far I have had no luck in getting the "Buy" window to open. I may need some more packet collections on this.
I'll post screen shots later when I get home from work, on what I CAN do and post screen shot on what I CAN"T do.

bolly
Retired
Posts: 389
Joined: Mon Sep 21, 2009 3:03 pm
Location: Leeds, UK

Re: Housing

Post by bolly » Tue Aug 17, 2010 1:45 pm

I was looking at this but couldn't find the world structs

Just looking at SetupInstance and CreateNewInstance which seem to be tied into pre-defined instances from the zones tables

User avatar
Zcoretri
Team Member
Posts: 1642
Joined: Fri Jul 27, 2007 12:55 pm
Location: SoCal

Re: Housing

Post by Zcoretri » Tue Aug 17, 2010 5:34 pm

bolly wrote:I was looking at this but couldn't find the world structs

Just looking at SetupInstance and CreateNewInstance which seem to be tied into pre-defined instances from the zones tables
You won't find world structs because I have been creating them when this topic came up :mrgreen:

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Re: Housing

Post by John Adams » Mon Oct 29, 2012 12:21 pm

Resurrecting this old thread for 2 reasons:

1) We are currently collecting data for functionality, and if there is something more needed for housing purchases and the like, our collectors need to know.

2) Jab, with the discovery of Instancing working (ish), can I ask that we go as far as the "Access" handler being implemented in 0.7.2? I don't want to take Housing further than that, as we have plenty to do in this cycle, but getting the Access option to generate a personal housing instance (no money involved or other features, just the zone-in), would be slick.

ProjMan - Housing Access Option

Let me know if you think this should wait. Seems simple enough.


PS: I will go back through Bolly's list above and add records for all the details on housing into ProjMan.

User avatar
alfa
Team Member
Posts: 550
Joined: Fri Jul 27, 2007 6:24 pm
Location: France
Contact:

Re: Implementing: Housing

Post by alfa » Mon Oct 29, 2012 2:17 pm

viewtopic.php?f=17&t=3253&p=24780#p24780
alfa wrote:Well, regarding Jab is near to done with instance, if I correctly remember times ago L.E. have find way to move object in game, so I prevent a great idea of John about housing, maybe it will be done in years, but data are here anyway :p
Héhé !
Fight with me... Or die, like the rest.
J.A. say: "I think Xinux tried to tell me this, but I ignore most things he suggests."

Jabantiz
Lead Developer
Posts: 2912
Joined: Wed Jul 25, 2007 2:52 pm
Location: California

Re: Implementing: Housing

Post by Jabantiz » Mon Oct 29, 2012 3:01 pm

I honestly haven't put any thought into what this will take. Getting a window to pop up shouldn't be to difficult, how to store the data to make it functional might be another issue. I can look into it and see what I can come up with and let you know if 7.2 is possible after we are done collecting.

User avatar
Zcoretri
Team Member
Posts: 1642
Joined: Fri Jul 27, 2007 12:55 pm
Location: SoCal

Re: Implementing: Housing

Post by Zcoretri » Mon Oct 29, 2012 4:20 pm

Well what do you know, i did commit some housing structs already :)

Code: Select all

<Struct Name="WS_DisplayVisitScreen" ClientVersion="1096" OpcodeName="OP_DisplayInnVisitScreenMsg">

Code: Select all

<Struct Name="WS_DisplayHouseStatus" ClientVersion="1096" OpcodeName="OP_PlayerHouseDisplayStatusMsg">
Of course there maybe more needed for this implementation.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Re: Implementing: Housing

Post by John Adams » Mon Oct 29, 2012 4:45 pm

Yes, to all 3 of you ;) I know Z did some structs work, I know alfa mentioned housing, and I know Jab is busy collecting (which we'd rather have first).

Again, I am not interested in housing in general... just getting that damn Right-Click "Access" to do more than blink at me. Since the Instance code is already there, I was hoping it would be as simple as creating the instance, then simply moving the player into it... nothing more than that for 0.7.2.

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest