How to eliminate cloning
#1

Hello dear people of forum samp today I come to pose an error that I have in the map editor and I do not know how to solve it good is the next I was mapping and and I accidentally gave several times to the "IMPORT PASTE" AND AGAIN, to the final and I just cloned the entire map and I've been deleting the objects object x I've been almost a month in that hahaha plan, what happens is that mapping contains 980 lines of objects and it is difficult to know what are cloned and I would like to know if there is a program that can solve
this error that tells me if a line is repeated to erase it or already exists, I do not know if I explain myself, forgive me, my english is from the nasa salu2
Reply
#2

Do you have the map as text file, or database?

If you have it in a database, export it to code.

Then paste the code into a file called "input.txt".

Create another file called "unique.bat" in the same folder and paste this batch code into it:

Код:
@echo off
setlocal disabledelayedexpansion
set "prev="
for /f "delims=" %%F in ('sort input.txt') do (
  set "curr=%%F"
  setlocal enabledelayedexpansion
  if "!prev!" neq "!curr!" echo !curr!
  endlocal
  set "prev=%%F"
) >> output.txt
Save it, then run it and it will output all unique lines into "output.txt".

This only works when the duplicate lines are exactly the same though.

Or use PowerShell:

Код:
type input.txt |Sort-Object -unique |Out-File output.txt
Reply
#3

Quote:
Originally Posted by [HLF]Southclaw
Посмотреть сообщение
Sublime Text also does this: Edit > Permute Lines > Unique

do not leave me
Reply
#4

Quote:
Originally Posted by NV1D3ATD
Посмотреть сообщение
-image-
do not leave me
That's notepad++, not sublime.

https://sampforum.blast.hk/showthread.php?tid=531379
Reply
#5

Quote:
Originally Posted by [HLF]Southclaw
Посмотреть сообщение
Sublime Text also does this: Edit > Permute Lines > Unique
Can you take a look On "SaMuRy" Topic? just posted yday.
Reply
#6

I realized my mistake, I'm an idiot thank you very much to everyone who helped me!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)