Jump to content

writing text


Recommended Posts

 

Hey) I was able to get the path to the file and even write it, but with the "a" type, the code does not want to write the text, with the "w" type, the mod writes, but as it should be for this type, it deletes all the previous text. I will ask those who know for io.open to help. Thank you.
 ^ _ ^

 

local function OnDead(inst, attacker)
local inputFileName = "../mods/Test/log.lua"
local FileWrite
    FileWrite = G.io.open(inputFileName, "a+")
    FileWrite:write(inst.name, G.os.date(" %Y.%m.%d %H:%M\n"))
    FileWrite:close()
end
Link to comment
Share on other sites

On 1/17/2022 at 3:45 PM, Lanthals said:

I also need an answer. After all, I write a lot, I read and recently I read about the advantages and disadvantages of active listening on the page. But now I am developing an application that will be aimed at developing such a hearing function for people of all ages.

Thank you for distributing. I have already started writing this.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...