채팅0

    형들 물약 스크립트 이거맞음?

    조회수 436

    -- Add a constant for potion item ID

    local HEALTH_POTION_ID = 2120000 -- Replace with the actual ID of your health potion item


    -- Add a function for automatic potion consumption

    local function autoConsumePotion()

    local playerHealth = _UserService.LocalPlayer.WsCharacterData.HP

    local potionThreshold = 50 -- Adjust the threshold as needed

    if playerHealth < potionThreshold then
        _ItemConsumeLogic:TryConsumeFromFuncKey(HEALTH_POTION_ID)
    end

    end


    -- ... (your existing code)


    -- Modify the existing user_check_func to include potion consumption

    zz_y7.user_check_func = function ()

    -- ... (your existing code)

    -- Add potion consumption check
    autoConsumePotion()

    end


    -- ... (your existing code)

    댓글1

    회원프로필

    되셨나요?

    2024.02.04 00:19

      게시글 리스트
      제목작성자작성일조회
      2747102-03566
      2747002-03264
      2746902-03352
      2746802-03232
      2746702-03303
      2746602-03437
      2746502-03362
      2746402-03669
      2746302-03373
      2746202-03538
      2746102-03309
      2746002-03271
      2745902-03243
      2745802-03254
      2745702-03260
      2745602-03291
      2745502-03344
      2745402-03419
      2745302-03465
      2745202-03506
      안내 배너 이미지