3DMGAME 3DM首页 新闻中心 前瞻 | 评测 游戏库 热门 | 最新 攻略中心 攻略 | 秘籍 下载中心 游戏 | 汉化 购买正版 论坛

注册 登录

QQ登录

只需一步,快速开始

查看: 1129|回复: 3
打印 上一主题 下一主题

[修改] 求高人能不能参考第一个的脚本,编写一个让全队在比赛中都能99能力+全徽章技能

[复制链接]

63

主题

1210

帖子

585

积分

高级玩家

Rank: 4

贡献度
80
金元
2652
积分
585
精华
0
注册时间
2010-10-5
跳转到指定楼层
主题
发表于 2024-12-28 23:05 | 只看该作者 |只看大图 回帖奖励 |倒序浏览 |阅读模式
1000金元
求高人能不能参考第一个的脚本,编写一个让全队在比赛中都能99能力+全徽章技能,但是关闭游戏会自动恢复原始数据,不是直接修改属性的那种。


require 'imports/career_mode/enums'
require 'imports/other/playstyles_enum'

-- Script that will keep your VPRO player in player career mode at 99 OVR

-- You can change the ID if you want to apply that to other player
local VPRO_PLAYERID = 30999

-- Playstyles
-- you can find "IDs" in <YOUR_LIVE_EDITOR_DIR>\lua\libs\v2\imports\other\playstyles_enum.lua

-- Playstyles1 to apply (No limit here I think?)
local playstyles1 = 0

-- Playstyles2 to apply (No limit here I think?)
local playstyles2 = 0

-- Playstyle1+ (Only 1 will work)

local iconplaystyle1 = ENUM_PLAYSTYLE1_TRIVELA + ENUM_PLAYSTYLE1_FINESSE_SHOT + ENUM_PLAYSTYLE1_CHIP_SHOT + ENUM_PLAYSTYLE1_POWER_SHOT + ENUM_PLAYSTYLE1_DEAD_BALL + ENUM_PLAYSTYLE1_POWER_HEADER + ENUM_PLAYSTYLE1_INCISIVE_PASS + ENUM_PLAYSTYLE1_PINGED_PASS + ENUM_PLAYSTYLE1_LONG_BALL_PASS + ENUM_PLAYSTYLE1_TIKI_TAKA + ENUM_PLAYSTYLE1_WHIPPED_PASS + ENUM_PLAYSTYLE1_JOCKEY + ENUM_PLAYSTYLE1_BLOCK + ENUM_PLAYSTYLE1_INTERCEPT + ENUM_PLAYSTYLE1_ANTICIPATE + ENUM_PLAYSTYLE1_SLIDE_TACKLE +
ENUM_PLAYSTYLE1_BRUISER + ENUM_PLAYSTYLE1_TECHNICAL + ENUM_PLAYSTYLE1_RAPID + ENUM_PLAYSTYLE1_FLAIR + ENUM_PLAYSTYLE1_FIRST_TOUCH + ENUM_PLAYSTYLE1_TRICKSTER + ENUM_PLAYSTYLE1_PRESS_PROVEN + ENUM_PLAYSTYLE1_QUICK_STEP + ENUM_PLAYSTYLE1_RELENTLESS + ENUM_PLAYSTYLE1_LONG_THROW + ENUM_PLAYSTYLE1_ACROBATIC + ENUM_PLAYSTYLE1_AERIAL
-- Playstyle2+ (Only 1 will work)
local iconplaystyle2 = 0

-- DON'T CHANGE ANYTHING BELOW

local fields_to_edit = {
    -- GK
    "gkdiving",
    "gkhandling",
    "gkkicking",
    "gkpositioning",
    "gkreflexes",

    -- ATTACK
    "crossing",
    "finishing",
    "headingaccuracy",
    "shortpassing",
    "volleys",

    -- DEFENDING
    "defensiveawareness",
    "standingtackle",
    "slidingtackle",

    -- SKILL
    "dribbling",
    "curve",
    "freekickaccuracy",
    "longpassing",
    "ballcontrol",

    -- POWER
    "shotpower",
    "jumping",
    "stamina",
    "strength",
    "longshots",

    -- MOVEMENT
    "acceleration",
    "sprintspeed",
    "agility",
    "reactions",
    "balance",

    -- MENTALITY
    "aggression",
    "composure",
    "interceptions",
    "positioning",
    "vision",
    "penalties",

    "overallrating"
}

function set_99ovr()
    -- Get Players Table
    local players_table = LE.db:GetTable("players")
    local current_record = players_table:GetFirstRecord()
    local playerid = 0

    while current_record > 0 do
        playerid = players_table:GetRecordFieldValue(current_record, "playerid")
        if (playerid == VPRO_PLAYERID) then
           for j=1, #fields_to_edit do
                players_table:SetRecordFieldValue(current_record, fields_to_edit[j], 99)
            end

            -- Playstyles
            players_table:SetRecordFieldValue(current_record, "trait1", playstyles1)
            players_table:SetRecordFieldValue(current_record, "trait2", playstyles2)
            players_table:SetRecordFieldValue(current_record, "icontrait1", iconplaystyle1)
            players_table:SetRecordFieldValue(current_record, "icontrait2", iconplaystyle2)

            -- Clear Player modifier to not affect his ovr
            players_table:SetRecordFieldValue(current_record, "modifier", 0)

            -- 99 Potential
            players_table:SetRecordFieldValue(current_record, "potential", 99)

            SaveVPRO()
            return
        end

        current_record = players_table:GetNextValidRecord()
    end
    LOGGERogError(string.format("Can't find player %d to apply 99ovr", VPRO_PLAYERID))
end

function handle_vpro_reset(events_manager, event_id, event)
    -- Events that reset the vpro attributes
    if (
        event_id == ENUM_CM_EVENT_MSG_USER_MATCH_COMPLETED or
        event_id == ENUM_CM_EVENT_MSG_USER_MATCH_COMPLETED_IN_TOURNAMENT or
        event_id == ENUM_CM_EVENT_MSG_USER_INTERNATIONAL_MATCH_COMPLETED or
        event_id == ENUM_CM_EVENT_MSG_ENTERED_HUB_FIRST_TIME or
        event_id == ENUM_CM_EVENT_MSG_POST_LOAD_PREPARE
    ) then
        set_99ovr()
    end
end

AddEventHandler("post__CareerModeEvent", handle_vpro_reset)


回复

使用道具 举报

63

主题

1210

帖子

585

积分

高级玩家

Rank: 4

贡献度
80
金元
2652
积分
585
精华
0
注册时间
2010-10-5
舒服的沙发
 楼主| 发表于 2024-12-29 20:36 | 只看该作者
顶一个!!!
回复

使用道具 举报

7

主题

176

帖子

395

积分

高级玩家

Rank: 4

贡献度
0
金元
3950
积分
395
精华
0
注册时间
2019-7-2
硬硬的板凳
发表于 2024-12-31 22:42 | 只看该作者
你都经理模式了,LE自己把首发11人全队的属性都拉满,徽章都点上金色不就好了。再简单点,配合CT,刷新编辑球员。勾选金色特技
回复

使用道具 举报

0

主题

12

帖子

17

积分

新手玩家

Rank: 1

贡献度
0
金元
170
积分
17
精华
0
注册时间
2025-2-8
冰凉的地板
发表于 2025-2-8 14:09 | 只看该作者
第五行的30999要改成你需要修改球员的id   用ct修改器看球员id 把30999改成id就可以了
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

Archiver|手机版|3DMGAME ( 京ICP备14006952号-1  沪公网安备 31011202006753号

GMT+8, 2026-5-21 14:06 , Processed in 0.034923 second(s), 17 queries , Memcached On.

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表