• Home
  • Index
  • Search
  • Download
  • Server Rules
  • House Roleplay Laws
  • Player Utilities
  • Player Help
  • Forum Utilities
  • Returning Player?
  • Toggle Sidebar
Interactive Nav-Map
Tutorials
New Wiki
ID reference
Restart reference
Players Online
Player Activity
Faction Activity
Player Base Status
Discord Help Channel
DarkStat
Server public configs
POB Administration
Missing Powerplant
Stuck in Connecticut
Account Banned
Lost Ship/Account
POB Restoration
Disconnected
Member List
Forum Stats
Show Team
View New Posts
View Today's Posts
Calendar
Help
Archive Mode




Hi there Guest,  
Existing user?   Sign in    Create account
Login
Username:
Password: Lost Password?
 
  Discovery Gaming Community Discovery Development Discovery Developers Forum Discovery Unofficial Development
« Previous 1 2 3 4 5 Next »
Freelancer multiple object mover

Server Time (24h)

Players Online

Active Events - Scoreboard

Latest activity

Pages (2): 1 2 Next »
Freelancer multiple object mover
Offline darkwind
08-07-2020, 01:24 PM, (This post was last modified: 08-07-2020, 01:30 PM by darkwind.)
#1
Frontier Sheriff
Posts: 1,170
Threads: 138
Joined: Oct 2019
Staff roles:
Coding Developer

made small program
[Image: Bke2dNE.png]
to help a friend

it is for a case when you have
[+]input data
[Object]
nickname = BW15_05
ids_name = 514512
pos = -16750, -200, 32153
archetype = space_port_dmg
ids_info = 514513
base = BW15_05_Base
dock_with = BW15_05_Base
reputation = fc_brigands_grp
behavior = NOTHING
voice = atc_leg_m01_ga
space_costume = li_rockford_head, gallia_male_brigands_body
difficulty_level = 17
loadout = space_port_dmg_ga_01
pilot = pilot_solar_easy
;

[Object]
nickname = BW15_05_1
pos = -16715, -125, 32153
rotate = 0, 0, 45
archetype = space_tankl4
parent = BW15_05
;

[Object]
nickname = BW15_05_2
pos = -16785, -125, 32153
rotate = 0, 0, -45
archetype = space_tankl4
parent = BW15_05
;

[Object]
nickname = BW15_05_3
pos = -16750, -344, 32153
archetype = dsy_mod_disc_s
parent = BW15_05
;

[Object]
nickname = BW15_05_4
pos = -16750, -420, 32153
rotate = 90, 0, 0
archetype = space_tanks4x4
parent = BW15_05
;

[Object]
nickname = BW15_05_5
pos = -16750, -420, 32153
rotate = 90, 90, 0
archetype = space_tanks4x4
parent = BW15_05
;

[Object]
nickname = BW15_05_6
pos = -16750, -420, 32153
rotate = 90, 45, 0
archetype = space_tanks4x4
parent = BW15_05
;

[Object]
nickname = BW15_05_7
pos = -16750, -420, 32153
rotate = 90, -45, 0
archetype = space_tanks4x4
parent = BW15_05
;

[Object]
nickname = BW15_05_8
pos = -16750, -500, 32153
archetype = dsy_mod_disc_s
parent = BW15_05
;
a.txt like that

and wishing to relocate everything to some other position together, and probably rotating it around some sort of center.
[+]example of result
[Object]
nickname = BW15_05
ids_name = 514512
pos = 6000, 0, 400
rotate = 0, 0, 0
archetype = space_port_dmg
ids_info = 514513
base = BW15_05_Base
dock_with = BW15_05_Base
reputation = fc_brigands_grp
behavior = NOTHING
voice = atc_leg_m01_ga
space_costume = li_rockford_head, gallia_male_brigands_body
difficulty_level = 17
loadout = space_port_dmg_ga_01
pilot = pilot_solar_easy
;

[Object]
nickname = BW15_05_1
pos = 6035, 75, 400
rotate = 0, 0, 45
archetype = space_tankl4
parent = BW15_05
;

[Object]
nickname = BW15_05_2
pos = 5965, 75, 400
rotate = 0, 0, -45
archetype = space_tankl4
parent = BW15_05
;

[Object]
nickname = BW15_05_3
pos = 6000, -144, 400
rotate = 0, 0, 0
archetype = dsy_mod_disc_s
parent = BW15_05
;

[Object]
nickname = BW15_05_4
pos = 6000, -220, 400
rotate = 90, 0, 0
archetype = space_tanks4x4
parent = BW15_05
;

[Object]
nickname = BW15_05_5
pos = 6000, -220, 400
rotate = 90, 90, 0
archetype = space_tanks4x4
parent = BW15_05
;

[Object]
nickname = BW15_05_6
pos = 6000, -220, 400
rotate = 90, 45, 0
archetype = space_tanks4x4
parent = BW15_05
;

[Object]
nickname = BW15_05_7
pos = 6000, -220, 400
rotate = 90, -45, 0
archetype = space_tanks4x4
parent = BW15_05
;

[Object]
nickname = BW15_05_8
pos = 6000, -300, 400
rotate = 0, 0, 0
archetype = dsy_mod_disc_s
parent = BW15_05
More detailed description:
It makes coordinates relative to some center
rotates around of it, if you write degrees for angles more than 0 in program
and then shifts the location of those objects to some position elsewhere
after that, it creates new file b.txt where the changed file is written
or you can rewrite the existing one.

download
github

P.S. so basically this program fastly changes "pos = ..." and "rotate = ...." strings in a file.
some people who change things in solar systems, perhaps need it to move multiple stuff around.

P.P.S. I didn't test it. so not exactly sure if it rotates properly. Yeah I tried to rotate but, not sure if it would correspond well with "rotate = " game parameter.


Interstellar Autogit Ctrl-V Encryptor Discovery At Linux
Dark Tools DarkBot DarkLint DarkStat DarkMap
Reply  
Offline Treewyrm
08-07-2020, 02:30 PM,
#2
Alchemist
Posts: 2,084
Threads: 61
Joined: Jul 2007

Erm... you can move and rotate multiple objects in FLMS.
[+]Spoiler
[Image: 0635f8d420eb97ffbd8fcae4c4d335de.gif]
Reply  
Offline Groshyr
08-07-2020, 02:39 PM,
#3
Member
Posts: 3,834
Threads: 381
Joined: Mar 2018

Indeed so but primary goal of Darkwind's soft is an accuracy without turning a single coordinate entity into a Pi number like FLMS do
Reply  
Offline Treewyrm
08-07-2020, 05:11 PM,
#4
Alchemist
Posts: 2,084
Threads: 61
Joined: Jul 2007

In FLMS options you can enable rounding to integer values if you want. Also rounding makes you lose accuracy, not gain in, as to what accuracy you need depends on situation.

In that code I don't see any matrix inversions and multiplications that would be necessary to rotate collection of objects around single pivot, looks like they're all just going to be in local space.
Reply  
Offline Kauket
08-07-2020, 05:26 PM,
#5
Dark Lord of the Birbs
Posts: 6,565
Threads: 507
Joined: Nov 2014
Staff roles:
Art Developer

(08-07-2020, 02:30 PM)Treewyrm Wrote: Erm... you can move and rotate multiple objects in FLMS.
[+]Spoiler
[Image: 0635f8d420eb97ffbd8fcae4c4d335de.gif]

Whaaaaat? How? Unless I'm using an outdated version. I've always asked Xalrok how we could move multiple objects since it didnt allow multi-selection.
Reply  
Offline darkwind
08-07-2020, 05:46 PM, (This post was last modified: 08-07-2020, 05:47 PM by darkwind.)
#6
Frontier Sheriff
Posts: 1,170
Threads: 138
Joined: Oct 2019
Staff roles:
Coding Developer

(08-07-2020, 05:11 PM)Treewyrm Wrote: In FLMS options you can enable rounding to integer values if you want. Also rounding makes you lose accuracy, not gain in, as to what accuracy you need depends on situation.

In that code I don't see any matrix inversions and multiplications that would be necessary to rotate collection of objects around single pivot, looks like they're all just going to be in local space.

Why would we be needing matrix inversion for object rotation?

rotation is just a matter of = Point * Matrix of rotation by X-axis * Matrix of rotation by Y-axis * Matrix of rotation by Z-axis. Matrix multiplication is enough for that ;b

I noticed though, that there is already in use some sort of better new method than it, but whatever. Although wait second, this new method exactly suggests using matrix inversions. Are you rotating through Quaternions?


Interstellar Autogit Ctrl-V Encryptor Discovery At Linux
Dark Tools DarkBot DarkLint DarkStat DarkMap
Reply  
Offline Laz
08-07-2020, 06:00 PM,
#7
(Sorta) Retired Code Monkey
Posts: 1,905
Threads: 106
Joined: Jan 2014

(08-07-2020, 05:26 PM)Kauket Wrote:
(08-07-2020, 02:30 PM)Treewyrm Wrote: Erm... you can move and rotate multiple objects in FLMS.
[+]Spoiler
[Image: 0635f8d420eb97ffbd8fcae4c4d335de.gif]

Whaaaaat? How? Unless I'm using an outdated version. I've always asked Xalrok how we could move multiple objects since it didnt allow multi-selection.

Laz update thing https://github.com/AftermathFreelancer/FLModStudio

Reply  
Offline darkwind
08-07-2020, 06:30 PM, (This post was last modified: 08-07-2020, 06:31 PM by darkwind.)
#8
Frontier Sheriff
Posts: 1,170
Threads: 138
Joined: Oct 2019
Staff roles:
Coding Developer

Reinventing the wheel.
[Image: 1*ZmLFM5MP17SLa8fgXmaFdQ.jpeg]
Reply  
Offline Skorak
08-07-2020, 07:30 PM,
#9
3x Custom User Title
Posts: 4,422
Threads: 503
Joined: Mar 2008

The new FLMS version crashes more often and has annoying 'features'. The rotating and moving is nice though so use both I guess.
Reply  
Offline Laz
08-07-2020, 07:39 PM,
#10
(Sorta) Retired Code Monkey
Posts: 1,905
Threads: 106
Joined: Jan 2014

then tell me about them

things aren't gonna get fix if I don't know about them

Reply  
Pages (2): 1 2 Next »


  • View a Printable Version
  • Subscribe to this thread


Users browsing this thread:
1 Guest(s)



Powered By MyBB, © 2002-2026 MyBB Group. Theme © 2014 iAndrew & DiscoveryGC
  • Contact Us
  •  Lite mode
Linear Mode
Threaded Mode