Jump to content

Cambiar Renglon


Recommended Posts

Posted

hola ise este script que guarda una informacion en un txt pero me la guarda mal.... osea me la guarda asi:

HulkingCrocodile58 (Narutimmy) envio 10 Reputacion a HulkingCrocodile58HulkingCrocodile58 (Narutimmy) envio 10 Reputacion a HulkingCrocodile58 

Y lo que yo quiero es que la guarde asi:

HulkingCrocodile58 (Narutimmy) envio 10 Reputacion a HulkingCrocodile58 
HulkingCrocodile58 (Narutimmy) envio 10 Reputacion a HulkingCrocodile58 

local file = fileOpen("REP.log") 
if not file then 
file = fileCreate("REP.log") 
outputDebugString("Creating REP.log") 
end 
fileSetPos ( file, fileGetSize ( file ) ) 
local written = fileWrite( file, ""..chatterName .. " ("..ussser..") envio " ..quantity.." "..item.." a " ..pName) 
fileFlush(file) 
fileClose(file) 

mtasa://66.85.14.178:22003

350x20_FFFFFF_FFFFFF_000000_000000.png

Ts3: thezombiworld.com:7777

350x20_FFFFFF_FFFFFF_000000_000000.png

  • MTA Team
Posted
local file = fileOpen("REP.log") 
if not file then 
file = fileCreate("REP.log") 
outputDebugString("Creating REP.log") 
end 
fileSetPos ( file, fileGetSize ( file ) ) 
local written = fileWrite( file, ""..chatterName .. " ("..ussser..") envio " ..quantity.." "..item.." a " ..pName.."\n") 
fileFlush(file) 
fileClose(file) 

DevOps Engineer, Cloud Advocate & Security Engineer(Red Team) | Coffee, Containers & Burp

 
Posted
local file = fileOpen("REP.log") 
if not file then 
file = fileCreate("REP.log") 
outputDebugString("Creating REP.log") 
end 
fileSetPos ( file, fileGetSize ( file ) ) 
local written = fileWrite( file, ""..chatterName .. " ("..ussser..") envio " ..quantity.." "..item.." a " ..pName.."\n") 
fileFlush(file) 
fileClose(file) 

solo con el /n ?

EDIT:

GRACIAS!

mtasa://66.85.14.178:22003

350x20_FFFFFF_FFFFFF_000000_000000.png

Ts3: thezombiworld.com:7777

350x20_FFFFFF_FFFFFF_000000_000000.png

  • MTA Team
Posted

Si con eso debería funcionarte, sino proba agregarle tambien \r pero eso te generaría dos renglones en algunos programas que leen tanto \n como \r

De nada

DevOps Engineer, Cloud Advocate & Security Engineer(Red Team) | Coffee, Containers & Burp

 
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...