I'm working on save editor program, but i've came into huge problem:
Here's structure in these textfile:
But, so that wouldnt be so simple, it can also be like:
Here's what the program should do:
- look for selected country (I'll use SOV as example)
So - look for core="SOV"
- then delete everything between
core="SOV" and points=0
- Add there
infra={
10.000 10.000 }
industry={
10.000 10.000 }
I really have NO idea how to make it. Thanks in advance.
Here's structure in these textfile:
Code:
owner="SOV"
controller="SOV"
core="SOV"
infra={
10.000 10.000 }
industry={
10.000 10.000 }
points=0
weather={
humidity=7.584
pressure=1015.000
temperature=11.050
precipitation=0.012
cloud_coverage=0.006
}
}
Code:
owner="USA"
controller="USA"
core="USA"
naval_base={
1.000 1.000 }
infra={
8.000 8.000 }
points=0
weather={
pressure=1015.000
temperature=21.700
precipitation=0.012
cloud_coverage=0.006
}
}
- look for selected country (I'll use SOV as example)
So - look for core="SOV"
- then delete everything between
core="SOV" and points=0
- Add there
infra={
10.000 10.000 }
industry={
10.000 10.000 }
I really have NO idea how to make it. Thanks in advance.