Gamestudio Links
Zorro Links
Newest Posts
New FXCM FIX Plugin
by flink. 06/04/24 07:30
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
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
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
0 registered members (), 1,490 guests, and 12 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19058 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
event sorting #293812
10/14/09 01:32
10/14/09 01:32
Joined: May 2008
Posts: 62
México.
F
FcoElizalde Offline OP
Junior Member
FcoElizalde  Offline OP
Junior Member
F

Joined: May 2008
Posts: 62
México.
Hi, this is how I understand events work:

The c_move function performs the movement and collision,
it sets the value of event_type and waits to the next loop cycle, in the next loop cycle the event function is started, acording to the event_type.

If this is truth, then all values passed in the event function are 1 tick old.

Is there a way of calling the event function in the same loop cycle the collision detection determined the event_type?

My problem is that I want the user entity to move and push another entity, It would be only passing the velocity vector of the collider to the velicity vector of the other, but these vectors then have 1 frame delay, showing a similar mistake when you try to atach one entity before the movement.

Please help, I even tried to set the pushed function after the move instruction, sending a skill as a trigger, but didnt worked.

Re: event sorting [Re: FcoElizalde] #293815
10/14/09 02:29
10/14/09 02:29
Joined: Feb 2008
Posts: 3,232
Australia
EvilSOB Offline
Expert
EvilSOB  Offline
Expert

Joined: Feb 2008
Posts: 3,232
Australia
No, Im pretty sure you are wrone. About 95% sure.

As I understand it,
1> c_cmove, c_rotate, c_whatever is executed.
2> events get processed immediately, BEFORE the next command in the
function that performed the c-move, c_rotate, c_whatever.
3> if ME exists ATM, and it has an event-function, then process that now.
4> if the ME.event triggers further events, goto line 2>
5> if YOU exists ATM, and it has an event-function, then process that now.
6> if the YOU.event triggers further events, goto line 2>
6a> if it was a c_scan event, then goto step 2> for the next-nearest entity.

Thats my understanding of it anyway...
And I know for CERTAIN that the events take place immediately, not one frame later.

ope this helps...


"There is no fate but what WE make." - CEO Cyberdyne Systems Corp.
A8.30.5 Commercial
Re: event sorting [Re: EvilSOB] #293869
10/14/09 14:08
10/14/09 14:08
Joined: May 2008
Posts: 62
México.
F
FcoElizalde Offline OP
Junior Member
FcoElizalde  Offline OP
Junior Member
F

Joined: May 2008
Posts: 62
México.
Much appreciated, that sounds more logical, now I can go on knowing how it really works.


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