17 thoughts on “SHOW MMR after EVERY RANKED GAME (How to In Dota 2)

  1. Noob question, i just funished my core and support. Whether i play supp or core my % in medal should change right? I hav3 higer core mmr and i played support but my % in medal ddnt go up😔

  2. Not tested it after a game but my support mmr is 20 less than it says in stats, and my core is 10 less than what is says it stats. Any reason? Great video though, man

  3. Feel free to ask questions here 🙂
    Paste this in coreinit.lua

    local UpdateMMR = function()

    local update = 'hostfile "";developer 1;dota_game_account_client_debug | hostfile;developer 0; dota_mmr | hostfile | hostfile'

    SendToServerConsole( update ) — update current mmr cvar

    end

    local HideMMR = function(t) SendToServerConsole( 'top_bar_message "" ' .. t ) end

    local ShowMMR = function(t)

    UpdateMMR()

    local current = Convars:GetStr( 'hostfile' ):upper() — get current mmr cvar

    local supp, core, bs = string.match(current, "%u+ : (%w+) [%u%_]+ = %u+ : ([%w]+) [%u%_]+ = [%u%_]+: ([%w]+)")

    local previous = Convars:GetStr( 'cl_class' ) — get previous mmr cvar

    if previous == (""..core.."."..supp.."") then — same MMR

    print("ShowMMR same")

    Msg(GetSystemDate().." "..GetSystemTime().." Behavior: "..bs.. " Core: "..core.." Support: "..supp.."nn")

    elseif previous == "default" then — initial script setup or cvars reset

    print("ShowMMR init")

    Msg(GetSystemDate().." "..GetSystemTime().." Behavior: "..bs.. " Core: "..core.." Support: "..supp.."nn")

    Convars:SetStr( 'cl_class', core.."."..supp ) — set previous MMR cvar

    else — changed MMR

    local core1, supp1 = string.match(previous, "(%w+).(%w+)")

    local c, s, c1, s1, c1c, s1s = tonumber(core), tonumber(supp), tonumber(core1), tonumber(supp1), 0, 0

    if c ~= nil and c1 ~= nil then c1c = c – c1 elseif c ~= nil then c1c = c elseif c1 ~= nil then c1c = 0 – c1 end

    if s ~= nil and s1 ~= nil then s1s = s – s1 elseif s ~= nil then s1s = s elseif s1 ~= nil then s1s = 0 – s1 end

    local tcolor, ccolor, scolor = 0, "00FF00FF", "00FF00FF"

    if c1c < 0 then tcolor = 1 ccolor = "FF0000FF" else c1c = "+"..c1c end

    if s1s < 0 then tcolor = 1 scolor = "FF0000FF" else s1s = "+"..s1s end

    local cmd = "grep . "..GetSystemDate().." "..GetSystemTime().." Behavior: "..bs.." Core: "..core.." ;log_color General "

    cmd = cmd.. ccolor.." | grep %;grep . "..c1c.." ;log_color General 00000000 | grep %;grep . Support: "..supp

    cmd = cmd.. " ;log_color General "..scolor.." | grep %;grep . "..s1s.." ;log_color General 00000000 | grep %;echoln;echoln"

    print("ShowMMR changed")

    SendToServerConsole(cmd) — pretty print MMR changes

    Convars:SetStr( 'cl_class', core.."."..supp ) — set previous MMR cvar to the current one

    local VScheduler = EntIndexToHScript(0) — if there are entities loaded, than vscheduler is available

    if VScheduler then

    local roses_are_red_violetes_are_blue = 'Core: '..c1c..("t"):rep(10)..'BS: '..bs..("t"):rep(10)..'Support: '..s1s

    SendToServerConsole('top_bar_message "'..roses_are_red_violetes_are_blue..'" '..tcolor..';') — show top bar message

    VScheduler:SetContextThink( "GabenPlz", function() HideMMR(tcolor) end, 8 ) — hide after 8 seconds

    end

    end

    end

    if SendToServerConsole then — local server only [ VScripts loads two vm's, one for sv, one for cl ]

    UpdateMMR()

    ListenToGameEvent("player_connect_full", ShowMMR, nil) — show message after each new map / disconnect

    end

Leave a Reply

Your email address will not be published. Required fields are marked *