Purple Spider Facing

  • 6 Replies
  • 6097 Views
*

Offline egomassive

  • 1852
  • 250
    • View Profile
    • egomassive games
Purple Spider Facing
« on: March 11, 2011, 04:15:44 »
I must be going crazy. The purple spider (bank 4 object 9) faces Juni when she enters a screen. If Juni enters from the left the spider looks left. I could have sworn that if Juni entered between 2 spiders (from the top for example,) then the spiders would still look towards her. But they don't, they both face left. I even reinstalled KS, but I got the same result. Am I completely mistaken here?

*

Offline sergiocornaga

  • 1286
  • 131
    • View Profile
    • Sergio's Games
Re: Purple Spider Facing
« Reply #1 on: March 11, 2011, 04:35:09 »
Could be a bug? I did a lot of testing, and it seems that when Juni enters between two spiders, the spider closest to the bottom will face Juni and the other spider will face the same direction.

*

Offline egomassive

  • 1852
  • 250
    • View Profile
    • egomassive games
Re: Purple Spider Facing
« Reply #2 on: March 11, 2011, 17:11:56 »
To be more specific, the last spider created controls where all the spiders look. I believe the MMF2 engine performs actions on the last objects created first. I can reverse their behavior by putting the left spider on a higher layer. See figures 1 and 2.

Code: [Select]
Fig.1) Same layer, same row.
<SPIDER........Juni........<SPIDER
The right spider controls the initial direction for all spiders.

Fig.2) Same row, left spider on layer 7, right spider on layer 6
SPIDER>........Juni........SPIDER>
The left spider controls the initial direction for all spiders.

Fig.3) How I think it should work regardless of order.
SPIDER>........Juni........<SPIDER

Note: Juni has entered from the center top in these scenarios.

Here's the kicker, according to the KS source I think they should all look at Juni. I can't figure out why they don't. Here's the instructions that initialize spider facing. Note: When a spider is created it's flags are all off and it faces right.

Code: (pseudo code) [Select]
If (X position of Player Character is < X position of Spider)
-- AND If (Flag Zero Of Spider is off)
----Then (set Spider direction to left)

If (Flag Zero Of Spider is off)
--Then (set Flag Zero Of Spider on)

According to my understanding of MMF2, the first expression should turn all the Spiders that are to right of Juni. The second expression acts on all the spiders. Afterward, Flag Zero is on so these expressions won't execute again.

This is becoming more of a question for the ClickTeam forums, I guess what I want to know is...
Is this a bug in the program, and should I fix it in my KS mod?

Edit: OMG! I replaced the line...

If (X position of Player Character is < X position of Spider)

with the line...

If (X position of Spider is > X position of Player Character)

and now it works like it should! I totally Hate you MMF2 with all my soul! I spent like 8 hours of my precious life figuring out that idiotic discrepancy!

... Anyway, I'm pretty sure Nifflas is done updating KS, do you guys think I should fix it in my mod?
« Last Edit: March 11, 2011, 18:02:41 by egomassive »

*

Offline sergiocornaga

  • 1286
  • 131
    • View Profile
    • Sergio's Games
Re: Purple Spider Facing
« Reply #3 on: March 12, 2011, 01:21:06 »
Sure, I think it should be fixed. It's an aesthetic thing that shouldn't influence gameplay for existing levels, right?

*

Offline egomassive

  • 1852
  • 250
    • View Profile
    • egomassive games
Re: Purple Spider Facing
« Reply #4 on: March 12, 2011, 02:18:03 »
It's a slight game play change really. I've kind of gone in a new direction with my mod though. The bread and butter of it is being able to put new graphics on existing objects. This causes a small, probably unnoticeable, drop in performance, and that will alter game play. So, I've decided I'm OK with allowing other small changes to existing game play if they are warranted and non-game-breaking for existing levels.

I'm not yet ready to start talking about my KS mod again. It's not officially back in production. When it is I'll resurrect it's old thread.

*

Offline Talps

  • 1027
  • 142
  • ...especially in a life-or-death situation!
    • View Profile
Re: Purple Spider Facing
« Reply #5 on: March 17, 2011, 18:47:48 »
I think some of the ghosts that turn to face Juni have the same thing: if you have two or more of the same ghost on a screen, one of them will control the direction they all face.

*

Offline egomassive

  • 1852
  • 250
    • View Profile
    • egomassive games
Re: Purple Spider Facing
« Reply #6 on: March 17, 2011, 22:30:13 »
Thanks for the tip. I haven't looked much at the ghosts' logic because the Animated Picture extension (Custom Object) doesn't support semi-transparency. Meaning, I can't reproduce the ghostly flickering. If it's a bug, I'll fix it.

Edit: Talps, you were right. Ghost objects 4 and 7 had the same programming that broke the Spider. It's easy to fix when you know what's causing it. I don't think it's off topic to ask if anyone knows of any other glitches in Knytt Stories. I know about the umbrella getting stuck on if it's shifted off while in use. I also know that certain objects will get sucked through the contact layer due to slopes. (Put the purple lizard, 3:19, between two 45 degree slopes if you don't know what I mean.) Oh and, it's not really a glitch but creatures walking off ledges looks odd.
« Last Edit: March 18, 2011, 05:53:08 by egomassive »