Gamestudio Links
Zorro Links
Newest Posts
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
4 registered members (degenerate_762, AbrahamR, AndrewAMD, ozgur), 667 guests, and 8 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Hanky27, firatv, wandaluciaia, Mega_Rod, EternallyCurious
19051 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 3 of 3 1 2 3
Re: Dijkstra and Wed paths [Re: MadJack] #216753
07/18/08 16:16
07/18/08 16:16
Joined: Jun 2005
Posts: 87
France
MadJack Offline OP
Junior Member
MadJack  Offline OP
Junior Member

Joined: Jun 2005
Posts: 87
France
I have upgraded today to V7.10 and you know what ?
I can't join two nodes anymore... (ctrl + click)

I can't believe it !
Just at the moment I want to release my DLL cry

I hope it is my mistake.


Commercial A7.25b
RUGod
Re: Dijkstra and Wed paths [Re: MadJack] #216943
07/20/08 07:52
07/20/08 07:52
Joined: Feb 2006
Posts: 1,011
Germany
pegamode Offline
Serious User
pegamode  Offline
Serious User

Joined: Feb 2006
Posts: 1,011
Germany
Hi MadJack ... I hope you solved your problem.

I included your really nice work into my point&click adventure (very early progress state) and you have done a very good job.

Currently I'm playing around with some code to let the player walk to points between the path nodes ... did you do this already and give me some hints how to do this best?

Best regards,
Pegamode.

Re: Dijkstra and Wed paths [Re: pegamode] #216954
07/20/08 10:41
07/20/08 10:41
Joined: Jun 2005
Posts: 87
France
MadJack Offline OP
Junior Member
MadJack  Offline OP
Junior Member

Joined: Jun 2005
Posts: 87
France
Hi Pegamode,

My aim is to set a region surrounding each point (a sphere which radius could be stored in node skill1).
Within this region, entity could move directly to any point.
For example, if you have a simple room, idea is to set a node xxx in the middle, set the radius to cover the room, and while entity is within the node sphere, all the points of the room might be reached directly.
Between two nodes, you are in fact following one edge. What could be done is to use edge skill to store "edge width", imagine something like a cylinder.
Node sphere or edge cylinder represent the space where entity can move freely.

In my DLL, I have added a function that returns the skills of the edge you are following.

You can download DLL here : MDJK_A7 DLL


Commercial A7.25b
RUGod
Re: Dijkstra and Wed paths [Re: MadJack] #216958
07/20/08 11:09
07/20/08 11:09

F
Fear411
Unregistered
Fear411
Unregistered
F



man könnte auch mit c_trace prüfen ob der Punkt von der Entity aus sichtbar ist.
Wenn ja dann geht sie direkt zum Punkt, so könnte es dann auch in eckigen Räumen besser funktionieren also mit einem runden Radius.

Re: Dijkstra and Wed paths [Re: ] #216973
07/20/08 13:55
07/20/08 13:55
Joined: Feb 2006
Posts: 1,011
Germany
pegamode Offline
Serious User
pegamode  Offline
Serious User

Joined: Feb 2006
Posts: 1,011
Germany
In my special case I don't want to let the moving entity leave the path. It should always remain onto the line between the nodes, but my problem is as follows:

When clicking left mouse button I scan from the mouse position for the nearest path in range. This is set as destination. That works fine so far.

But I have to set a lot of path nodes in WED so that the distance between the point I really clicked at and the chosen path I set as destination is not so big.
I'd like to get rid of setting such a lot of nodes and just break down also that world points into one dimension so that the point I clicked at lies onto the line between the two nodes.



Re: Dijkstra and Wed paths [Re: pegamode] #216997
07/20/08 17:32
07/20/08 17:32
Joined: Jun 2005
Posts: 87
France
MadJack Offline OP
Junior Member
MadJack  Offline OP
Junior Member

Joined: Jun 2005
Posts: 87
France
Oh, I think I understand.
Ideally, you need something like
  • find the nearest edge of the path
  • go to this edge
  • stop when you are in front of the mouse click

So far we don't have a function to get the nearest edge, you have to develop something approaching, for example :
  • find the nearest node of the path
  • explore all the edges of this node
  • mesure angle between mouse click and edge
  • use edge with the smallest angle
  • follow this edge and stop at the minimum distance of mouse click



Might be a good function to add in the DLL...


Last edited by MadJack; 07/20/08 17:51.

Commercial A7.25b
RUGod
Re: Dijkstra and Wed paths [Re: MadJack] #217000
07/20/08 17:42
07/20/08 17:42
Joined: Feb 2006
Posts: 1,011
Germany
pegamode Offline
Serious User
pegamode  Offline
Serious User

Joined: Feb 2006
Posts: 1,011
Germany
Would be great if you could add such a function to your DLL :-)

Re: Dijkstra and Wed paths [Re: pegamode] #217002
07/20/08 17:54
07/20/08 17:54
Joined: Jun 2005
Posts: 87
France
MadJack Offline OP
Junior Member
MadJack  Offline OP
Junior Member

Joined: Jun 2005
Posts: 87
France
Would be great if Conitec could debug path editor and path functions.
They have cut my legs !

Last edited by MadJack; 07/20/08 18:05.

Commercial A7.25b
RUGod
Re: Dijkstra and Wed paths [Re: MadJack] #223004
08/21/08 21:23
08/21/08 21:23
Joined: Feb 2006
Posts: 1,011
Germany
pegamode Offline
Serious User
pegamode  Offline
Serious User

Joined: Feb 2006
Posts: 1,011
Germany
Hi MadJack,

I've got a problem when using your dll with a model created by ent_create instead of placing it in WED.

The engine crashes when calling the following line:

player.skill99 = path_MDJK_init(player, _chr (myPath));

After creating the entity I added a wait and I use path_set(player, myPath); to set the path to the player.

Any ideas ???

Regards,
Pegamode

Re: Dijkstra and Wed paths [Re: pegamode] #223068
08/22/08 07:56
08/22/08 07:56
Joined: Jun 2005
Posts: 87
France
MadJack Offline OP
Junior Member
MadJack  Offline OP
Junior Member

Joined: Jun 2005
Posts: 87
France
Right now, I don't know, I did not try to use the DLL after ent_create, I'll do it this week-end. (I have sent you a PM)


Commercial A7.25b
RUGod
Page 3 of 3 1 2 3

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1