dragontechi 68 Report post Posted November 11, 2022 how can i make the map end in the center like pirates online do this is their code --Map Name labMapName = UI_CreateCompent( frmMinimap, LABELEX_TYPE, "labMapName", 100, 15, 15, 3 ) UI_SetCaption( labMapName, "Map Name" ) UI_SetTextColor( labMapName, COLOR_WHITE ) UI_SetLabelExFont( labMapName, FONT12B, FALSE, 4284846015 ) UI_SetLabelExAlign(labMapName, 1) this is my code --Load map name display labMapName = UI_CreateCompent( frmMinimap, LABELEX_TYPE, "labMapName", 100, 16, 25, 12 ) UI_SetCaption( labMapName, "Map Name" ) UI_SetTextColor( labMapName, COLOR_WHITE ) UI_SetLabelExFont( labMapName, FONT12B, FALSE, 4284846015 ) when entering UI_SetLabelExAlign(labMapName, 1) i get error CaLua Library : Error running script scripts/lua/forms/minimap.clu : scripts/lua/forms/minimap.clu:28: attempt to call global `UI_SetLabelExAlign' (a nil value) I'm using src but it doesn't seem to execute that line that I imagine is the central one the name of the map Quote Share this post Link to post Share on other sites
V3ct0r 2,116 Report post Posted December 3, 2022 Hello @dragontechi, On 11/11/2022 at 6:58 PM, dragontechi said: when entering UI_SetLabelExAlign(labMapName, 1) i get error CaLua Library : Error running script scripts/lua/forms/minimap.clu : scripts/lua/forms/minimap.clu:28: attempt to call global `UI_SetLabelExAlign' (a nil value) I'm using src but it doesn't seem to execute that line that I imagine is the central one the name of the map Looks like UI_SetLabelExAlign() is a custom function which is developed by Pirates Online team. You should develop your own function which will calculate position of the text depending on its length and window size. Quote Some useful links / Полезные ссылки Tips for making a topic in 'Questions & Help' / Рекомендации по созданию тем в разделе "Помощь" Server Advertising Section Rules / Правила раздела "Реклама серверов" Available e-mail domains for registration / Допустимые e-mail домены для регистрации User groups / Группы пользователей User ranks / Звания пользователей "Broken" pictures on the forum / "Битые" изображения на форуме Beware of scammers! / Осторожно, мошенники! My developments / Мои разработки Mods for client and server / Моды для клиента и сервера PKOdev.NET website for Tales of Pirates Server / PKOdev.NET веб-обвязка для сервера Пиратии I do not provide any help in private messages and outside the forum. Use 'Questions & Help' section please. Thank you for understanding! Я не оказываю какую-либо помощь в личных сообщениях и вне форума. Пожалуйста, используйте раздел "Пиратия: Помощь". Благодарю за понимание! Share this post Link to post Share on other sites