This is a read only copy without any forum functionality of the old Modcraft forum.
If there is anything that you would like to have removed, message me on Discord via Kaev#5208.
Big thanks to Alastor for making this copy!

Menu

Author Topic: [QUESTION] Ride gameobjects  (Read 7557 times)

stoneharry

  • Contributors
  • Creator of Worlds
  • *****
  • Posts: 617
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #15 on: August 15, 2015, 10:31:25 pm »
Quote from: "kojak488"
That's not entirely true.  Well as far as saying that transports on predetermined routes is the only option for him, that's not true.  It's not.  There is a way to accomplish what he wants.

Well this is just bullshit. Post something useful or don't post at all.

Quote from: "Смердокрыл"
Is it possible to make a usual vehicle npc, which, when stopped, would spawn an object (of the same model, but with collision) over itself, and then, when I mount it and start moving, it would despawn the object?

It's possible but would be buggy and too slow to use on a server with players from many locations and a volatile latency. So not a feasible solution really.

edit: Just re-read this again. Yes, that would be very feasible to spawn and remove on start/stop. But not constantly respawning the object while moving along, which is how I read it the first time.

Quote from: "saifi0102"
Quote from: "stoneharry"
You can implement it for creatures because you can code them to think there is a barrier there (this is how creatures spreading out is implemented)

That sounds interesting. Can you move the creature around and keep the collision object stick with it? And what do you mean by creatures spreading out?

As in like this video: https://youtu.be/DbjAF-atgZ8?t=27
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

kojak488

  • Registred Member
  • Creator of Worlds
  • *****
  • Posts: 351
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #16 on: August 15, 2015, 11:28:23 pm »
Quote from: "Смердокрыл"
Quote from: "kojak488"
There is a way to accomplish what he wants.
You are the king of intriguing!
Jokes aside, what is it?

I'm not known for sharing my techniques...

Quote from: "stoneharry"
Well this is just bullshit. Post something useful or don't post at all.

I did post something useful.  I gave him a hint.  Furthermore, I clarified that you're giving him incorrect information as far as possible solutions being limited.  Sorry, I don't hold hands and leave little breadcrumbs for the mouse to find the cheese.  That doesn't mean my comment isn't useful.  And let me show you what happened the last time some bluebie called bullshit on me in a similar situation: viewtopic.php?f=93&t=9058

Or there's the time that Anthony said he was the first to achieve something that I then showed him a video of me doing it a while before.  Just because you haven't figured something out doesn't mean it's bullshit that someone else has nor mean it's bullshit because you think it's impossible.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

schlumpf

  • Administrator
  • Creator of Worlds
  • *****
  • Posts: 2967
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #17 on: August 15, 2015, 11:57:35 pm »
If you want to help, actually help. "I KNOW BUT I DON'T TELL" does not help at all, in no possible way. Otherwise, you're the one trolling.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Смердокрыл

  • Registred Member
  • Creator of Worlds
  • *****
  • Posts: 445
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #18 on: August 16, 2015, 01:34:17 am »
Quote from: "stoneharry"
to spawn and remove on start/stop
Yeah, thats what I meant. I can imagine how to make it spawn an object (a spell, or a smart script maybe), but how will it remove it? Each time the guid is gonna be different, and its not guaranteed that the guid will increase by 1 every time.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
or no.
At least I tried.

stoneharry

  • Contributors
  • Creator of Worlds
  • *****
  • Posts: 617
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #19 on: August 16, 2015, 01:40:05 am »
Quote from: "Смердокрыл"
Quote from: "stoneharry"
to spawn and remove on start/stop
Yeah, thats what I meant. I can imagine how to make it spawn an object (a spell, or a smart script maybe), but how will it remove it? Each time the guid is gonna be different, and its not guaranteed that the guid will increase by 1 every time.


Quote from: "kojak488"
That's not entirely true.  Well as far as saying that transports on predetermined routes is the only option for him, that's not true.  It's not.  There is a way to accomplish what he wants.
Quote from: "kojak488"
I'm not known for sharing my techniques...
What exactly in this six sentences do you call
Quote from: "kojak488"
a hint
?

That's the beauty of object orientated programming. You could just store the current object guid that is spawned in the player class and remove it on a movement packet being received, or all the other cases like logout, map change, command...
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Смердокрыл

  • Registred Member
  • Creator of Worlds
  • *****
  • Posts: 445
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #20 on: August 16, 2015, 02:13:43 am »
Quote from: "stoneharry"
That's the beauty of object orientated programming. You could just store the current object guid that is spawned in the player class and remove it on a movement packet being received, or all the other cases like logout, map change, command...

So if Im planning to use smartAI:
 for spawning, the action_type is 50 and target_type is 1. What is the event_type? 28 or 43 maybe?
 for despawning, the action_type is 41 and target_type is, I presume, 12? Event type possibly 34?
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
or no.
At least I tried.

Allifeur

  • Contributors
  • Wiki Incarnate
  • *****
  • Posts: 189
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #21 on: August 16, 2015, 02:35:50 am »
You could also fake a collision by giving your vehicule an invisible aura that bumps those who are too close. That way, people couldn't go through the object when it's moving. But this solution is better for small vehicles and not for these giant ships you want. I never tried it, but I imagine it would be easier to manage little boats, like this one :



 This aura system is a good addition to the alternation of creature/gameobject phases : it avoids players to get into your boats.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Method

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 78
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #22 on: August 16, 2015, 02:55:58 am »
The way that Blizzard has ALWAYS done this kind of stuff is by creating transport npcs or simply using mounts, sadly creating an entirely new method is just really complex.

You're talking about essentially recoding the game object handler (The closest in resemblance to your desired collision) to handle movement, which isn't impossible, but I'd imagine it wouldn't be very practical, and would destroy an average PC.

The boat in Shimmering Flats is an example of THE go-to transport NPC, you can't really move inside it like it was a game-object. If Blizzard themselves uses that method, then it's pretty hard to create an alternative, like I said, creating one requires some serious work.

-- but there are workarounds.

I think the easier alternative is to create a new zone, and in that zone, design it like the interior of a ship.

Talking to your own transport NPC, or having a hearthstone device could in theory allow you to go inside your ship, and you can have as many gameobjects as you want in there, as it would be a static zone. So, you're not really walking on, or inside your ship, HOWEVER you can walk inside it, and potentially have a crew onboard if it was an actual zone.

Making a zone that confined and small isn't a new idea, look at the pre-cata war-rooms for Alliance and Horde.
« Last Edit: August 16, 2015, 03:01:06 am by Admin »
Big Protodrake Gifs are really annoying aren\'t they?

Смердокрыл

  • Registred Member
  • Creator of Worlds
  • *****
  • Posts: 445
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #23 on: August 16, 2015, 02:56:46 am »
I wantED people to walk inside the ship when its moving, just like in a proper ship. But thats not possible.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
or no.
At least I tried.

Method

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 78
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #24 on: August 16, 2015, 03:02:22 am »
You CAN give it the *illusion* of movement though. You don't need to move the ship, you just need to move everything around the ship. You would still achieve a lot of your desired affect.

You CAN make your ship look like it's moving through the sea, in the middle of the ocean, you can have a bunch of npcs like untargetable icebergs and islands pass by, and have a full crew onboard by making a zone that fits that purpose.  

You can even dynamically change which NPC's spawn based on which area of the sea you're in. You could even stop those npcs at will while you're traveling to pick up quests, or turn dynamic npcs into static wmo's that you can actually move on.

Moving those npc paths and the game-object with fluid movement would be awesome, but it'd require some serious work that's probably complex for Blizzard themselves, it does require rewriting code, it isn't as simple as just making things work.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
Big Protodrake Gifs are really annoying aren\'t they?

Смердокрыл

  • Registred Member
  • Creator of Worlds
  • *****
  • Posts: 445
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #25 on: August 16, 2015, 03:23:41 am »
Thanks for advising, but I need to have an actual ship, which could be actually mounted and moved around the world.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
or no.
At least I tried.

kojak488

  • Registred Member
  • Creator of Worlds
  • *****
  • Posts: 351
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #26 on: August 16, 2015, 02:22:57 pm »
Quote from: "schlumpf"
If you want to help, actually help. "I KNOW BUT I DON'T TELL" does not help at all, in no possible way. Otherwise, you're the one trolling.

Incorrect because you're missing the fact that I'm clarifying he's being given misinformation.  That is help.  I'm sorry if you can't see it that way, but that doesn't mean it's not help.  Trolling would be saying nothing and letting the poor chap think there's no viable solution for him.

Quote from: "Смердокрыл"
What exactly in this six sentences do you call
Quote from: "kojak488"
a hint
?

That stoneharry gave you wrong information, which may lead you to give up your search for the viable solution.  Just like in the thread I linked above Alastor tried to say it wasn't possible (or at least that nobody had managed it), that might lead people to give up.  Yet clearly there was a solution.  Letting people know it's possible means they shouldn't given up.  Allowing people to think it's impossible means they're more likely to give up.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Method

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 78
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #27 on: August 16, 2015, 02:46:32 pm »
Quote from: "Смердокрыл"
Thanks for advising, but I need to have an actual ship, which could be actually mounted and moved around the world.

Have you looked further into the ship system used by Blizzard in Rachet/BootyBay/Menethil/Auberdine/etc?

That may be one of the areas you can work on. All of those paths are pre-programmed, but I can't see why new paths can't be added. (Some were in cataclysm)

And those ARE ships that ARE Wmo's that DO move. I totally forgot about those ships in my initial post.

It may be as simple as adding a few hundred static pre-programmed paths or working out how to make a more dynamic system.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
Big Protodrake Gifs are really annoying aren\'t they?

Смердокрыл

  • Registred Member
  • Creator of Worlds
  • *****
  • Posts: 445
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #28 on: August 16, 2015, 02:54:27 pm »
Again, I dont need anything pre-programmed. I need a ship which I and my friends could use and move it whenever and wherever we want to.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
or no.
At least I tried.

Method

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 78
    • View Profile
Re: [QUESTION] Ride gameobjects
« Reply #29 on: August 16, 2015, 02:56:51 pm »
Then you need to dynamically figure out a way to path destinations using the static system as a basis.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
Big Protodrake Gifs are really annoying aren\'t they?