YesNoOk
avatar

Can't Record Sprpriority? (Read 173 times)

Started by Sheng Long, December 10, 2014, 03:07:57 am
Share this topic:
Can't Record Sprpriority?
#1  December 10, 2014, 03:07:57 am
  • *****
  • Video Game Veteran
    • USA
    • gcnmario.free.fr
Why can't I record the current sprpriority that is set on a player on to a variable?

I'm trying to do something like this.
Code:
[Statedef 12345]

[State 12345, SprPriority]
type = SprPriority
trigger1 = 1
value = Var(10) + 1

Since 'value = Root, sprpriority' will NOT work directly, or any way. I am trying to make a helper's sprpriority match the root characters sprpriority with a single code, + 1 more up so it always appears in front, but not when an opponents attack sprpriority is highest in front. If I use sprpriority = 5 or 10, that will ALWAYS put the object in front, which i do NOT want to happen here. I just want it in the same sprpriority of the root character as much as +1 more.

"You must defeat my flaming
dragon punch to stand a chance."
Re: Can't Record Sprpriority?
#2  December 11, 2014, 12:30:05 pm
  • ***
    • USA
hmmm, I doubt you'll be able to read that info. I'd suggest using something that locks in the sprite's priority. Dont allow it to change?

 
    [State 12000, ROOTPriority]
    type = SprPriority
    trigger1 = 1
    value = -2
 
    [State 12345, SprPriority]
    type = SprPriority
    trigger1 = 1
    value = -1

Would you need to put it into statedef -2?

           
Re: Can't Record Sprpriority?
#3  December 11, 2014, 01:16:57 pm
  • ****
  • Hey.
    • Ukraine
    • mugencoder.com

  • Online
If var(10) is the root's variable, then you have to redirect it to the root with "root,var(10)." This is assuming you're just manually setting var(10) as your current sprpriority. As Odb718 said, you can't read that information. There are no triggers available to you that will allow you to do that.

-[Все слова это только слова.]-