Jump to content

MCM menu no longer shows


Recommended Posts

I've been working on an MCM menu, and unwieldy as it is, it showed up in Mod Configuration; until just recently, and no amount of crtl-z ing in npp++ can get it back, I've block commented out whole chunks, it still compiles but no joy.

Could someone take a quick look and suggest what stop it showing. The quest is all set up as it is was showing before, all tests are on a backed up save that has never seen mods.

 

 

 

Scriptname dz_outfit_change_menu Extends SKI_ConfigBase
Int Function GetVersion()

return 1 ; Default version

EndFunction
String name

Actor aRef

Bool Named
String outfit_name
Int default

Int town

Int pleasant

Int rainy

Int snowy

Int playerh

Int swimming
Bool _toggle_default

Bool  _toggle_town

Bool  _toggle_pleasant

Bool  _toggle_rainy

Bool  _toggle_snowy

Bool  _toggle_playerh

;Bool[]  _toggle_swimming
Actor[] Property Teammates Auto
Form[] Property default_outfit0 Auto

Form[] default_outfit1

Form[] default_outfit2

Form[] default_outfit3

Form[] default_outfit4

Form[] default_outfit5

Form[] default_outfit6

Form[] default_outfit7

Form[] default_outfit8

Form[] default_outfit9

Form[] default_outfit10
Form[] Property town_outfit0 Auto

Form[] Property town_outfit1 Auto

Form[] town_outfit2

Form[] town_outfit3

Form[] town_outfit4

Form[] town_outfit5

Form[] town_outfit6

Form[] town_outfit7

Form[] town_outfit8

Form[] town_outfit9

Form[] town_outfit10
;/ Form[] pleasant_outfit0

Form[] pleasant_outfit1

Form[] pleasant_outfit2

Form[] pleasant_outfit3

Form[] pleasant_outfit4

Form[] pleasant_outfit5

Form[] pleasant_outfit6

Form[] pleasant_outfit7

Form[] pleasant_outfit8

Form[] pleasant_outfit9

Form[] pleasant_outfit10
Form[] rainy_outfit0

Form[] rainy_outfit1

Form[] rainy_outfit2

Form[] rainy_outfit3

Form[] rainy_outfit4

Form[] rainy_outfit5

Form[] rainy_outfit6

Form[] rainy_outfit7

Form[] rainy_outfit8

Form[] rainy_outfit9

Form[] rainy_outfit10 /;
Form[] Property snowy_outfit0 Auto

Form[] Property snowy_outfit1 Auto

;/ Form[] snowy_outfit2

Form[] snowy_outfit3

Form[] snowy_outfit4

Form[] snowy_outfit5

Form[] snowy_outfit6

Form[] snowy_outfit7

Form[] snowy_outfit8

Form[] snowy_outfit9

Form[] snowy_outfit10
Form[] playerh_outfit0

Form[] playerh_outfit1

Form[] playerh_outfit2

Form[] playerh_outfit3

Form[] playerh_outfit4

Form[] playerh_outfit5

Form[] playerh_outfit6

Form[] playerh_outfit7

Form[] playerh_outfit8

Form[] playerh_outfit9

Form[] playerh_outfit10 /;
;/ Form[] swimming_outfit0

Form[] swimming_outfit1

Form[] swimming_outfit2

Form[] swimming_outfit3

Form[] swimming_outfit4

Form[] swimming_outfit5

Form[] swimming_outfit6

Form[] swimming_outfit7

Form[] swimming_outfit8

Form[] swimming_outfit9

Form[] swimming_outfit10 /;
Int Property Index Auto
Event OnConfigInit()

Pages = New String[11]

Pages[0] = Game.GetPlayer().GetBaseObject().Getname() as String

Pages[1] = "Empty"

Pages[2] = "Empty"

Pages[3] = "Empty"

Pages[4] = "Empty"

Pages[5] = "Empty"

Pages[6] = "Empty"

Pages[7] = "Empty"

Pages[8] = "Empty"

Pages[9] = "Empty"

Pages[10] = "Empty"
EndEvent


Event OnPageReset(String a_page)



SetCursorFillMode(TOP_TO_BOTTOM)

AddEmptyOption()

AddEmptyOption()

AddHeaderOption("$Default/Combat")

AddEmptyOption()

default = AddToggleOption("$Outfit_set?", _toggle_default)

SetCursorPosition(1)

AddHeaderOption("$Town/City")

SetCursorPosition(3)

pleasant = AddToggleOption("$Pleasant_Outfit_set?", _toggle_pleasant)

SetCursorPosition(5)

rainy = AddToggleOption("$Cloudy/Rainy_outfit_set?", _toggle_rainy)

SetCursorPosition(7)

snowy = AddToggleOption("$Snowy_outfit_set?", _toggle_snowy)

SetCursorPosition(11)

AddHeaderOption("$Player_house")

SetCursorPosition(13)

playerh = AddToggleOption("$Outfit_set?", _toggle_playerh)

;/ SetCursorPosition(17)

AddHeaderOption("$Swimming/Wading")

SetCursorPosition(19)

swimming = AddToggleOption("Swimming outfit set", _toggle_swimming) /;
EndEvent
Event OnOptionSelect(int a_option)

int i

i = 0

While i < Pages.Length

  If Pages[i] == CurrentPage

   Index = i

  EndIf

  i = i + 1

EndWhile



If ( a_option == default )

_toggle_default = !_toggle_default

SetToggleOptionValue(a_option, _toggle_default)

  If _toggle_default == True

   dz_set_name()

   If Named == True

    dz_get_kit(aRef,default)

   EndIf

  ElseIf _toggle_default == False

    dz_unset_kit(default)

  EndIf

ElseIf ( a_option == town )

_toggle_town = !_toggle_town

SetToggleOptionValue(a_option, _toggle_town)

  If _toggle_town == True

   dz_set_name()

   If Named == True

    dz_get_kit(aRef,town)

   EndIf

  ElseIf _toggle_town == False

    dz_unset_kit(town)

  EndIf

ElseIf ( a_option == rainy )

_toggle_rainy = !_toggle_rainy

SetToggleOptionValue(a_option, _toggle_rainy)

  If _toggle_rainy == True

   dz_set_name()

   If Named == True

    dz_get_kit(aRef,rainy)

   EndIf

  ElseIf _toggle_rainy == False

    dz_unset_kit(rainy)

  EndIf

;/ ElseIf ( a_option == pleasant )

_toggle_pleasant[Index] = !_toggle_pleasant[Index]

SetToggleOptionValue(a_option, _toggle_pleasant[Index])

  If _toggle_pleasant[Index] == True

   dz_set_name()

   If Named == True

    dz_get_kit(aRef,pleasant)

   EndIf

  ElseIf _toggle_pleasant[Index] == False

    dz_unset_kit(pleasant)

  EndIf /;

ElseIf ( a_option == snowy )

_toggle_snowy = !_toggle_snowy

SetToggleOptionValue(a_option, _toggle_snowy)

  If _toggle_snowy == True

   dz_set_name()

   If Named == True

    dz_get_kit(aRef,snowy)

   EndIf

  ElseIf _toggle_snowy == False

    dz_unset_kit(snowy)

  EndIf

;/ ElseIf ( a_option == playerh )

_toggle_playerh[Index] = !_toggle_playerh[Index]

SetToggleOptionValue(a_option, _toggle_playerh[Index])

  If _toggle_playerh[Index] == True

   dz_set_name()

   If Named == True

    dz_get_kit(aRef,playerh)

   EndIf

  ElseIf _toggle_playerh[Index] == False

    dz_unset_kit(playerh)

  EndIf /;

;/ ElseIf ( a_option == swimming )

_toggle_swimming[Index] = !_toggle_swimming[Index]

SetToggleOptionValue(a_option, _toggle_swimming[Index])

  If _toggle_swimming[Index] == True

   dz_set_name()

   If Named == True

    dz_get_kit(aRef,swimming)

   EndIf

  ElseIf _toggle_swimming[Index] == False

    dz_unset_kit(swimming)

  EndIf /;

EndIf
EndEvent
 
Function dz_get_kit(Actor ActRef, Int aOutfit)
Weapon Lefthand

Weapon Righthand

Form[] Items

;Form[] outfit_name

;Lefthand = ActRef.GetEquippedWeapon(True)      ;store the left hand weapon - if any

;Righthand = ActRef.GetEquippedWeapon(False)      ;store the righthand weapon - if any

Items = PO3_SKSEFunctions.AddAllEquippedItemsToArray(ActRef)  ;store all equipped items in an array using https://www.nexusmods.com/skyrimspecialedition/mods/22854
If aOutfit == default

If index == 0

  default_outfit0 = Items

ElseIf index == 1

  default_outfit1 = Items

ElseIf index == 2

  default_outfit2 = Items

ElseIf index == 3

  default_outfit3 = Items

ElseIf index == 4

  default_outfit4 = Items

ElseIf index == 5

  default_outfit5 = Items

ElseIf index == 6

  default_outfit6 = Items

ElseIf index == 7

  default_outfit7 = Items

ElseIf index == 8

  default_outfit8 = Items

ElseIf index == 9

  default_outfit9 = Items

ElseIf index == 10

  default_outfit10 = Items

EndIf

;debug.messagebox("Outfit name = "+outfit_name)

ElseIf aOutfit == town

If index == 0

  town_outfit0 = Items

ElseIf index == 1

  town_outfit1 = Items

ElseIf index == 2

  town_outfit2 = Items

ElseIf index == 3

  town_outfit3 = Items

ElseIf index == 4

  town_outfit4 = Items

ElseIf index == 5

  town_outfit5 = Items

ElseIf index == 6

  town_outfit6 = Items

ElseIf index == 7

  town_outfit7 = Items

ElseIf index == 8

  town_outfit8 = Items

ElseIf index == 9

  town_outfit9 = Items

ElseIf index == 10

  town_outfit10 = Items

EndIf

;/ ElseIf aOutfit == pleasant

If index == 0

  pleasant_outfit0 = Items

ElseIf index == 1

  pleasant_outfit1 = Items

ElseIf index == 2

  pleasant_outfit2 = Items

ElseIf index == 3

  pleasant_outfit3 = Items

ElseIf index == 4

  pleasant_outfit4 = Items

ElseIf index == 5

  pleasant_outfit5 = Items

ElseIf index == 6

  pleasant_outfit6 = Items

ElseIf index == 7

  pleasant_outfit7 = Items

ElseIf index == 8

  pleasant_outfit8 = Items

ElseIf index == 9

  pleasant_outfit9 = Items

ElseIf index == 10

  pleasant_outfit10 = Items

EndIf

ElseIf aOutfit == rainy

If index == 0

  rainy_outfit0 = Items

ElseIf index == 1

  rainy_outfit1 = Items

ElseIf index == 2

  rainy_outfit2 = Items

ElseIf index == 3

  rainy_outfit3 = Items

ElseIf index == 4

  rainy_outfit4 = Items

ElseIf index == 5

  rainy_outfit5 = Items

ElseIf index == 6

  rainy_outfit6 = Items

ElseIf index == 7

  rainy_outfit7 = Items

ElseIf index == 8

  rainy_outfit8 = Items

ElseIf index == 9

  rainy_outfit9 = Items

ElseIf index == 10

  rainy_outfit10 = Items

EndIf

ElseIf aOutfit == snowy

If index == 0

  snowy_outfit0 = Items

ElseIf index == 1

  snowy_outfit1 = Items

ElseIf index == 2

  snowy_outfit2 = Items

ElseIf index == 3

  snowy_outfit3 = Items

ElseIf index == 4

  snowy_outfit4 = Items

ElseIf index == 5

  snowy_outfit5 = Items

ElseIf index == 6

  snowy_outfit6 = Items

ElseIf index == 7

  snowy_outfit7 = Items

ElseIf index == 8

  snowy_outfit8 = Items

ElseIf index == 9

  snowy_outfit9 = Items

ElseIf index == 10

  snowy_outfit10 = Items

EndIf /;

;/ ElseIf aOutfit == playerh

If index == 0

  playerh_outfit0 = Items

ElseIf index == 1

  playerh_outfit1 = Items

ElseIf index == 2

  playerh_outfit2 = Items

ElseIf index == 3

  playerh_outfit3 = Items

ElseIf index == 4

  playerh_outfit4 = Items

ElseIf index == 5

  playerh_outfit5 = Items

ElseIf index == 6

  playerh_outfit6 = Items

ElseIf index == 7

  playerh_outfit7 = Items

ElseIf index == 8

  playerh_outfit8 = Items

ElseIf index == 9

  playerh_outfit9 = Items

ElseIf index == 10

  playerh_outfit10 = Items

EndIf /;

;/ ElseIf aOutfit == swimming

If index == 0

  swimming_outfit0 = Items

ElseIf index == 1

  swimming_outfit1 = Items

ElseIf index == 2

  swimming_outfit2 = Items

ElseIf index == 3

  swimming_outfit3 = Items

ElseIf index == 4

  swimming_outfit4 = Items

ElseIf index == 5

  swimming_outfit5 = Items

ElseIf index == 6

  swimming_outfit6 = Items

ElseIf index == 7

  swimming_outfit7 = Items

ElseIf index == 8

  swimming_outfit8 = Items

ElseIf index == 9

  swimming_outfit9 = Items

ElseIf index == 10

  swimming_outfit10 = Items

EndIf /;

Endif
EndFunction
Function dz_unset_kit(Int aOutfit)

Form[] a

If aOutfit == default

If index == 0

  default_outfit0 = a

ElseIf index == 1

  default_outfit1 = a

ElseIf index == 2

  default_outfit2 = a

ElseIf index == 3

  default_outfit3 = a

ElseIf index == 4

  default_outfit4 = a

ElseIf index == 5

  default_outfit5 = a

ElseIf index == 6

  default_outfit6 = a

ElseIf index == 7

  default_outfit7 = a

ElseIf index == 8

  default_outfit8 = a

ElseIf index == 9

  default_outfit9 = a

ElseIf index == 10

  default_outfit10 = a

EndIf

;debug.messagebox("Outfit name = "+outfit_name)

ElseIf aOutfit == town

If index == 0

  town_outfit0 = a

ElseIf index == 1

  town_outfit1 = a

ElseIf index == 2

  town_outfit2 = a

ElseIf index == 3

  town_outfit3 = a

ElseIf index == 4

  town_outfit4 = a

ElseIf index == 5

  town_outfit5 = a

ElseIf index == 6

  town_outfit6 = a

ElseIf index == 7

  town_outfit7 = a

ElseIf index == 8

  town_outfit8 = a

ElseIf index == 9

  town_outfit9 = a

ElseIf index == 10

  town_outfit10 = a

EndIf

;/ ElseIf aOutfit == pleasant

If index == 0

  pleasant_outfit0 = a

ElseIf index == 1

  pleasant_outfit1 = a

ElseIf index == 2

  pleasant_outfit2 = a

ElseIf index == 3

  pleasant_outfit3 = a

ElseIf index == 4

  pleasant_outfit4 = a

ElseIf index == 5

  pleasant_outfit5 = a

ElseIf index == 6

  pleasant_outfit6 = a

ElseIf index == 7

  pleasant_outfit7 = a

ElseIf index == 8

  pleasant_outfit8 = a

ElseIf index == 9

  pleasant_outfit9 = a

ElseIf index == 10

  pleasant_outfit10 = a

EndIf

ElseIf aOutfit == rainy

If index == 0

  rainy_outfit0 = a

ElseIf index == 1

  rainy_outfit1 = a

ElseIf index == 2

  rainy_outfit2 = a

ElseIf index == 3

  rainy_outfit3 = a

ElseIf index == 4

  rainy_outfit4 = a

ElseIf index == 5

  rainy_outfit5 = a

ElseIf index == 6

  rainy_outfit6 = a

ElseIf index == 7

  rainy_outfit7 = a

ElseIf index == 8

  rainy_outfit8 = a

ElseIf index == 9

  rainy_outfit9 = a

ElseIf index == 10

  rainy_outfit10 = a

EndIf

ElseIf aOutfit == snowy

If index == 0

  snowy_outfit0 = a

ElseIf index == 1

  snowy_outfit1 = a

ElseIf index == 2

  snowy_outfit2 = a

ElseIf index == 3

  snowy_outfit3 = a

ElseIf index == 4

  snowy_outfit4 = a

ElseIf index == 5

  snowy_outfit5 = a

ElseIf index == 6

  snowy_outfit6 = a

ElseIf index == 7

  snowy_outfit7 = a

ElseIf index == 8

  snowy_outfit8 = a

ElseIf index == 9

  snowy_outfit9 = a

ElseIf index == 10

  snowy_outfit10 = a

EndIf

ElseIf aOutfit == playerh

If index == 0

  playerh_outfit0 = a

ElseIf index == 1

  playerh_outfit1 = a

ElseIf index == 2

  playerh_outfit2 = a

ElseIf index == 3

  playerh_outfit3 = a

ElseIf index == 4

  playerh_outfit4 = a

ElseIf index == 5

  playerh_outfit5 = a

ElseIf index == 6

  playerh_outfit6 = a

ElseIf index == 7

  playerh_outfit7 = a

ElseIf index == 8

  playerh_outfit8 = a

ElseIf index == 9

  playerh_outfit9 = a

ElseIf index == 10

  playerh_outfit10 = a

EndIf

ElseIf aOutfit == swimming

If index == 0

  swimming_outfit0 = a

ElseIf index == 1

  swimming_outfit1 = a

ElseIf index == 2

  swimming_outfit2 = a

ElseIf index == 3

  swimming_outfit3 = a

ElseIf index == 4

  swimming_outfit4 = a

ElseIf index == 5

  swimming_outfit5 = a

ElseIf index == 6

  swimming_outfit6 = a

ElseIf index == 7

  swimming_outfit7 = a

ElseIf index == 8

  swimming_outfit8 = a

ElseIf index == 9

  swimming_outfit9 = a

ElseIf index == 10

  swimming_outfit10 = a

EndIf /;

Endif

EndFunction
;;set the name of the menu page

Function dz_set_name()

name = Game.GetCurrentCrosshairRef().GetBaseObject().GetName()
;String current_name

int i

i = 0

While i < Pages.Length

  If Pages[i] == CurrentPage

   Index = i

  EndIf

  i = i + 1

EndWhile

debug.messagebox("Current page is "+CurrentPage)

debug.messagebox("Page no is "+Index)

i = 0

While i < Pages.Length

  If Pages[i] == name && Pages[i] != CurrentPage

   debug.messagebox("This Name is already in use")

   Named = False

   Return

  EndIf

  i = i + 1

EndWhile

  If CurrentPage == name

   Named = True

   Return

  Else

   Pages[Index] = name

   Teammates[Index] = Game.GetCurrentCrosshairRef() as Actor

   Named = True

   ;ForcePageReset()

   Return

  EndIf

Named = True

Return

EndFunction

 

 

 

 

diziet

 

edit: and there are no references to the mcm quest at all in Papyrus.0.log

Link to comment
Share on other sites

Well my apologies to you for your having taken the time to reply, and to the rest of the planet for making the newbiest of all mistakes.

Somewhen, for no reason I can fathom, in between editing and testing I disabled the plugin esp in Vortex!

I would never have checked if it wasn't your suggestion that made me open the console in game and find no mention of the quest.

But I am embarrassed :)

 

diziet

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...