I would like to be able to edit sections of text in the following way.
I might have a section as seen below.
Example.
Instance=wall
{
VisGroups=(32)
MeshFile=wall.gmt CollTarget=False HATTarget=False
}
I need to find the section I want based on the 'Instance' name in this case 'wall' and then change the script in line 4
I would like to change CollTarget and HatTarget to True,
A simple case of cut/paste if it's only once or twice, but it can be up to 500 times and the sections will be scattered throughout the text, some areas will have the same script ie CollTarget=False HATTarget=False which doesn't need editing. The file can be as long as 5000 lines similar to the EXAMPLE below
Instance=object350
{
MeshFile=object350.gmt CollTarget=False HATTarget=False
}
Instance=box056
{
VisGroups=(32)
MeshFile=box056.gmt CollTarget=False HATTarget=False
}
Instance=wall01
{
VisGroups=(32)
MeshFile=wall.gmt CollTarget=True HATTarget=False
}
Instance=track01
{
MeshFile=track01.gmt CollTarget=True HATTarget=True
}
NOTE also that the lines aren't all the same amount between the parentheses
but on the following section I may not want to do this.
Instance=20road007
{
VisGroups=(32)
MeshFile=20road007.gmt CollTarget=False HATTarget=True Response=VEHICLE,TERRAIN
}
such as Add/Paste an extra piece of script or even Delete a piece of script completely
Is this possible using a macro? Could I do something in Notepad++ ..... it has lots of commands? Do I need to write a 'BASIC' programme. I don't understand macro's and my programming is limited.
How would I do this? It would be such a time saver. I hope I have made myself clear.
Any help would be greatly appreciated. Thank You