Question on forceMapRecenter in Special Message

All discussions & material related to Command's Lua interface

Moderators: angster, RoryAndersonCDT, michaelm75au, MOD_Command

Post Reply
Parel803
Posts: 932
Joined: Thu Oct 10, 2019 3:39 pm
Location: Netherlands

Question on forceMapRecenter in Special Message

Post by Parel803 »

Good afternoon,

Just a question out of curiosity
On this LUA page: https://commandlua.github.io/assets/Fun ... ssage.html
You have the line: forceMapRecenter [optional] True/False The map will be centered on location if present.

Probably due to languange knowledge on my end but should this move your screen to location without executing the button "jump to location"?

I made this: local msg = ScenEdit_SpecialMessage('playerside', 'Here\'s a message!', {latitude = 'N41.00.00', longitude = 'E005.30.00', forceMapRecenter=true})
In this case I have no difference as without using: forceMapRecenter
What am I doing wrong or do I misunderstood.

regards GJ
User avatar
blu3s
Posts: 1008
Joined: Fri Jul 08, 2022 9:45 am

Re: Question on forceMapRecenter in Special Message

Post by blu3s »

Hi GJ,

the correct lua is:

Code: Select all

ScenEdit_SpecialMessage( 'playerside', 'Here\'s a message!', { latitude = 1.2, longitude = 3.4 }, true )
Note that forceMapRecenter is another variable outside of the latitude/longitude settings.
Parel803
Posts: 932
Joined: Thu Oct 10, 2019 3:39 pm
Location: Netherlands

Re: Question on forceMapRecenter in Special Message

Post by Parel803 »

Goodevening,
Thank you for your time and answer, much appriciated.
regards GJ
Post Reply

Return to “Lua Legion”