YesNoOk
avatar

add004basic (Read 1509412 times)

Started by Shiyo Kakuge, June 18, 2014, 05:46:41 pm
Share this topic:
Re: add004basic
#761  January 17, 2017, 02:13:52 am
  • ****
  • Retired
  • Terminally Online
    • New Zealand
    • network.mugenguild.com/devon/
Does anyone know how to get the CPU-1 icon showing for the CPU character in the first match of Arcade Mode instead of the score?
Re: add004basic
#762  January 17, 2017, 06:14:19 pm
  • avatar
  • *
    • USA
Does anyone know how to get the CPU-1 icon showing for the CPU character in the first match of Arcade Mode instead of the score?
You need to enable AIlevel detection. Find this section of the code:
Code:
;>>sys::ai_switch
;;>>@Config.AI>>
;; ai判定  v51 [def:0 / ai:1-8 / hum:-1]
[state 0]
type=varset
trigger1=1
;;--- vWin
var(51)=ifelse((matchno>1&&ishometeam=1), ifelse(matchno+roundno-1<8, matchno+roundno-1, 8), 0)
;;--- v1.0
;;v1.0 var(51)=(root,ailevel) ;; (v1.x)
Just comment out the first var(51)-setting line and uncomment the second.
Re: add004basic
#763  January 17, 2017, 06:33:45 pm
  • *****
  • Super Mario Fighters 3 resurrected.
    • USA
    • doraemariby@yahoo.com
Random question... Does that do anything else, and does that also affect VS mode?
Re: add004basic
#764  January 17, 2017, 08:48:17 pm
  • ****
  • Retired
  • Terminally Online
    • New Zealand
    • network.mugenguild.com/devon/
You need to enable AIlevel detection. Find this section of the code:
Code:
;>>sys::ai_switch
;;>>@Config.AI>>
;; ai判定  v51 [def:0 / ai:1-8 / hum:-1]
[state 0]
type=varset
trigger1=1
;;--- vWin
var(51)=ifelse((matchno>1&&ishometeam=1), ifelse(matchno+roundno-1<8, matchno+roundno-1, 8), 0)
;;--- v1.0
;;v1.0 var(51)=(root,ailevel) ;; (v1.x)
Just comment out the first var(51)-setting line and uncomment the second.
Hey thanks my man, I would never have thought to look there. Now I just need to adjust my AI Ramping.

Random question... Does that do anything else, and does that also affect VS mode?
AIlevel won't show for P2.
Re: add004basic
#765  January 18, 2017, 10:35:39 pm
  • avatar
  • *
there will be a update(bugfix) soon.  :)

@MageKing17:
wow, excellent!
would it be alright if I used your codes in next update?
Re: add004basic
#766  January 19, 2017, 02:25:58 am
  • avatar
  • *
    • USA
there will be a update(bugfix) soon.  :)
Looking forward to it.

@MageKing17:
wow, excellent!
would it be alright if I used your codes in next update?
Absolutely! I posted my modifications in the hopes that they would be as useful to somebody else as they were to me, so do whatever you want with them.

I've been testing the modified combo meter pretty heavily (with the built-in combo meter also enabled for comparison purposes) and found very few differences (once I modified the character to manually increment var(11) alongside hitadd, of course); obviously this combo meter doesn't count everything exactly the same (the reset conditions appear to be slightly different, so sometimes the state-based combo meter will consider a combo "over" when the built-in one does not, and the built-in combo counter will count hitting a projectile as a combo hit when the state-based one has no way to track that), but since I haven't found any more major bugs, it should be relatively safe to use as-is. It could maybe use some extra comments for clarity... if you want me to document my code better before you incorporate it, just let me know.

I actually considered rewriting the combo meter again to use something like state -2 to track every increment of UniqHitCount and using that to increment the team's combo meter (since UniqHitCount is automatically affected by numhits and hitadd), but it wouldn't detect projectiles... I could use (projhit=1), but then two projectiles hitting in the same frame wouldn't get detected (whereas projectile hits are automatically detected by GetHitVar(hitcount)). I guess a projectile using numhits also wouldn't get handled properly by such a system (but, then, the current system doesn't do anything about it either). Also, anything using hitcountpersist would violate the assumption that a state change automatically resets the hit count...

...Upon reflection, that sounds like more trouble than it's worth, compared to just sticking with what works. :P
Re: add004basic
#767  January 19, 2017, 08:19:02 am
  • ****
  • Raging Fist
Re: add004basic
#768  January 19, 2017, 01:20:03 pm
  • ****
  • Hoping for the best, prepared for the worst.
  • 2D Fighting games forever!
    • Brazil
there will be a update(bugfix) soon.  :)

@MageKing17:
wow, excellent!
would it be alright if I used your codes in next update?


I have a question for you, it is possible to change the tag change commands? it conflicts with some characters who have those buttons as a move, turning impossible to switch them.
Lasagna
Re: add004basic
#769  January 19, 2017, 01:49:07 pm
  • ****
  • Retired
  • Terminally Online
    • New Zealand
    • network.mugenguild.com/devon/
open common1.cns and search for ";;>>@Config.Tag_Command>>" without quotes.
Re: add004basic
#770  January 19, 2017, 02:28:23 pm
  • ****
  • Hoping for the best, prepared for the worst.
  • 2D Fighting games forever!
    • Brazil
Thanks man.
Lasagna
Re: add004basic
#771  January 22, 2017, 04:24:59 am
  • avatar
  • *
    • USA
I finally got fed up with the "TAINING" typo in the menu font and fixed it. Just download that and stick it in your \data\mm2\ folder to get this:
Re: add004basic
#772  January 22, 2017, 05:01:51 am
  • ****
  • Raging Fist
Thanks buddy! I was wondering how to fix this XD
Re: add004basic
#773  January 22, 2017, 05:28:06 pm
  • ****
  • Pixels are atom's of resolution,Low-res or Hi-res
    • Turkey
    • metekervan26@gmail.com
can anyone tell me how to add these water effect to my stages? I tried it but it didn't work,
here is the code from common1.cns
can someone tell me what I'm doing wrong,I pasted WATER to author,changed p1's X and p2's  X it still doesn't works

Code:
;---
;>>sys::stage_type_set
;;>>@Config.Stage_Type>>
; stage type: ( 0: normal 1: water... )
[state 0] ;[.04]
type=varset
triggerall=!time && (var(7)&16384) ;; system_switch
;;--- vWin
trigger1=abs(floor(root,pos x*fvar(0)))=73 || floor(root,p2dist x*fvar(0))=146 ;; 73+73
;;--- v1.0
;v1.0; trigger2=stagevar(info.author)="WATER" ;(v1.0)
var(24)=1
Re: add004basic
#774  January 22, 2017, 05:30:45 pm
  • ****
  • The other Indian
    • India
Change p1 and p2 starting positions to 73 respectively in the stage.
Re: add004basic
#775  January 22, 2017, 05:45:02 pm
  • ****
  • Pixels are atom's of resolution,Low-res or Hi-res
    • Turkey
    • metekervan26@gmail.com
add004 is updated I guess

and It seems like I figured it out but it doesn't works on some stages,
and it appears on some stages randomly even if it isn't author=WATER
Last Edit: January 22, 2017, 07:04:55 pm by mete122
Re: add004basic
#776  January 23, 2017, 03:21:34 am
  • ****
  • The other Indian
    • India
add004 is updated I guess

and It seems like I figured it out but it doesn't works on some stages,
and it appears on some stages randomly even if it isn't author=WATER

Author  =  Water is not necessary. Changing the p1 and p2 positions to 73 from the default 70 does the trick.
Re: add004basic
#777  January 23, 2017, 04:43:31 am
  • avatar
  • *
    • USA
@Shiyo Kakuge:
Nice update, although... I'm not sure why you asked to use my code, since you appear to have come up with an improved version all on your own; the only even tangential reference to my version seems to be in comments. :S I feel almost like I got thanked for wasting my time, since my goal was simply to decouple the combo meter from life-change detection, and you did that with much less effort.

Author  =  Water is not necessary. Changing the p1 and p2 positions to 73 from the default 70 does the trick.
Actually, having an absolute X-coordinate of 73 is just one way to trigger the water detection; if the distance between player 1 and player 2 is 146 (73 * 2), it will also work (so you could, for example, have player 1 start at 150 and player 2 start at 296). Sadly, the logic trying to account for different resolution characters is broken; this code
Code:
	trigger1=abs(floor(root,pos x*fvar(0)))=73 || floor(root,p2dist x*fvar(0))=146
should be this instead:
Code:
	trigger1=abs(floor(root,pos x/fvar(0)))=73 || floor(root,p2dist x/fvar(0))=146
Re: add004basic
#778  January 23, 2017, 04:50:53 am
  • ****
  • The other Indian
    • India
Yes a multiple of 73.
Re: add004basic
#779  January 23, 2017, 09:59:57 am
  • avatar
  • *
thank you friends for the feedback!
update and bugfix #20170122

@MageKing17:
thank you for allowing me to use your code.
I tested your hitcount-detector, and copied a part of it in this update (I slightly altered the addon so that combo-meter-system works well in the future)
the codes you wrote are clearly customizable, very useful for any project.
this time, even though i didn't use your code exactly as it is, your codes tips and ideas enlightened me quite much. continuing to learn from your codes above. :wideeyed:
Re: add004basic
#780  January 23, 2017, 02:30:16 pm
  • ****
  • Pixels are atom's of resolution,Low-res or Hi-res
    • Turkey
    • metekervan26@gmail.com
@MageKing17:

interesting but what about p3x and p4x positions in stage and why this code still doesn't works on some stages,but works perfectly on another one?
Last Edit: January 23, 2017, 02:37:31 pm by mete122