default barGirlDancer = [None,0,0,0,0]

#----------------------------------------------------------------------------
# Vip y Caño
#----------------------------------------------------------------------------
label placeBarVIP:

    if not DEVroll:
        $ renpy.block_rollback()

    if julia.storyLvl == 70 and hasItem(playerInventory, "bar_ticket_full"):
        jump juliaStoryLvl70

    if julia.storyLvl == 30 and hasItem(playerInventory, "bar_ticket_full"):
        jump juliaStoryLvl30

    $ playSong("audio/music/dance-Karstenholymoly_-_Liberation.ogg")
    $ playAudio("audio/effects/shop.ogg", 1, True)
    $ playAudio("", 2)

    $ pBarVIP.setPlace()
    call kEffects(kNoise=True, disNoise=0.1, alpNoise=0.4, kSmoke=True, disSmoke=1.2, alpSmoke=0.2, rain=False, fireflies=False, snowArg=True)
    
    call assignGirlDancer()
    show screen screenBarOverlays1
    scene expression "images/renders/bar/barVIP/bar-dance-empty.jpg" with dissolve

    show screen barVIPMenu
    call mainMenu

#----------------------------------------------------------------------------
# Menú del VIP
#----------------------------------------------------------------------------
screen barVIPMenu():

    frame:
        style "placeMenuStyle"
        at sideMenuEffect()
        vbox:
            style "placeMenuIconsStyle"

            if barGirlDancer[0] != None:
                $g = barGirlDancer[0]
                imagebutton auto "images/actions/seeShow_%s.png" action [Jump("barVIPDancePole")] tooltip __("Ver el show de ") + __(g) style "buttonSounds" at sideMenuIconsEffect                

            use timeGPS

#----------------------------------------------------------------------------
# assignGirlDancer
#----------------------------------------------------------------------------
label assignGirlDancer:

    # barGirlDancer = [Nombre, propinaParaDesnudo, propinaActual, horaUltimaPropina, estadoDesnudo, vectorAcumulaCamarasMostradas]
    # Si se cambia algún día/hoarrio cambiarlo también en npc_class
    $ barGirlDancer[0] = None
    if gameTime.day in [1,3,5,7] and gameTime.hour in [20,21]:
        if julia.storyLvl < 60:
            $ barGirlDancer = ["Julia", 1000, 0, 0, 0, []]
    elif gameTime.day in [1,3,5,7] and gameTime.hour in [22,23]:
        $ barGirlDancer = ["Abigail", 750, 0, 0, 0, []]
    elif gameTime.day in [1,3,5,7] and gameTime.hour in [0,1]:
        $ barGirlDancer = ["Nicole", 1000, 0, 0, 0, []]
    elif gameTime.day in [1,3,5,7] and gameTime.hour in [2,3]:
        if julia.storyLvl < 84 or not isabellaPartner:
            $ barGirlDancer = ["Isabella", 1000, 0, 0, 0, []]
    elif gameTime.day in [1,3,5,7] and gameTime.hour in [4,5]:
        $ barGirlDancer = ["Evelyn", 750, 0, 0, 0, []]
    elif gameTime.day in [2,4,6] and gameTime.hour in [20,21]:
        $ barGirlDancer = ["Monica", 750, 0, 0, 0, []]
    elif gameTime.day in [2,4,6] and gameTime.hour in [22,23]:
        $ barGirlDancer = ["Naomi", 750, 0, 0, 0, []]
    elif gameTime.day in [2,4,6] and gameTime.hour in [0,1]:
        if julia.storyLvl < 84:
            $ barGirlDancer = ["Amelia", 1000, 0, 0, 0, []]
    elif gameTime.day in [2,4,6] and gameTime.hour in [2,3]:
        $ barGirlDancer = ["Olivia", 1000, 0, 0, 0, []]
    elif gameTime.day in [2,4,6] and gameTime.hour in [4,5]:
        $ barGirlDancer = ["Alicia", 750, 0, 0, 0, []]

    return

#----------------------------------------------------------------------------
# barVIPDancePole
#----------------------------------------------------------------------------
label barVIPDancePole:

    call hideFullInterface
    if barGirlDancer[0] == None:
        sRockyT ashamed "No hay nadie en el escenario, probaré en otro momento..."
        jump placeBarVIP

    call fadeEffect()

    $ tipChances = 4
    while tipChances > 0:

        call showGirlDance()

        if tipChances > 1:
            menu:
                "Seguir viendo el show":
                    pass
                "Dar propina de $100" if playerInventory.money >= 100:
                    $ barGirlDancer[2] = barGirlDancer[2] + 100
                    $ barMoneySpent = barMoneySpent + 100
                    $ playerInventory.removeMoney(100)
                    $ barGirlDancer[3] = gameTime.totalHours
                "Dar propina de $250" if playerInventory.money >= 250:
                    $ barGirlDancer[2] = barGirlDancer[2] + 250
                    $ barMoneySpent = barMoneySpent + 250
                    $ playerInventory.removeMoney(250)
                    $ barGirlDancer[3] = gameTime.totalHours
                "Dar propina de $500" if playerInventory.money >= 500:
                    $ barGirlDancer[2] = barGirlDancer[2] + 500
                    $ barMoneySpent = barMoneySpent + 500
                    $ playerInventory.removeMoney(500)
                    $ barGirlDancer[3] = gameTime.totalHours
                "Hacer oferta sexual $2000" if barGirlDancer[4] == 2 and playerInventory.money >= 2000 and tipChances == 2:
                    call sexOffer
                "Irse del show":
                    hide screen danceOverlay1
                    call timeAdvance(True, 2)
                    if gameTime.hour == 6:
                        jump bar
                    else:
                        jump placeBarVIP

        $ tipChances = tipChances - 1

    scene expression "images/renders/bar/barVIP/bar-dance-empty.jpg" with dissolveBig
    sRockyT devil "Terminó el show, quizás pueda conseguir un poco más la próxima..."

    call timeAdvance(True, 2)
    if gameTime.hour == 6:
        jump bar
    else:
        jump placeBarVIP

#----------------------------------------------------------------------------
# sexOffer
#----------------------------------------------------------------------------
label sexOffer():

    $ tipChances = 0
    scene expression "images/renders/bar/barVIP/" + normalize(barGirlDancer[0]) + "/bar-dance-" + normalize(barGirlDancer[0]) + "-pose2c-cam5.jpg" with dissolve:
        dizzy(0.4,2.0)
    if barGirlDancer[0] == "Julia":
        $ playSong("audio/music/humor-fluffing-a-duck-by-kevin-macleod-from-filmmusic-io.ogg")
        scene expression "images/renders/bar/barVIP/julia/bar-dance-julia-stopDance002.jpg" with hpunch
        sJulia surprise "¿[sRocky.name]? ¿Qué haces aquí? ¿Donde estoy?"
        scene expression "images/renders/bar/barVIP/bar-dance-empty.jpg" with dissolveBig
        sRockyT ashamed "Salió corriendo del escenario..."
        sRockyT ashamed "Parecía perdida... Ni siquiera me había reconocido..."
        sRockyT ashamed "¿Le ocurrirá algo?"
        call timeAdvance(True, 2)
        jump placeBarVIP
    elif barGirlDancer[0] == "Abigail":
         if achiIsComplete("repeMaintenanceRoomAbigailFuck"):
            $ playerInventory.removeMoney(2000)
            $ barMoneySpent = barMoneySpent + 2000
            sAbigail sexy "Te lo ganaste, sígueme... Tengo una sorpresa para ti."
            jump barBedroomAbigailNaomiFuckA
         else:
            sAbigail sexy "No hago ese tipo de cosas... Y menos aún con estudiantes..."
    elif barGirlDancer[0] == "Alicia":
        sAlicia sexy "Por el momento me podrás tener solo en tus sueños..."
    elif barGirlDancer[0] == "Amelia":
        sAmelia sexy "No existen posibilidades de que tú puedas hacer algo conmigo..."
    elif barGirlDancer[0] == "Evelyn":
        if lucy.storyLvl >= 50:
            $ playerInventory.removeMoney(2000)
            $ barMoneySpent = barMoneySpent + 2000
            sEvelyn sexy "Mmmm... ¡Vamos a divertirnos!"
            jump barBedroomEvelynFuckA
        else:
            sEvelyn sexy "Disculpa, pero te quedarás con las ganas... Solo miembros VIP..."
    elif barGirlDancer[0] == "Isabella":
        sIsabella sexy "¿Te gustaría verdad? Pero tendrás que olvidarte..."
    elif barGirlDancer[0] == "Monica":
        sMonica sexy "Por el momento me alcanza solo con bailar... Quizás en otro momento..."
    elif barGirlDancer[0] == "Naomi":
         if achiIsComplete("repeMaintenanceRoomNaomiFuck"):
            $ playerInventory.removeMoney(2000)
            $ barMoneySpent = barMoneySpent + 2000
            sNaomi sexy "Te lo ganaste, sígueme... Tengo una sorpresa para ti."
            jump barBedroomAbigailNaomiFuckA
         else:
            sNaomi sexy "No hago ese tipo de cosas... Y menos aún con estudiantes..."
    elif barGirlDancer[0] == "Nicole":
        sNicole sexy "Te agradezco, pero no me dedico a esas cosas..."
    elif barGirlDancer[0] == "Olivia":
         if emma.storyLvl >= 60:
            $ playerInventory.removeMoney(2000)
            $ barMoneySpent = barMoneySpent + 2000
            sOlivia sexy "Contigo lo hubiese hecho gratis, pero gracias igual..."
            sOlivia sexy "Acompáñame a casa, siempre es bueno un guardaespaldas para el viaje..."
            sRocky devil "Claro..."
            jump emmaHomeOliviaBedroomBarFuckA
         else:
            sOlivia sexy "No hago ese tipo de cosas... ¿Cómo piensas eso de mi?"

    return

#----------------------------------------------------------------------------
# showGirlDance
#----------------------------------------------------------------------------
label showGirlDance():

    show screen danceOverlay1

    $ v = True
    while v:
        $ randomPose = numberRandom(1,5)
        if randomPose not in barGirlDancer[5]:
            $ barGirlDancer[5].append(randomPose)
            $ v = False

    $ nudeState = "a"
    $ song = "sexy-octoblues-by-kevin-macleod-from-filmmusic-io.ogg"
    if barGirlDancer[2] >= (barGirlDancer[1] / 2):
        $ nudeState = "b"
        $ barGirlDancer[4] = 1
        $ song = "sexy-texasradiofish_-_Not_Quite_Two_Minute_Blues.ogg"
    if barGirlDancer[2] >= barGirlDancer[1]:
        $ nudeState = "c"
        $ barGirlDancer[4] = 2
        $ song = "sexy-octoblues-by-kevin-macleod-from-filmmusic-io.ogg"

    $ playSong("audio/music/" + song)

    $ tmp = []
    while len(tmp) < 7:
        $ randomCam = numberRandom(1,7)
        if randomCam not in tmp:
            $ tmp.append(randomCam)
            $ player.addSex(1, True, False)
            scene expression "images/renders/bar/barVIP/" + normalize(barGirlDancer[0]) + "/bar-dance-" + normalize(barGirlDancer[0]) + "-pose" + str(randomPose) + nudeState + "-cam" + str(randomCam) + ".jpg" with dissolve:
                dizzy(0.4,2.0)
            pause 4

    if PLACE.code == "barVIP" and monica.place == "barVIP" and QB.isCompletedGoal("showMonica") == 2:
        if persistent.lang == None:
            sRockyT think "Ahí está Monica. Es verdad que baila en estos horarios durante la semana."
            sRockyT sexy "La estrategia será desgastarla, no debe tener buen estado físico viviendo de noche."
        else:
            sRockyT think "There's Monica. It is true that she dances at these times during the week."
            sRockyT sexy "The strategy will be to wear her down, she must not be in good physical condition living at night."
        $ uma.addStoryLvl(2, False)
        $ QB.completeGoal("showMonica")
        $ achiComplete("umaStory01")


    return

#----------------------------------------------------------------------------
# danceOverlay1
#----------------------------------------------------------------------------
screen danceOverlay1:

    image "danceFade1"
    image "danceLights1"

#----------------------------------------------------------------------------
# danceLights1
#----------------------------------------------------------------------------
image danceLights1:
    "images/sexFighter/red.webp"
    alpha 0.35
    pause 0.42
    "images/sexFighter/green.webp"
    alpha 0.35
    pause 0.42
    "images/sexFighter/blue.webp"
    alpha 0.35
    pause 0.42
    repeat

#----------------------------------------------------------------------------
# danceFade1
#----------------------------------------------------------------------------
image danceFade1:
    "images/sexFighter/dark_overlay.webp"
    alpha 0.5