HiveCraft - Hub Map
pimpยท@strangedadยท
1.212 HBDHiveCraft - Hub Map
<center>https://images.ecency.com/DQme1WGnp61nZwaDbnSLxGk5oqz1PfWMmzqAz5S55XpSoYS/image.png</center>
The server is running. If you're having any bugs or things aren't working correctly, comment here.
I am working on trying to code in a centralized hub that has all the things that we're working on as well.
I may add in other games and such that are Hive-associated. I might add Splinterlands... we'll see.
main.lua
```lua
-- HubWorld main.lua
local g_Config =
{
WorldName = "world",
Radius = 256,
WarningCooldownSeconds = 3,
CenterX = nil,
CenterY = nil,
CenterZ = nil,
}
local g_LastWarn = {}
local function LoadConfig()
local ini = cIniFile()
local cfgPath = "Plugins/HubWorld/HubWorld.ini"
if (ini:ReadFile(cfgPath)) then
g_Config.WorldName = ini:GetValue("HubWorld", "WorldName", g_Config.WorldName)
g_Config.Radius = ini:GetValueI("HubWorld", "Radius", g_Config.Radius)
g_Config.WarningCooldownSeconds = ini:GetValueI("HubWorld", "WarningCooldownSeconds", g_Config.WarningCooldownSeconds)
local cx = ini:GetValueI("HubWorld", "CenterX", 0)
local cy = ini:GetValueI("HubWorld", "CenterY", 0)
local cz = ini:GetValueI("HubWorld", "CenterZ", 0)
if (cx ~= 0 or cy ~= 0 or cz ~= 0) then
g_Config.CenterX = cx
g_Config.CenterY = cy
g_Config.CenterZ = cz
end
return
end
ini:SetValue("HubWorld", "WorldName", g_Config.WorldName)
ini:SetValueI("HubWorld", "Radius", g_Config.Radius)
ini:SetValueI("HubWorld", "WarningCooldownSeconds", g_Config.WarningCooldownSeconds)
ini:WriteFile(cfgPath)
end
local function GetCenter(a_World)
if (g_Config.CenterX ~= nil) then
return g_Config.CenterX, g_Config.CenterY, g_Config.CenterZ
end
return a_World:GetSpawnX(), a_World:GetSpawnY(), a_World:GetSpawnZ()
end
local function SaveCenter(a_World, a_X, a_Y, a_Z)
g_Config.CenterX = math.floor(a_X + 0.5)
g_Config.CenterY = math.floor(a_Y + 0.5)
g_Config.CenterZ = math.floor(a_Z + 0.5)
local ini = cIniFile()
local cfgPath = "Plugins/HubWorld/HubWorld.ini"
if (ini:ReadFile(cfgPath)) then
ini:SetValueI("HubWorld", "CenterX", g_Config.CenterX)
ini:SetValueI("HubWorld", "CenterY", g_Config.CenterY)
ini:SetValueI("HubWorld", "CenterZ", g_Config.CenterZ)
ini:WriteFile(cfgPath)
end
end
local function IsOutside(a_World, a_Pos)
local cx, cy, cz = GetCenter(a_World)
local dx = a_Pos.x - cx
local dz = a_Pos.z - cz
return ((dx * dx + dz * dz) > (g_Config.Radius * g_Config.Radius))
end
local function BouncePlayer(a_Player)
local world = a_Player:GetWorld()
local cx, cy, cz = GetCenter(world)
a_Player:TeleportToCoords(cx, cy, cz)
end
function HandleHubSetCenter(a_Split, a_Player)
local pos = a_Player:GetPosition()
SaveCenter(a_Player:GetWorld(), pos.x, pos.y, pos.z)
a_Player:SendMessageSuccess("Hub center updated.")
return true
end
function HandleHubStatus(a_Split, a_Player)
local world = a_Player:GetWorld()
local cx, cy, cz = GetCenter(world)
a_Player:SendMessageInfo("HubWorld: center=" .. cx .. "," .. cy .. "," .. cz .. " radius=" .. g_Config.Radius)
return true
end
function OnPlayerMoving(a_Player)
local world = a_Player:GetWorld()
if (world:GetName() ~= g_Config.WorldName) then
return false
end
local pos = a_Player:GetPosition()
if (not IsOutside(world, pos)) then
return false
end
local uid = a_Player:GetUniqueID()
local now = os.time()
local last = g_LastWarn[uid] or 0
if ((now - last) >= g_Config.WarningCooldownSeconds) then
a_Player:SendMessageFailure("You reached the hub boundary.")
g_LastWarn[uid] = now
end
BouncePlayer(a_Player)
return true
end
function Initialize(Plugin)
Plugin:SetName("HubWorld")
Plugin:SetVersion(1)
LoadConfig()
cPluginManager:Get():AddHook(cPluginManager.HOOK_PLAYER_MOVING, OnPlayerMoving)
LOG("HubWorld loaded")
return true
end
```
---
### ๐ช PeakeCoin Ecosystem
**๐ฑ PeakeCoin USDT Bridge (Hive โ Polygon/MATIC)**
Bridge **SWAP.USDT** from **Hive Engine** to **USDT on Polygon (MATIC)**.
Whitelist access, documentation, and bridge status updates:
๐ https://geocities.ws/peakecoin
---
**โ๏ธ HiveP.I.M.P. โ PeakeCoin Intelligent Market Protector**
Operated by **@hivepimp**, P.I.M.P. focuses on stabilizing **PEK markets** and strengthening liquidity on Hive Engine.
Community participation supports long-term ecosystem health.
---
**๐ค PeakeBot โ Autonomous Trading System**
Independent multi-token trading bot with RC-awareness, adaptive delay logic, and smart cycle control.
๐ Trading bot documentation:
๐ https://geocities.ws/p/e/peakecoin/trading-bot/peakebot_v0_01.html
๐ป Open-source repositories:
๐ https://github.com/paulmoon410
---
**๐ฐ PeakeSino โ The PeakeCoin Casino (Beta)**
Blockchain-powered games using **PEK** as the native in-game currency.
Built on Hive with a focus on provable fairness and community-driven growth.
๐ Play the beta games here:
๐ https://geocities.ws/peakecoin/pek_casino/beta_games/index.html
---
### ๐ Acknowledgements
Thanks to and please follow:
**@enginewitty @ecoinstant @neoxian @txracer @thecrazygm @holdonia @aggroed**
For their continued support, guidance, and help expanding the **PeakeCoin ecosystem**.
---๐ peakecoin.bnb, shturm, toastfox, ecoinstant, onewolfe, cryptoknight12, jozefkrichards, kernelillo, dpend.active, sketching, mxm0unite, txracer, magic.cent, paulmoon410, peakecoin, seckorama, good-karma, esteemapp, esteem.app, ecency, ecency.stats, sunisa, imno, marabuzal, bloghound, drwom, sayee, auleo, ahmadmangazap, irisworld, cherryng, blumela, cryptosimplify, allentaylor, cindynancy, bipolar95, rivereyesmusic, digi-me, eolianpariah2, alessandrawhite, street-ar, archon-gov, kristabel123, letusbuyhive, cumanauta, saboin.ccc, enginewitty, thealliance, rumplestiltskin, steemitcomics, anomallies, psyborg, antdroid, hazem91, katrina-ariel, lunamoon, khaldeesi, freyamber, allied-mafia, steemforschool, steemforschools, angeltree, christmasclub, birthdaywishes, wittys.angels, wittysangels, angiel, sassafrass, bellelynn, b34w0lf, karina.yana, monchhichi23, arc7icwolf, elizacheng, helena-m, hardikv, avesa, tyedyefirepower, platosgroove, thealliancebank, bobthebuilder2, thekrazypoet, dadview, underground, dabeckster, gohba.handcrafts, vm2904, jayna, felt.buzz, michaeldavid, moeknows, burkulese, vikar, bobthebuilder, splash-of-angs63, brisby, astrea, themothership, emjoe, bengy, cygon, khimgoh, cryptictruth, musicapoetica, joseantpp, break-out-trader, veteranforcrypto, raokoz, tinyhousecryptos, alliedbanking, hive-123585, alliedfun, lespecial17, captaincryptic, ismaelrd04, dhedge, chrono88, jaydr, dirego1, cantfoldaces, brucegryllis, femcy-willcy, marynn, iwannabeme, tawthar, whitneyalexx, nkatadelgormo, franco10, pollenation, honeyjean24, killerwhale, x40l1n, newigennity, currentseas, w1tty, nism, thetradecenter, mamadini, joeyarnoldvn, adsactly, syndicates, a11y, tygertyger, alliedforces, thesummoner, r-e-d, lord-of-the-d, steemforsteem, toonuts, twonuts, letlove, itwasme, theblooded, blooded, theclan, fambalam, youdo, bi0digital, tokencav, theblockpartyii, toekins, pollination, sircork, elviguitarra, riblaeditores, daveza, senalove, silvergoldbotty, chain.games, publicview, centsable, ambiguity, dr460n3y3, vetfunding, bigtakosensei, edthecanadian, voxmortis, thgaming, freedomring, coolbuddy, dynamicrypto, bigtom13, philippekiene, mumma-monza, menzo, iamleicester, beffeater, wahlterwhite, bulliontools, iviaxpow3r, draygyn, psyberx, hivedrip, mr-wallstreet, rosmiapure, ragk88, mighty-thor, splinterwhale, aslamrer, psx-bank, slothlydoesit, fiftysixnorth, dgi, psyber-x, psyberfish, psybercurator, psyberwhale, dreemsteem, inthenow, sku77-poprocks, jim-crypto, mochilub, merit.ahama, hopestylist, saffisara, wildo, slothburn, princessmewmew, thistle-rock, shadowspub, crescendoofpeace, haveyaheard, deadgrlsuppastar, simgirl, afifa, jzerpa, byn, christianyocte, tommyl33, c0ff33a, nolasco, snowpea, ilhuna, blue.panda, whiterosecoffee, oswvin, the.lazy.panda, teamuksupport, cryptosneeze, tommys.shop, bluefinstudios, leighscotford,