Jibble

Author Topic: Last & Furious (MAGS Nov 2017 entry)  (Read 11036 times)

Re: Last & Furious (MAGS Nov 2017 entry)
« Reply #40 on: 13 Oct 2019, 23:02 »
I can't use objects because they are always drawn on top of the character's dynamic sprite, notwithstanding the baselines.

The normal characters behave the same way (always drawn on top).

This is unexpected. Objects and characters must abide baselines.
There is nothing special in my "AI characters", they are regular characters and will follow same rules.

What baselines do you have set for the paper plane and for objects that must be behind it?

Re: Last & Furious (MAGS Nov 2017 entry)
« Reply #41 on: 13 Oct 2019, 23:10 »
It's working.

Stupidly, I had tried to set baselines for the objects but not for the characters.
I had supposed that the baseline of the characters would have been at their feet if they were working (which doesn't seem to be the case).

Thanks for your patience.
« Last Edit: 13 Oct 2019, 23:20 by Creamy »
 

Re: Last & Furious (MAGS Nov 2017 entry)
« Reply #42 on: 23 Oct 2019, 18:59 »
Hi Crimson,

Can you please tell me how to get rid of the opponents? I need them to disappear at a certain point.

I've tried to make them go in another room:
Code: Adventure Game Studio
  1.   cAICar1.ChangeRoom(1);
  2.   cAICar2.ChangeRoom(1);
  3.   cAICar3.ChangeRoom(1);
  4.   cAICar4.ChangeRoom(1);
  5.   cAICar5.ChangeRoom(1);

Or to update the race options:
Code: Adventure Game Studio
  1. ThisRace.Opponents = 0;

It doesn't crash the game but it doesn't work.
 

Re: Last & Furious (MAGS Nov 2017 entry)
« Reply #43 on: 23 Oct 2019, 21:33 »
ThisRace.Opponents = 0 will do nothing if you set it during the race, it makes sense only before the race began.

And when race updates all participants are forcedly have their room changed to current one:

in VehicleBase.asc
Code: Adventure Game Studio
  1. protected void VehicleBase::SyncCharacter()
  2. {
  3.     <...>
  4.     if (this.c.Room != player.Room)
  5.         this.c.ChangeRoom(player.Room);
  6.     <...>
  7. }
  8.  



I don't remember all details, but quickly scanning through code shows that each struct has a variable that tells that particular racer or car is active and should be updated.
In Vehicle class this is IsInit variable, and in Racer class this is IsActive variable. Setting these to false should stop game from updating them.
For RaceAI class there seem to be vehicleIndex that must be >=0 , so setting it to -1 might disable the AI.


Jack

  • Think deviant
    • I can help with AGS tutoring
    • I can help with scripting
    • I can help with story design
    • Jack worked on one or more games that was nominated for an AGS Award!
Re: Last & Furious (MAGS Nov 2017 entry)
« Reply #44 on: 23 Oct 2019, 22:57 »
CW, when are you and JimReed making LnF2?

2 Last
2 Furious
?

Re: Last & Furious (MAGS Nov 2017 entry)
« Reply #45 on: 23 Oct 2019, 23:15 »
CW, when are you and JimReed making LnF2?

This was never in plans.

Re: Last & Furious (MAGS Nov 2017 entry)
« Reply #46 on: 23 Oct 2019, 23:23 »
2 Furious 2 Last

:~(

Re: Last & Furious (MAGS Nov 2017 entry)
« Reply #47 on: 24 Oct 2019, 22:58 »
Thank you again CW.
Clumsily fiddling with your code, I was able to achieve what I had in mind.

Now, it's hopefully the final stretch. The game works fine when I test it in the editor. However it keeps its old behaviours when I compile it:
- it doesn't start in the right room,
- the AI cars use your old sprites,
- your game menu can be accessed with the escape key (which I had disabled).
- even my airegions are not taken into account.

Any life saving tip?
« Last Edit: 24 Oct 2019, 23:02 by Creamy »
 

Re: Last & Furious (MAGS Nov 2017 entry)
« Reply #48 on: 24 Oct 2019, 23:26 »
Have you renamed the project directory but did not clean up Compiled folder? That's the only thing that comes to mind.

Re: Last & Furious (MAGS Nov 2017 entry)
« Reply #49 on: 25 Oct 2019, 21:56 »
That did the trick  :)