#General modding chat
1 messages · Page 8 of 1
It’s also been done before
I'd think that even something like 101% wouldnt be as glitchy as it is but that explanation sounds correct
How can you rotate custom objects?
Same as with a prefab - using the SetRotation function
Does setphysicsspeed scale the internal tickrate (engine still running at normal tickrate) or the actual engine tickrate at its core
Ill need a proper answer from someone who knows
Cuz if it scales the physspeed with everything else like mod refresh rates it might be impossible to make a module im considering
im pretty sure physics speed is different from mod tickrate although i havent done a lot of testing
so if you set physspeed to 50% mod timing wont be affected
it changes the time step size of the physics simulation. The game will still attempt to update the physics at 60fps, but those 60 frames might be longer/shorter than 1 in game second
it's only different if you set your mod to anything below 60fps
oops, but does it really matter if i catch these errors because it isnt fatal and it would take extra code (L optimization) to catch them for something that needs to run as quick as possible
funny when it throws that error the scraps are actually cleaned up
i dont think its supposed to be called that many times but there arent any errors so i'll take i t!
oh wait its because of how i setup the skips
How does your mod detect when the server is lagging?
runs at 60hz and compares some stuff with gettime or getunitytime I forget exactly
but it times at what would be the frame time of 60 fps
so if the server dips below that, that means it's lagging
but if it outright freezes then it doesn't detect
so its only good for comparatively small lag like repairing a big structure, spawning structures in build mode, respawning with a medium-large vehicle
and in those cases where it can detect, I can detect how far behind it is in milliseconds and do different stuff based on that
Does it detect when the server runs constantly at for example 50% speed?
for example if it lags at all, set the physics speed down depending on how much lag. if the frametime is more than 7ms higher than it should be, then delete all "scrap" structures and pause physics until lag stops
Nice
no because it uses gettime or getunitytime which are not affected by physics speed. however, if super intense lag happens then that time stops ticking. although I could maybe store previous frame times and compare that when the frametime jumps back to where it should be
the issue with more complicated stuff like cleaning scrap is that the server still has to run that while it's lagging and most of the time, lag is a spike (e.g. calculating a collision) and not a constant thing
so it hardly affects things
but I think it might help for unstable servers where a lag spike could spiral into a bigger issue and eventually crash, ESPECIALLY on high player servers
because it so quickly responds to even small stutters
That's nice
I should probably update sensitive seats to run at 60hz because currently I think it runs at 10hz
and I still need to fix getting locked out of repairing in no repair tokens
Spamming errors also lags the game
how much lag does it cause? its less than 10 errors (usually 1-3) per lag spike which isn't all the time
Probably more than an if/pcall, I/O is slow
ah so not that bad but for a heavily optimized mod I might not want them. how performance heavy is it to leave in tm.os.log lines?
Depends on how much data you try to log/how often
here's an example of what I'm logging. maybe an extra couple lines for some other performance or instability warnings- idk
That's probably fine
I might make a server benchmark thing with my new found ability to track performance. that could be interesting
like you say how many players you're going to host for and it runs for 30 minutes or something as soon as that player count is reached and then based on how many stutters and severity determines how good your server hosting is
although that assumes the server doesn't crash
And that human behavior will be consistent and reproducible
I've updated Track Creator Plus with new features and fixes. More Info:
#1242291936715608205 message
i still havent found what causes that error but now the logs are funnier
seems like it only triggers that error when the structure has a seat/anchorpin in it
so it might be the goto im using
yup! its that goto... but whyy
oh maybe when it gotos then it gets block again incorrectly
the errors magically went away after trying one of my old solutions a second time so i guess its fixed now
Are you using vscode in dark mode? It feels weird seeing it since i use light mode
Vs code is by default on dark mode
I know, i just like it on light mode so i don't fall asleep
Is your discord also in light mode?
Nope, it's on dark mode
Discord is just better in dark mode
The colors of names on white mode are really hard to read
are colors in a float? or in some other weird ass number format?
rgb
(r, g, b) iirc or something similar
no i mean the color R, color G and color B. how are they rounded, how many digits do they support, etc
well if it's rgb it's probably integer 0-255
in the new version it gets rounded 0-1, but in the old one it didnt have such limits. rn im testing sth, but it isnt going well
what new version?
huh? thats... not what i found. do floats lose bits that are used for digits if the exponent gets too big or too small?
no, but floats are stored in scientific notation with limited precision for the mantissa
Anyone remembers what version of lua TM is running?
Im pretty sure its lua 5.2
That could be an issue... I'll have to check tomorrow
5.2
Damnit
String.pack and unpack, which as I gather are an extremely easy way to convert floats to bits are 5.3+
Cause supposedly moving the sign bit and the first one of the exponent at the end of the mantissa should be a working, simple option
That would cap the exponent at -1 making the largest possible number ~1 (with a mantissa of all one, basically 0.9...) and the smallest 0, exactly what we need
And losing 2 out of 23 mantissa bits is far from the worst
you would need to move the first 3 bits (otherwise the largest number would be 1.99999...)
Why? 1.1111 is close to 2 yes, but to the power of 2^-1 makes it 1
01111111 in the mantissa should be -1 if I remember floats correctly
because the mantissa for normalized numbers has an implicit 1. for extra precision (in scientific notation the mantissa always starts with a non-0 digit, but in binary that means the only possible value is 1 and thus there is no need to store it)
I know that much... The thing that's not matching up is the exponent
Why is 0111... 2^0 and not 2^-1
the exponent is represented in biased form with a -127 constant, so 2^127 is actually 2^0 = 1
Agh, why
I thought it was using excess notation, what's this
Excess 128, the offset is 128....
because that means half the exponents are positive and half are negative (0 exponent is reserved for subnormal numbers, and 255 exponent is for infinity/nan)
I guess I'll sub one from the exponent, that's still better than losing another bit
Assuming I get to decompose the float into bits
is the coloring function still broken?
Pretty sure it still clamps to 1
ye i dont mean that, i mean sometimes the coloring gets screwed up big time
Idk
for setprimarycolor yes
well, then something is very wrong in my coloring function....crap
ah, found the issue. apparently, NaN cannot be used as a valid color value
ah yes, changing a secondary color of course makes the primary color green and gives me a red glow around the block....... what?
(im on an old version, i assume this is the "black hole" thingy that was fixed)
cool glitch not gonna lie
ye, if not for the fact its supposed to just save the color normally 😭
is there a way to disconnect players without banning them? or is that what the kick function already does?
That’s what kick does (I think)
We are missing a ban by steamid and steamid get functions
ooh i havent even though about steam integration things
i feel like a dynamic and automatically adjusting complexity limit would be both an amazing and terrible idea at the same time
is it possible to detect whether an individual block/structure is in build mode?
Get the structure(s) currently in build mode for a player
Parameters:
- playerId: PlayerID (See
PlayerIDtype alias)
Returns: table: ModStructure
Code:
function tm.players.GetPlayerStructuresInBuild(playerId) end
yes but for my mod i am checking all of each player's structures for whether theyre scrap, how would i use this to detect structures that aren't in build mode?
ideally because this is a performance/stability mod, i need this to run insanely quick
oh i wonder if gravity applies to build mode structures, cause maybe i can check velocity and if its perfectly 0 then dont remove
When someone enters build mode with a structure save the current structure data, then check it against all the players structures, the ones that don’t match the buildmode structures data get removed
When someone enters build mode with a structure save the current structure data
what about unconnected blocks in build mode?
Aren’t all blocks in buildmode considered one structure?
let me lay out what i'm trying to do and what the current issue is, i think thats unclear right now
i am trying to clean up structures that:
- aren't in build mode
- do not have a seat or anchor pin on board
the issue is that because unconnected blocks are treated as a separate structure and often don't have a seat/anchor, they get cleared, and make building in laggy conditions nearly impossible
The get all structures in build mode apparently gets more than 1
So it should be in theory just a simple comparison?
this might work but i fear it could be rather performance intensive (relatively) so i'll try to get my speed check idea to work before trying this
If the velocity works then that might faster
hey wait it might actually be working lol
Actually velocity won’t work because it requires player seated
GetSpeed() doesn't work without a seated player? but why would it be under modstructure then
oh wtf
devs why
I guess you could maybe cheese it by comparing rotation of the structure compared to the world, structures not in build mode are likely not to be exactly aligned with the axis like build mode
That's what we all wonder... Time for you to derive that
Btw, are you worried about all unconnected blocks or only the ones in build mode
Cause you could just... Not delete scrap when in build mode, do it once when they enter, then they as long as they stay in they won't make any more
only unconnected blocks in build mode. the point of what im doing is to clean up pieces of scrap/wreckage on the ground
this is supposed to run once when the server is detected lagging, although preventative measures may be good
I see
also i see complexity is not updated when blocks are disposed/destroyed in build mode
devs!!!
oh i wonder if forces (center of mass, thrust, that stuff) are updated
Thinking about it this has a couple flaws, mainly if you bring a build without a seat in build mode it will still get deleted
i might add 1x1 eyeballs to the list of "protected" blocks so that it has compatibility with custom missles mod
So rotation as terror suggested is probably for the best, X and y should never have decimal points in build mode
That is, assuming the missile mod works
GetRotation() is fine right? local space though
this should work right?
ofc use actual thing if [0] is wrong
which it probably is tbh
ye figured it out, it should be rotation.y right..?
ayo
now i spawn some scrap out in the world
Ah, right, forgot about that
Use .Forward
just .forward? nothing else?
As in ModBlock.Forward()
Should be
Since get rotation is local will always return multiples of 90
Unless that was only blocks... Agh, I haven't modded in a while
Module of 1, should be
So if n%1==0 should detect if the build is in build mode
Assuming ModStructure.GetRotation() works properly
it doesnt like me using goto but im gonna try it again anyway because 🖕
🖕
actually i dont need to but it would be more performant if that could be used
it worked !!!
Great
im not sure whats going on with the modvector log values but it did what i wanted it to do so 👍
it is exactly intended
You never know how it is with mods anymore ¬_¬
nah actually i looked at it again, you said ==0 means its in build mode; its working as intended lol
the one with the ~=0 is the scraps on the ground
do you remember what the pfb name for the 1x1 eyeball is?
Not a clue
Ridicolas' block editor of just the missile mod (set to use another block then select an eye) should tell you
holy shit my block edit mod is RAGING
ah its because its doing loads of calculations on every structure and theres like 40 of them because of the plane
gotos are almost never a good idea
hmm i just thought of a better way to calculate frametime
just count the time passed between updates rather than if +1 to a variable happened in a given timeframe
what were you doing when this is a thing?
something very dumb tbh, but it did work well enough
LETS GO
I SOLVED LAG
Infinity server fps 🔥🔥🔥
Nice work 🙂
as it turns out, this doesnt detect when the server itself lags... so my janky method was actually better!
peak
i think the physspeed formula broke
im not sure how accurate these numbers are but i will try it in multiplayer
player joining seems to break this new measurement system
at one point it was like 62ms behind?
By itself it doesn't, you need to compare it against the target delta time and determine if there is a significant difference
@dusty pelican, @serene magnet has a boost thing going on
i have been informed you guys are collabing
yeah that's the idea
how do you make an invincible block mod
i don't think it's possible because of the health functions being broken
wdym?
ModBlock.SetHealth(hp) isn't consistant, it sometimes works but most of the time it doesn't
also ModBlock.GetStartHealth() does not give you the right health of a block
weird
@near parcel if i have a float like this 0 0....0 0....010 does it get converted to 0 or is there a chance it still works?
so exponent all 0, but not the mantissa (i am guessing i probably shouldn't do that, not to have some unexpected behaviour)
is there a list of block ids?
if not do you know the id of the ski
PFB_WaterSki
im trying to set the bouyancy but it isnt working
it might be PFB_WaterSki(server) or you need to be in build mode
what does that mean to be in build mode
have the ski in build mode
i did
that corresponds with a subnormal number. It works, but doesn't have as much precision as normal numbers
need to be in build mode but it seemed to work for me when we tried it out on my wheel buoyancy mod
it ended up getting treated as 0, but so is this, so idk anymore
ok, this should have absolutely not been converted to 0
post your code
just by looking at the code you should lsee that n2_5 is just n2 after being put into and taken out of a block
wait, no, little mess up
so they supposedly should be the same, same could be said for n3 and n4 which are just the two from before, but decompressed
yet they are not
(if using the mod go in build mode, select a block and put whatever value you want in the field, the top one is said value encoded and decoded, the bottom one is after getting put as block color)
any exponent of 01101100 or less of value seems to round everything down to 0
Huh?
I've been summoned
line 23 shouldn't be +127 instead of +126? If the numeric value has an exponent of 0, you should encode 127
horma wanted to do mariokart thing and i was like "oh antimatters doing stuff" and then i was informed that you are working with horma
oopsie
this is the print float fields of 2, which seems correct to me
whats all this floating point madness for? i lost track of that
a couple mods used the block color to store data
before you could put any number and it worked, it stored a whole float, now it's clamped between 0 and 1
so we are working on a way to slightly compress a float so it fits in the 0-1 range
Indeed
is there a difference in accuracy/performance between tracking tm.os.GetRealtimeSinceStartup() between updates, and deltatimes?
no, only difference is that getdeltatime gives you the time between update calls (doesn't change within a single update call) while the other gives you the time since startup (updates within a single update call)
and what is the effect of this?
oh i see, it shouldn't matter too much because i am only ever comparing time once and at the very start of the update
ok, so... after more testing i can say... we are kinda scewed
the exponent has to stay between 01101100 and 01111111, extremes excluded
wich makes the range really shallow
time to lose more of the mantissa....
like, another 2 bits
also, for some reason the last few mantissa bits start to get unstable near the 01111111 range... so i am a bit worried
ah well the major collision had a big number so ill say that realtime method is good enough
im pretty sure unity pauses the stopwatch when lag occurs though because it should report maybe 1000ms if so
Where can we start a petition or sth to get the colors back (or better yet a big update to the mod api)?
(or better yet a big update to the mod api)?
we all know this aint happening (frans and jonas step up 🙏🙏)
we should sneak in their office at night and do it ourselves
well no because thats flashbulb's excuse to not fix everything
technically set color works (half the time)
Alright, then:
- i take that back
- feels like half the api isnt working 😭
2.1) it feels like that because its true
it's not half the time
it's on every block that doesn't have special features
so you canlculate exactly how often it works
ffs im having a hard time making singleplayer lag enough to trigger lag responses
change color of wing? fine, it has a flap!? not fine
(it needs to be >7ms but not pause unity's tracking of time, to trigger structure cleanup)
worse yet, its the important part. who cares if i can or cant do vector operations, as long as i can read x,y,z and create a vector, ill be fine by rewriting it myself. but you cant rewrite setHealth() or SetColor() and shit
not with that attitude
anyhow, thingy work now... at least it works about as well as i'd expect it to
nowhere, the colors were clamped for a good reason
lost 5 mantissa bits :(
ok, so where can i start a petition to get a replacement for that? or anything else connected with the API that would actually help in mod creation? (also i think it could have been done better, or at least in a way which wouldnt break everything connected with saving data to blocks via colors)
#1123915629653667943
^
i mean, if this sacrifice brings the devs to implement a proper data storage option i'd say it's worthed
also i think it could have been done better, or at least in a way which wouldnt break everything connected with saving data to blocks via colors
no it couldn't. Saving data in blocks has always been a hack relying on undefined behavior that could cause a ton of issues. Fixing those issues means preventing the undefined behavior
they didn't expect us to use color for that in the first place
oh ye, definitely, question is whether we will get that
a man can hope
just clamping it from -1 to 1 instead of 0 to 1 would have saved a TON of hassle. sure, you still get clamped a lot, but you do not get enormous problems simply because you want to save a float that is potentially negative
this is working amazingly omg
negative values are still undefined behavior. The only thing that makes sense is either integers 0 to 255 (most common method) or floats between 0 and 1 that get mapped to integers 0 to 255
the problem described in the patchnotes, which therefore i assume is the addressed problem/concern, was about invalid color values looking crazy, so unless valuse of -1 to 0 looked crazy, i dont see why they couldnt have been kept in
GENERAL - Fixed externally modified Blueprints containing invalid colour values looking crazy when spawned in.
anything outside of [0, 1] is an invalid color
honestly i do believe most invalid colors probably didn't cause that, but without having one of such cursed blocks and doing some testing in 2.0 it can't be said, this was the fastest solution without doing that
yes, and? again, i wanna point out that the problem is "invalid colour values looking crazy when spawned in", so i dont see why they couldnt have been kept in unless they were the ones looking crazy
made the suggestion
invalid colors lead to undefined behavior. If your program has undefined behavior, that's a bug you should fix, because it will eventually become a problem. Fixing all invalid colors was the only way of guaranteeing the issue was fixed.
if the idea was to fix invalid colors, it should have said so, and it shouldnt have mentioned the look of those
fixing all invalid colors was the only way to fix the crazy colors without a very expensive investigation
very expensive investigation
the investigation in question: check the blueprints with weird colors, see what those used, limit around that.
i feel that i should say, that i get trying to just fix bugs like that (at least somewhat, since i also find a lot of bugs cool), but since a big part of the modding api is not working properly, then any action that takes away the ability of modders to do stuff feels like an attempted assasination of modding as a whole.
and this [#1196793172429394050 message] just seems... like an awful way to go. sure, getting more assets is very much welcome, but i dont think thats what the focus should be on. idk, it just gives me a very bad impression, i dont know how else to put it
the investigation in question: check the blueprints with weird colors, see what those used, limit around that.
then it becomes a game of whack-a-mole as new problematic values are discovered. If you want to avoid that, you either need to fix all undefined behavior or go in a rabbit hole to figure out what exactly causes the issue, probably deep within unity's render pipeline, and that's very expensive
but since a big part of the modding api is not working properly, then any action that takes away the ability of modders to do stuff feels like an attempted assasination of modding as a whole.
blame the people who want to ruin everyones fun for that
and this [moddingRequests for spawnables objects] just seems... like an awful way to go. sure, getting more assets is very much welcome, but i dont think thats what the focus should be on. idk, it just gives me a very bad impression, i dont know how else to put it
adding more assets is relatively cheap on development, as they are already made for the game
at first i sided with you regarding invalid colors, but i switch to alvaro's side because this, without doubt, is unintended behavior being leveraged, and it shouldn't really be expected that unintended behavior will be maintained
adding more assets is relatively cheap on development, as they are already made for the game
adding onto this, it is most likely easier to add and test new prefabs- which already use a well established system- than making a whole new system, testing edge cases and whatnot, fixing those, repeat, all while working on a big update of their own. modding is only available for pc-steam and the rest of the game is available for everyone, it's not going to have the same effort put into it
by unintended behavior that shouldnt be expected to be maintained do you mean the black hole coloring or storing values in colors?
i dont blame the devs for fixing the black hole weirdness
storing values in colors and using out-of-normal-bound limits in general
Modding api does seriously need looking into when devs get time. Hasn’t moved forward in probably a year and in some cases some functions are now broken that originally worked.
this aged like milk
do we have a modding bug reports thread? i kinda feel like any that do pop up just end up buried in #bug-reports or not even reported due to how little the API has been touched.
iirc we're supposed to put them in here but it kind of has the same problem as #bug-reports
I think we are supposed to put them in #1123915629653667943
I know reporting bugs in a vote-features category seems strange but I seem to recall the devs asking us to do that.
let's get a central gigantic list of every bug and very major missing thing for Flashbulb "Mr. Modder Developer" Frans
I made "Bug report" tag for both #1126842222898315274 and #1123915629653667943
thank you!!
#1123915629653667943 would be best place as it will be the main place we review when task planning.
what will the tag in #1126842222898315274 be used for then? non-urgent or unconfirmed bugs?
When you want to keep a bug and discuss it :p
EDIT: I'll delete the tag haha
should each individual bug be its own post, or should the backlog of bugs be in one mega post?
i'd say keep it on separate posts, a single thread might get cluttered by conversations and what would be the point of making the tag in the first place?
yes but I fear that would make too many posts because there are that many bugs I think
It is a good question and I don't have any good answers!
I think if they are collected nicely in a list it is a little more chewable for management to see the scope of needs.
Listed into "critical", "nice to have", etc. could make it also better as we could see what to prioritise.
Categorising them into "assets", "sounds", etc. it not really needed. Just how much people want it fixed.
oh, and
where do prefab object bugs go? these might be different than api bugs
ok maybe its time to actually gather up every issue in one spot
I think broken prefabs deserves its own list with pictures or similiar.
like how you made a pfb suggestions post?
I think we should have a thread in modding for making the list and also report them in modding suggestions individually
Yes 🙂
I think that concludes my question and concerns for today. I'll say this for all of us, thank you for giving the future of modding a sense of direction. good night!
heyy when was this added...
Modding is hard for us to measure success in. So it is scary to invest money into.
But yeah, for now it is words on my side... There is just very little time and the people who knows how to work with modding in Trailmakers just have very little time to do so.
This week I am onboarding a few new-ish employees to expand the knowledge a little.
Ages ago
that is very exciting! is it Johannes?
i don't know how often johannes checks the modding channel of all places xd
Listed into "critical", "nice to have", etc. could make it also better as we could see what to prioritise.
That is likely to be extremely subjective based on what each modder selfishly wants fixed right now 😂
Anyway - thanks, we'll do our best 🙂
what is the case for broken prefabs in ways like broken functionality? should special functionality glitches go in its own thread?
for examples,
PFB_Runner-Monkey's explosion immediately plays when the prefab is spawned (he still functions just fine afterwards though :D)- Explosive salvage are converted to regular salvage
PFB_BarrelandPFB_ExplosiveBarrelcannot be fully despawnedPFB_RingofFireparticle and light source positions aren't scaled correctly
made a thread for reporting bugged PFBs
https://discord.com/channels/296562030624899072/1369074385410982050
there is no way to remove an individual block from a structure in build mode. this means i cannot mod in a banned blocks system that runs within build mode. i am unhappy now.
@dusty pelican are you hearing this
why not just count the number and kick someone if they have the wrong amount
it's not clean but it would do the trick
are we perma banning people for using the wrong block without any warning...?
do you have any better ideas
being really angry and exploding them or killing them (killplayer function barely works lol) after 5s out of build mode
oh
Being able to remove blocks from build mode and outside it, would be a great feature
that and being able to control block bans and whether the host can control block bans/power core limit/player invinciblility
actually
block ban and block lock
block ban is like the host option
block lock hides it like in stranded
This would be great
hey also might as well add a whole UI engine and preset ui tools like unlock block pop-up like stranded or the campaign finish screens
custom minimap and checkpoints too why not
yk just give us everything ngl
new employees gotta lock tf in fr
what's the availability for modding updates and fixes in pvp part 2 looking like?
UI.getPixel and UI.setPixel when?
True! And I understand that; but in the end it is us who picks and what we can fit in at the given time... But it helps to know where the peoples vote are on.
Still just broken prefabs.
Personal vote on this one 😉
None at the moment. But talks are still ongoing.
I remember at some point prefabs were being pictured for something on the wiki. that was all manual right? should I make a mod to setup the prefabs, the camera, and a background automatically?
I believe in you, you can do it!
-# although I would prioritize making the stuff we have actually work... spawnables, while they are cool, aren't many of our priorities- and I'm saying that as a map maker
pitch to them that if we were given proper map making tools or assets (for example: surface properties/wheel-grip, cliff overhangs like stranded and rally, heightmap input ||(I heard that the game actually uses a heightmap texture and just generates a terrain for it (this would explain grid like cliffs on diagonals and why stranded uses an extra separate model on top of caves))||, world-space(?) tiling and blending ||(like high seas, airborne, space sector rock spawnables)||) that we very well could make maps that are on par or surpassing dev quality, and all that's needed from you guys is the tools to be made for us, and the maps roll in
free, (in theory) high quality content which could very well surpass flashbulb's own work
and the (PC steam) community is very happy with all the extra content they can play and (with a lower bar to entry) create. there is potential for a lot more content about tm- playing new maps, tutorials/guides for it
MapMakers2025 would be absolutely cracked with these tools
I'm definitely not biased as a map maker trust me bro
but seriously I have some ideas, like that offroad checkpoint campaign, which could actually be made possible at all with these tools. even just surface properties and better mesh/texture importing would go a long way
it seems like a decent system to have a texture for the terrain shape (idk about the surface properties though...) and then use Trailmappers for the prefabs
I suppose we would also need water and sea floor customization for that- but that is more fit for #1123915629653667943
I wonder how hard it is to make a trackmania nation forever track in trailmakers
It was my intention; but the annoying part was figuring out the bounds of the objects in order to zoom out properly.
We constantly change the terrain. It is very different between every level. You might be thinking about traditional Unity Terrain system which uses heightmap yes.
i was thinking I could make 3-5 size presets and switch between them in a UI window
We constantly change the terrain. It is very different between every level.
what does this mean for custom heightmaps?
is updating the terrain/heightmap in the context of a mod possible? if it is possible, then I'd guess that it's out of the scope for pvp pt2's modding time
Or just use a raycast to position the camera at a appropriate distance
it means we dont have 1 method that works with heightmap. I believe we using some custom solution for it at this point. I mean you can always implement a new heightmap solution but we prefer using whatever system we already have.
Right now there is nothing for PVP pt2 🙂
But I can say that I have added a few spawnables the other day to the.. thing.. coming after pvp part 2
and maybe some other things, nothing grand, maybe some fixes 🙂
It is just some of the prefabs are absolutely massive lol but yeah you could definintely do it.
Honestly as long as we have the power of making tris (technically not required) and changing material that would already be plenty to make custom height maps (tho vanilla terrain will still exist and you'll can't directly use TM textures).
I am considering making new terrain virtually identical if not better than editing the existing one, after all all the objects on normal maps will stay, so placing new terrain elsewhere is likely better.
That is assuming trailmapper adds a tool for it, which could allow to paint terrain with materials, create a whole texture with given material textures, ecc..
Terror soul already has a mod that generates a terrain from a heightmap i think
yeah as I said in my long rant thing
leak the modding changes please
it's not like it's going to spoil the main content of the update...
Needs the QA stamp before I dare 🙂
hey uh,
if we actually do end up wanting stuff to be fixed in the modding API, we do actually have to make some reports on stuff. I personally am not too well versed in lua or working with this API, probably enough to figure out what's wrong with certain things. so if we do actually want to expect something soon we should really start now.0
yes, been working on spawnable reports (i need to do some special functions reports as i excluded those initially) and sebi has been doing a couple function reports
at some point ill do a report for KillPlayer()
oh god did i just discover the cause of the KillPlayer() bug. if so i HATE that
i HATE that
NOO ITS ACTUALLY REAL
OH GOD
do tell
players are marked as invincible if theyre in an "enclosed" seat (gokart isn't enclosed, armored seat is)
which speaking of,
https://discord.com/channels/296562030624899072/1370539379260522516
ah I see
lemme test if this is consistent with my mods
@scenic echo i figured out why KillPlayer sometimes doesnt work and i hate it
So you'd have to destroy the seat first I guess
or maybe i teleport them into a mod-spawned open seat and then kill them
WHYYYY, it works and it is a solution, BUT WHY
i'm thinking of making a thread where we can put all the bug reports and then sort them by priority
maybe terror soul can do something like he did for the spawnables
that's called voting for mod features... or #1123915629653667943
highest votes is priority
I get that its the steepness of the terrain that determines whether there's grass or dirt/rock. But how come it's so different from Trailmappers to Trailmakers?
because trailmappers is pretty much just estimating what trailmakers does. same reason the sunlight color in trailmappers is different
also... #1226065444364877835?
No quick fix then. Oh well. Thanks for explaining. ^^
that cabin looks really nice btw
Thank you! I feel like I have to hold back on the details so it doesn't start chugging. I really have no idea where the limit would be. I assume plants and trees are the most taxing assets?
custom models and especially textures are very taxing in load times
besides that you really can go crazy
Oh, that's promising. I guess I'll just keep building, and then I can extra details at the end.
can you move spawned blueprints with the modding api?
Yes by add force, no by set position
Me adding 937MN of force to move a build by 5m in one tick:
"ModObject.Exists()" seems to always return true... either that or both "ModObject.Despawn()" and "tm.physics.DespawnObject(GameObject)" aren't doing a good enough job
i wonder if i can make a mod that forces the player out of build mode
to bandaid fix bugs which softlock you in build mode
for example this one
explode the seat, then KILL
no because this is in build mode
the issue is that build mode is active while the cinematic camera is
so i get locked in a hybrid in/out of build mode state
thus
exit build mode by force
i read out of seat instead of out of build mode
the second i stop playing it becomes super close istg
im actually op
rahh
the 6 player lobby is having a great time
i cant close server
im trapped here
save me
get me out
let me out
set me free
i know all the secrets you keep
i
i wont be
i wont be your casualty
you shall be in the prison, created by you, for eternity
damnit frans and johannes got tired of me begging for modding update so theyve trapped me as the host of the most stable (>5 hours without crashing) server hosting to ever exist
just enable the missile mod, i heard it can solve such issues
by crashing the game
🔥
yeah
i should try that
freedom
i should set physics speed to 1000%
boom
"oh guys i accidentally enabled a broken mod i was working on"
IM FREE
@sharp lantern SET ME FREE
"now restart"
THANK YOU BRO 🙏🙏🙏
time to work on force out of build mode mod
or you can make cool rocket
Making a large island with lots of dried up river beds to drive and crawl inn. Will be done in 3-5 business years.
this looks like wheel collision hell ngl. i would use simpler rock models but if you cant find any then it is what it is
It sort of is, yeah. It's still kinda fun, but you do slide and bounce around a bit. I'm gonna continue making this, but it honestly might just be shite. At least until they decide to update the game with better wheel physics.
would someone be so kind and do the "SPA" racetrack map? pretty please
This! Very important 🙂 We have some very old backlogs I am unsure if I can even recommend.
If we would have some fresh reports that would be AMAZING.
Staright to bug report :p
first I gotta remember the bugs I found... then I gotta not be lazy
ah not a bug but certainly quality of life. update block statistics like weight and aerodynamics live based on the blocks actual values
that and getdragall
gotta remember that for the afternoon
While Frans is here I'll mention, if you haven't marked it yet, setColorSecondary not working on any "special" block (any with inputs it seems), and colorPrimary possibly not working at all, but I'd need to do some testing before I can give a concrete reason
to #1123915629653667943/🦗 Bug Report you go fine sir
I feel like there's quite a few bugs that we reported for you guys many years ago that are not yet fixed - some are day 1 bugs. Surely they are actually logged effectively somewhere and would be somewhat prioritised over new fresh bug reports?
If you talking about "the" PDF, then that is still going around. Multiple of the reported items on that is either fixed, or cannot be reproduced - There is surely a few things in there that needs fixing as well.
Our own backlog is absolutely massive, and it is hard to prioritise for us other than "FIX EVERYTHING", hence why I am doing a call for help here 🙂
And if you can help us confirm that they still exist + great reproduction (Eg. mod included with steps to reproduce) then that's going to increase the chances of it getting fixed.
Modding QA is extremely hard as we solely depend on Programmers having extra time to test everything thoroughly + you guys. But in reality.. You are the ones who are using the to great degree, so you will have much better sense than we have time to at the moment.
Reporting the bugs in async chat is also hell. There is no way to find things again + I don't sit and stare at this thread all day and log every bug.
So that's why we are trying to get a little bit order and put things into individual threads. It will be much easier to point and link to individual bugs and discuss them.
Just did a pass to start this;
Has Thread
- AddUILabel (among other UI elements) with +82 characters (or something like that) crashes the session (Frans)
- PFB_BlockHunt (the blue beacon) spawns with a horrible constant synthetic sound which is unbearable once you spawn a number of them close together. It also spawns with a weird angled yellow ring which it never used to have.
- KillPlayer does not work after some time [Discord](#1370539379260522516 message)
- Spawning any explosives causes crashes with late join [Discord](#1368997534307057785 message)
- Custom cameras do not work when player's vehicle camera is set to orbit or sticky orbit [discord](#1371929672228798504 message)
- SetHealth is not reliant [Discord](#1368999049188872204 message)
Missing Thread / Reproducible steps
- PFB_Barrrel does not always despawn [discord](#1140936220487192587 message)
- SetIsTrigger removes hit box collisions but does not remove raycast collisions [discord](#1140936220487192587 message)
- Updating UI element for 10 minutes crashes the game [Discord](#1361406446612381757 message)
- Changing drag makes the game bug out [Discord](#1140936220487192587 message)
Very unclear details
- SetIsTrigger does nothing [discord](#1140936220487192587 message)
- Mesh Import discards vertices? LOD issues? [Discord](#1226065444364877835 message)
.
I can also let you know one of our project managers recently messaged me and asked for a prioritised list of modding wish list. Hence why I am pushing for your help lately 🙂
the KillPlayer function may be related to this
https://discord.com/channels/296562030624899072/1370539379260522516
Cheers, changed link and moved it
#1371929672228798504 message
is this the kind of thread and mod you meant? and does that work as a bug report of the issue with the camera?
i should be able to make some basic mods for a few of these in the upcoming days, tho stuff like drag is just so unreliable.. even with a test mod it's not gonna be easy to see
tho for now i'm only able to say that the barrel not despawning is likely tied to how the game handles the prefab, expecially with the explosive barrel that respawns when blown up (and i think normal when far away), don't have inside info so i can't say if it's just despawning the spawner, if there even is one, or similar
The Barrel thing I experience myself as a single player. But yes, they could be related with the order of how we cleanup potentially.
This is very awesome and makes everything much easier if we can replicate easier; so yes VERY NICE! 😄
And as alvro mentioned; a zip with the modfolder is more than enough. No need to upload to steam.
im not sure whether this is a bug or intended but the session option for player invulnerability completely overrides the mod based toggles. if this were to be fixed I think the best solution would be to have mods override the session option and maybe to also add functions to modify such session options
can someone help test weight/mass of custom models? seems to barely affect the object.
this example is from a drop of 100 units.
0 vs 100000 mass (via tm.physics.SpawnCustomObjectRigidbody)
i would expect an object with 500000kg of weight to fall a bit faster than an object with 0kg(?) of weight and be noticeably harder to push than the 0kg one
Higher mass would be able to push through the atmosphere easier than an identical object of less mass.
fall a bit faster not slower sorry
Fall speed doesn't depend on mass
the heavier object did fall slightly faster though?
and they feel about the same to push
The only thing that should be higher is terminal speed, not acceleration
my logic is that if the shipping crates are heavier and they are harder to push than a barrel, that making a custom asset heavier, it should be harder to push. and thats not what im seeing to a noticeable degree
You testing aerodynamics and other components. Not weight.
See how it affects other physical objects; eg big plate with suspension and wheels on or something
regarding mesh import issues: discarded faces happens when there are more than 32767 faces I think. there was also some corruption bugs with very high complexity models where semi random vertices get connected and cause massively incorrect triangles (something above 100k vertices)
I need to do some testing again because I forgot whether it was faces or vertices that were capped. it's probably faces?
see what I said to Alvaro: pushing the object with a vehicle feels almost identical regardless of what weight I give it
and no matter how heavy I make it, I can't get an object to act the same as a default shipping container prefab
from memory, in order of most to least wanted:
- A chance for our hopes and dreams to not be mercilessly shattered
- Function fixes (e.g. KillPlayer issues, "color issues", etc...)
- Custom asset importing optimizations
- Models and textures import painfully slowly and especially in multiplayer
- Improved custom model collision with wheel visual deformation and entering build mode or repairing
- Transparent custom textures
- Custom model surface properties like grass/mud/sand/snow (how would this be done? a texture?)
- Mod UI update (hey Frans I think you might know this one already)
- More extensive block modification function set
- Things like setting powercore count
- Control server-wide block bans and block unlock state
- Block unlock state: whether a block is available at all, like how blocks are missing in the builder before unlocked in Stranded
- Live updating statistics like weight and aerodynamic displays
- Things like weight values ||(per block and total structure weight)|| and COG aren't changed when a block is modified
- Per-player block bans and block unlock state
- Low priority: getdrag function. the only use cases I can come up with are for the wiki and for random little aerodynamics edits for racing or something
- More control over player input and menus
- Forcing a player to enter/exit build mode
- Forcing cursor unlock state
- etc... (need further research)
- Graphics controls
- Fog start/end
- Fog color (how would this work with sky colors though?)
- Render distance
- Toggle in settings whether mods can control render distance (for low-end users)
- Post processing
- Things that the cinematic camera feature can already edit
- DOF
- Things that the cinematic camera feature can already edit
- Water surface opacity/color/target height
- Underwater fog start/end/color
- Sky type (Pioneers, High Seas, Space Sector, Airborne, Classic)
- Sky top/horizon colors
- Spawnable bug fixes
- New spawnables
- Normal/specular/metallic(?) maps for custom textures
People, let me know if I missed anything (I sure did) and if I got priorities wrong or anything. I've tried to be unbiased but my list might be slightly biased towards mapmaking
oh, we can't actually get drag values from blocks. it doesn't have a very real use case but it could be used for wiki numbers I guess? that's kinda low priority tbh
damnit I ran out of characters because of no nitro
alright ive actually ran out of characters for the starter list, that's a great sign
@formal crane do you see any issues with this list? not enough detail? no sources? not enough use cases?
there are a couple small things I can't add due to message length limit but one of them is for graphics control: ambient light color/brightness (like how dark caves on Stranded make the ambient light basically 0)
Mostly that it is absolutely humongous especially considering the resources we have available :p
Priorities perhaps?
I tried listing them from most to least wanted... tried
there's a lot... and I think the mapmaker bias crept in a little- my bad
ah :v Well, maybe we need more people to vouch their thoughts 🙂
I think visibility is a small issue too for that. if we got another modder role ping like you did at the start of the prefab suggestions thread, that would boost this process a lot.
I've heard from talking in general land (im not schizophrenic trust) that modding is cool but people don't know where they can put their thoughts on what should be added updated
so I think perhaps maybe even tapping outside of the modding circle could be really useful
You mean modders or people who use mods?
most of the people I saw were not people I recognized from the modding threads. at least a couple of them were console players
I think the console players spoke up mainly when I talked about the state of disrepair that modding was in
so to answer your question, they were probably 50/50 normal unmodded players and modding players, or, rarely, console players
AJ would be a good person to talk to about this if he's online at this hour he is very keen on getting a list going
Irl mass doesn't change acceleration. Increased gravity force is perfectly balanced with the increased inertia
alright well, I'll try and make scale of sorts like Frans told me to do
or maybe a crane
The backlog is so big with modding now, I think the worry is that when will the next time modding get an update after this planned as if we are talking atleast a year again then different things are more priority than others.
<@&1123912996406706277>
We just had a little chat; and moving forward with the next update cycle we will go for more healthiness in terms of the current Modding API.
Bug fixes will be prioritises - but to do so we need good reproducible cases and detail information. If (big if!) we have more time, we will reach out about our thoughts on what we can otherwise implement. But right now we see it more fitting fixing the current functionality such that it is reliable for you modders to use.
Please see the following list of our bug list, and help us expand it, make threads with information - I will keep it updated so you can follow along a little. This is not a list of what is being worked on, but rather a list of things we should investigate and move forward with.
#1140936220487192587 message
Let me know how this works 🛠️
PFB_Explosion causing crashes has a thread https://discord.com/channels/296562030624899072/1368997534307057785, i'm also gonna make another test mod with spawning explosions and despawning all spawned objects for it
Also ModBlock.SetHealth() is kind of broken, i already made a thread https://discord.com/channels/296562030624899072/1368999049188872204 and i'm gonna make a test mod for it too
meanwhile set color seems to be a lot more unreliable then expected
Thankyou. I think is the most sensible approach. As much as new features would be great, fixing existing broken ones first makes a lot of sense. I'll add some bug threads soon (hopefully).
after some bug testing... i'm more confused than before... some values (like "SetPrimaryColor(0.204,0.7411,0.224)") just don't work, ever, so there seem to be 2 bugs about colros (more details soon... hopefully)
Are you declaring the values as seperate values, our inserting them directly in SetPrimaryColor?
Eg
local r = 0.204
local g = 0.7411
local b = 0.224
SetPrimaryColor(r,g,b)
vs
SetPrimaryColor(0.204,0.7411,0.224)
And does it make a difference? I have encountered a few oddities in MoonSharp here as it would make some wrong assumptions about input parameters/overload functions.
I have made a mod to use while doing the bug in the https://discord.com/channels/296562030624899072/1368997534307057785 thread for the PFB_Explosion causing crashes with late join bug. I also put instructions on how to replicate it
Updated this but I am hitting Message limit.
Should I perhapes make a thread on its own and then you can report in there if you have made anything in relation to this? 🙂
Otherwise, if you make the threads and simple tag me there, then I will ensure out internal tracker is updated.
sorry, i'm a bit late... neither seem to work
The internally function looks so naive so will have to do a deep dive on this one later...
Again, if you have a nice and simple little script to test it. I am fine with spamming a button until it happens. But from the sounds of it, it is specific values that dont get saved?
Itd be easier at this rate to just have something save values into the blueprint file lol
really wish i could say more about this part, but i'm so confused, the only ones that seem to reliably work are black and white
@warm canopy We considered our options yes. But for now. No new stuff 😉
But it is much more complicated to save data to blueprints via new APIs. (But the last clamping talk, did spawn a bunch of brainstorming)
tho i'm sure at least secondary color was working fine the other day... which is enough for saving some data
why is all working properly now....
ok, no, it's not..., at least, not primary, but secondary works
imma go make a thread...
Oh neat
The function breaks after calling once and has to be reloaded
Probably just a broken persistance or too agressive GBC
(GarBage Collection)
Tons of bugs in #1123915629653667943 already, but here is the one for this exact one 🙂
https://discord.com/channels/296562030624899072/1372211286611464344
Feel free to write in there for this specific bug if you have more insights
Aye will do
not really, it keeps working fine, as long as you only do primary or secondary, as soon as you use both on the same block it all gets messed up
That's very cursed. In lua those should be equivalent
I can't remember the exact case but it was something with overload function, where it picked the wrong overload function in a really dumb context.
The example I gave was non-related, thinking of it, and not applicable in what I am talking about here.
It wasn't working properly for me when i tested your broken float encoder/decoder
I have made the mod for bug testing
Should I perhapes make a thread on its own and then you can report in there if you have made anything in relation to this?
Yes that might be a good option especially if you can pin it at the top.
(Note: I've had messages in topic threads auto-deleted when trying to simply update them - can you perhaps reduce the aggressiveness of the bot?)
can someone help test salvage spawnable collision issues? seems like some of them sink into the ground
this issue has been around for years at this point iirc
and now its stopped..?
Nope. Dyno is pretty insane on that regard. It usually comes down to dumb things like trible same character or stuff like that...
hi guys, im new here, how do i mod sounds and is it even possible at the first place?
can i replace sounds, like the ocean waves sound with a silenced one?
or just replace the mp3 with a mute mp3 indiana jones style
As far as I know no... At least not via the official modding
I know there are some tools to replace textures and probably also sounds, but those are technically against the EULA, so can't really help
Really appreicated all the work so far with the bug reports. Very helpful. I'll do a pass later today.
In terms of the most useful things added in the past, I think the subtlemessage functionality is probably way up their. So if you get time, UI related functions are incredibly useful (e.g The title text (seen in space))
Yeah I agree. I think there are some small wins to be have had there; I generally support any kind of feedback to the player. Super useful for gamemodes.
Same with player event feed and proper dialogue system access.
Yup, they go along way to making mods feel less clunky
But yeah, this modding release cycle will be focused on bug fixes as said.
Maybe a few functionalities will come out from fixing said bugs.
I dont think theirs that many bugs in the grand-scheme of things. Most notable being the explosions prefab causing a crash on players joining whilst spawned, the invincible not overriding the server setting and probably the colour issues that Jess has
Let see how it looks at the other side, I can't push for more at the moment.
Drag is also something i'd like to see fixed, tho I still need to setup a decent test mod
Personally the Set Health stuff is also making me cringe, I think there is a few more of these cases where things are just way too unreliable or requires some kind of weird tribal knowledge to circumvent some non-descriptive behaviour.
Things should be just straightforward.
Set Health has always been weird because it also doesnt affect the strength of the welds
Posted it in general chat and got ignored so figured this may be a better place. Eventually gonna make it all work but I wanted to try my hand at a semi botnak themed turret
If anyone has any ideas/suggestions please lemme know. Preferably before I start trying to program animations
Would be funny if it would only shoot at builds that dont have the majority of their blocks painted yellow.
Omg i have THE idea: use actual projectiles.
Save a blueprint of a single pipe or something like that and spawn them with a massive force.
player name must have "BOTNAK" somewhere in it to be a friendly
i wanna try and make a feedback system between blueprints and mods to see if i can make it so you can shut down the turret with an EMP
I tried doing that with dynamite but my issue was that the blueprint had a random offset that i didnt feel like figuring out
Oh oooof
yeah
is communication between mods even possible?
my first idea was to add stuff to tm, but thats blocked
and idk if its shared between mods anyway
No its not
rip
each mod runs on a different sandbox
closest thing are hacks like spawning objects and measuring them with raycasts
Itd be nice to have some way but nothing right now unless you do some really janky way by having one mod look for objects
why would you need mods to communicate between eachother? Only thing i can think of are dependencies, but a dependency manager that bundles different mods into a single package would be better for that
you could have a mod that implements a projectile system and other ones just use the functions that it exposes
that's what dependencies are for (specially when they are required for the mod to function rather than optional)
I wish we had some way of communicating to a db that you could then pull from with a different mod.
we dont have that either 👍
https://xyproblem.info/ then you should ask for what you actually want, not something you think might solve your problem
The dependency mod would only exist in my mod env, right?
Lets say i make a mod for spawning bouncy balls that can have rules for what they bounce off of, and this mod can be used by other mods
If i want to make it so that my red bouncy balls only bounce off of other red balls, it would all work just fine with the balls spawned by my mod, but what if another mod spawns red balls? There would be 2 instances of the balls mod running and they wouldnt know of the balls spawned by the other instance
Thats why it would be cool to have it as a central thing instead, it gets loaded like a normal mod and exposes some api for other mods to use
if proper dependency management is added, downloading your mod would also download your dependencies and any dependencies of those
so it would be loaded as it's own mod with it's own env
if so, how do i interact with it lol
theres no way to do that currently
i dont remember pipethruhill having LODs 👀
what is the bug?
continuously getting player joined event?
seems like it. its only started happening today though...
seems like a somewhat rare bug but it did happen twice or thrice in about 1-2 hours of hosting. it stops after other things are triggered in the update function
What you mean by other things?
in my update function it checks how far behind the server is running. if it's above 1ms it'll log the server frametime. if it's above a certain higher threshold it'll log again and clear unused/scrap structures and log the results. I'm guessing itd be something with logging because it only stops when either thing gets triggered and logs
I'll send the lua file asap as I can't explain it well from mobile
Does anyone know what this error means?
It seems you tried to do set position of something that isn't an object
Likely something that was an object but now deleted
thanks
Could be worthy reportin as bug report if it is consistent 🙂
Might be a user error, but just wanna flag it... Don't hold back with the reports.
Not sure if this is bug but register keydown callbacks doesnt always work and ive found I have to have a few seconds of delay before registering for the host to load in
I feel like its become more of an issue with later updates
here is the lua file. i still dont know what exactly triggers this bug fyi
I'm pretty sure it's just me using tables wrong
This was happening because i forgot to delete a tm.physics.ClearAllSpawns() from one place

seems like "other things" includes other players joining as well
Made a new thread for the whole Modding Resurgency 🙂
https://discord.com/channels/296562030624899072/1374687311538814986
It is worth noting that I am not only asking for bugs. But could also be Quality of life things.. Eg. weird Up vectors missing from classes. This is a little vague for now, but anything that seems small and would make your life easier.
I'll keep most of this discussion in that thread now. And then general modding discussion can continue here. I'll keep track of both to the best of my ability, but don't hesitate to ping me!
Heya, any chance you could make a thread for this one? 🙂
Maybe someone else can help with making mod with reproducible case.
making the character 95% the original size or lower makes him fly, i'm gonna make a thread about this bug
Its always been the case (atleast since several updates), hence why in my server utilities mod I dont allow going below 1
ah i just thought that was a physical limitation of the api, never tried it outside your mod
it would be definitely cool if we could make the character smaller for miniatures
On one side it would be cool, on the other if the Devs have to spend time on this instead of other stuff it's not really worthed
Which reminds me, a bunch of assets (lava, pipes and some flowers) when scaled exactly to 1 they are actually scaled way bigger (bigger than both 1.1 and 0.9) tho it's quite inconsequential, and having to handle scale differently for every object would be a pain
I think the last time smaller scales worked for the character properly was somewhere around 1.5
We have some thoughts for this actually.. Unfortunantely, if we wanted to fix this then we might break existing maps.
That's fine, it's a lot less work for us to set the scale to ~1 than for you to go fix the scale on all the objects on all the maps
Usually we have a lot of discussing on whether.. Should we fix things and break everything that compensates for said broken thing.
Or, keep compatibility and increase implementation complexity, usually resulting in more inconsistent behaviour.
I would say to just fix it tbh
Mostly just uphill battle with mappers as they would have to go through and fix them in their maps 🙂
As of now trailmapper fixes it already, everything scaled to exactly one gets scales to 0.0001 so the scale stays linear
So, if the scale 1 gets scaled down to how it's supposed to then nothing changes, if every other scale is scaled up to match then everything will need an update
Yeah, but every old map would have to be opened in trailmapper to update the scale.
With the second fix yes, first one no
First one technically yes, but the change should be too small to notice
it would be cool if we could have keybind glyphs in strings ngl
I remembered this had been discussed before and a search found that the issue was discussed with you back in 2023 in bug-reports:
#bug-reports message
You suggested adding a "ToggleCollider" to the API which would be an ideal solution 🙂
Fuck aroud with <sprite index=<num> in the string until you find what you need.. Psst... You didn't hear it from me 😉
Agreed 🙂
Sprite index is awesome btw, fitting that code in a subtle message isnt 😛
I dream of more ui functionality one day 
Me too
does the tag's characters count towards the length limit?
Yup 😐
Controller Xbox:
1 = B
2 = X
3 = Y
4 = LB
5 = RB
6 = LT
7 = RT
8 = DPAD
9 = DPAD UP
10 = DPAD RIGHT
11 = DPAD DOWN
12 = DPAD LEFT
13 = MENU
14 = SWAP SCREEN
15 = XBOX BUTTON
16 = LEFT STICK
17 = LEFT STICK UP
18 = LEFT STICK RIGHT
19 = LEFT STICK DOWN
20 = LEFT STICK LEFT
21 = LEFT STICK PRESS
22 = RIGHT STICK
23 = RIGHT STICK UP
24 = RIGHT STICK RIGHT
25 = RIGHT STICK DOWN
26 = RIGHT STICK LEFT
27 = RIGHT STICK PRESS
55 = A
56 = B
57 = X
58 = Y
59 = LB
60 = RB
61 = LT
62 = LT + RT
63 = RT
Controller Playstation:
33 = L1
34 = R1
35 = L2
36 = R2
37 = OPTIONS BUTTON
38 = LEFT STICK
39 = RIGHT STICK
40 = O
41 = X
42 = Square
43 = Triangle
44 = DPAD UP
45 = DPAD RIGHT
46 = DPAD DOWN
47 = DPAD LEFT
48 = ALL DPAD
49 = TOUCHPAD
113 = TOUCHPAD
Additional Controller Buttons:
64 = L1
65 = R1
66 = L2
67 = L2 + R2
68 = R2
69 = DPAD
70 = DPAD UP
71 = DPAD RIGHT
72 = DPAD DOWN
73 = DPAD LEFT
74 = MENU BUTTON
75 = SWAP SCREEN
76 = XBOX BUTTON
77 = OPTIONS BUTTON
78 = LEFT STICK
79 = RIGHT STICK
80 = LEFT STICK
81 = LEFT STICK UP
82 = LEFT STICK RIGHT
83 = LEFT STICK DOWN
84 = LEFT STICK LEFT
85 = LEFT STICK PRESS
88 = Circle
89 = X
90 = Square
91 = Triangle
92 = RIGHT STICK
93 = RIGHT STICK UP
94 = RIGHT STICK RIGHT
95 = RIGHT STICK DOWN
96 = RIGHT STICK LEFT
97 = RIGHT STICK PRESS
100 = DPAD UP
101 = DPAD RIGHT
102 = DPAD DOWN
103 = DPAD LEFT
104 = ALL DPAD
114 = L1
115 = R1
116 = L2
117 = R2
Mouse:
28 = Mouse
29 = Left Button Click
30 = Middle Mouse Button
31 = Right Button Click
32 = Arrow Keys
33 = ALL DPAD
106 = Mouse
106 = Left Button Click
107 = Middle Mouse Button
108 = Right Button Click
109 =
Keyboard:
98 = UP ARROW
99 = DOWN ARROW
112 = LEFT ARROW
119 = DELETE
120 = B
122 = RIGHT ARROW
153 = A
Other :
50 = No Access
51 = Caution
52 = Alert
53 = XP
54 = Coin
86 = No Access
87 = Caution
109 = Black Square
110 = Black Rectangle
111 = Slightly Longer Black Rectangle
112 = Small Alert
121 = No Access
(this should be added to the wiki)
Man theirs 100+ sprite ids. Not sure if I've got the stamina 
it probably can be distributed between a couple people ||(or the frans could give us the list since they probably already have it)||
If someone can give me an example of how to check them, i can help
Just copy and paste the sprite id into the games username field
What is the games username field?
sadly the "sprite index= " text contributes to the byte limit, so its very limited in useability
tm.playerUI.AddSubtleMessageForPlayer(playerId, "FreeCam", "Press <sprite index=1> to toggle Free Camera!", 10)
So... uh... HTML tags can go anywhere? 😮
"┌─ <b>Lap</b> Time by..."
"<b>Ha </b><i>Ha </i><u>Ha </u>"
'Someone' may have opened a worm of cans!
YOOO
time to add doom to subtle messages
worm of cans is wild btw. i think you meant can of worms
deliberate
plus it's a better visual
oo you could do like flare on text with a scrolling bold part
like you have "Claim the crown!" and like 2 characters are made bold and that scans across the text
well you might end up with text that all tag and no... um message
I wonder if <br/> for line breaks works
I did scrolling text and other animations already in TCP - don't need HTML for that.
I know /n works in Subtle messages - I use it.
and no it's just like
Cl<b>ai</b>m the crown!
but for subtle messages and putting bold on a small part of it
Animation works in Subtle Messages too
wait what if we put <style> and then custom css XDD
But yeah adding bold, italics, underline, etc it's useful.
Subtle messages really suffer heavily under the char limit, it hurts to use
@ Frans take notes
yeah. The Header part of a subtle message doesn't actually even fit all 32 on screen - unless you put a line break in (and then you get 30 visible at least)
this to be used on the regular UI window
We can get around the character limit with animation (lots of updating values) so it's still handy to be able to use tags
what about divs?
hehe who knows?
span too?
div and set font size !!!
maybe even LINE HEIGHT!!
what happens with absolute positioning and relative offsets
can we move divs outside the UI window?
set the overflow to display too?
I haven't got time to test right now. I expect it might be tags but not styles etc.
I might try this in the morning or afternoon... so many possibilities
<ul>👀
<div style="">content</div>
Can't wait for people to make eye splitting rapid blinking marquee scrolling nightmare UI's 😂
God forbid horizontal scrolling in mod windows
oh sorry - did that one
It would be crazy if things like <audio> work
radio button / checkbox when
so the UI is built on a browser you say?
doom
Yeah no probaply not. Would be very odd if thats the way it works
adds TM wiki embed
<table> could be interesting
text aligning perhaps
or if we do have styling then customizing text background, overflow visibility, line height, font size
WE COULD DO TRANSLUCENT UI EVEN
oh actually
hyperlinks?
if absolute positioning works then you could just have an actual custom UI engine
How short is your URL?
as short as me
Fair enough
there are two more but theyre probably not relevant for tm
yup
OK so if colour works - wow
color and font size
colour and size do work in some places
italics works in subtle messages as thats probably how Dethrone works
Ah oof dreams crushed
this allows translucent colors..?
it should
I also just showed it here:
#1140936220487192587 message
shh
Yep coloured text works
The tags appear not to count towards the 32 character limit at all!
btw the game still has a chance to crash if you enter too many characters
Im pretty sure they do on subtle messages, atleast with the
Sprite tag #1140936220487192587 message
https://docs.unity.cn/Manual/UIE-supported-tags.html
not all of them but, good guidance 🙂
Yeah I didn't make it very clear but I was just referring to the standard UI stuff there.
Which I exactly did just before you posted that 🤣
I have it marked for this cycle
https://discord.com/channels/296562030624899072/1374687311538814986
yay
custom html != custom css. Even if you can specify the attributes, they might be ignored, and likely just a few tags are supported
Hey guys, I've just started on making some mods for TM. I can't find anywhere if we have an in-game console or maybe even a log file to see prints etc from Lua?
tm.os.Log(whatever)
tm.os.Log("erm ackschualli")
Thanks! I've also only found this so far https://github.com/ALVAROPING1/Trailmakers-mods/blob/master/Documentation.lua for parseable docs, is there anything newer than 3 years old? Or any API list
Collection of the mods i have made for the game "Trailmakers" - ALVAROPING1/Trailmakers-mods
Unfortunately I am pretty sure that's up to date
Tho the game should provide you with one that for sure is up to date, either in the mods folder directly or from "documentationmod"
Thank you thats's perfect!
tm.playerUI.AddUILabel(0, "header", "<line-indent=50%>Header 1 which is really unnecessarily long for</line-indent>") crashed the game
edit: mb its just the character amount crash
ooh, could that be used to disconnect (but not ban/kick) players? cause that is probably clientside rendering
line-height at 50% also crashed the game
are you sure the string is not longer than 64 characters?
trust the process ||(don't)||
yeah thats gonna crash your game
its 64
damnit so many of these from frans' unity docs list dont work
why why why
also i dont think any of the ones that require a string (e.g. <font-weight="100">) will work unless im doing something wrong
wait i dont need to put the "" for color at least
hyperlinks do work but you can't click on them 😭
This tag stuff is effectively a new feature for us which is pretty fun 🙂
theres also like 5 things out of frans's unity docs list that actually work
and all the proper fun stuff like text align, line height, and width dont work
Bummer. Nice work going through and checking though 👍
damn you, glyphs don't work in ui
and yes i tried other indexes
tf why isnt <s> allowed
funnily enough, line-height and mspace do work in other places(used to align the pixels)
standard tags for text formatting
<a> - hyperlinks (can't click on the links) (doesn't work with subtle messages)
<b> - bold
<color> - colored text
<i> - italics
<rotate> - rotate individual characters (works only in subtle messages)
<size> - font size (maximum of 16px before vertically overflowing in ui window)
<sprite name> - can't test
<sprite index> - glyphs like controller inputs works only in subtle messages
yeah out of that literally only 6 of them do anything, and one of those don't work properly
so all we get is colored, bold, italicized, miniature text
and also translucent
this should be pinned
hmm because subtle messages allow sprites, WHAT ELSE WORKS?
IT ALLOWS <S>
YOO
god save us all it allows size too
frans never patch this out istg lol
the character limit still exists but now we can cover the screen with subtle message
we can have thin message subtle messages too!
also uhmm
new ui windows just dropped-
that only happens every other message it seems
Use line breaks after each letter to get vertical text
box
i wonder if i can get the formatting to work on the image too lol that would be horrible
Such a shame the SMs suffer from tags adding to the character limit
such a shame theres a char limit at all
I tried to add colour to my racing splits hud but I can't fit enough info in between the tags 😦
one day i will relearn how to import a texture
i dont think it does sadly
fair enough tbh
wait
it still loads the image even with the tag
No closing tag?
yeah I found that too but I wonder if there are other consequences (with no closing tag)
Imagine being able to fit "War and Peace" in there
well then
rotate works
indeed
cool
ooh nice one
"GO!"
negative <pos> values makes the subtle message flicker like crazy
a has snuck into the image 🕵️
yoo negative line indent pushes it left
wow!
Doom
you can get 2 characters outside by sacrificing the header too
ah you dont need voffset, that saves a lot of chars
its only giving me one character that escapes to the bottom center of the screen
Imagine this when SM's are stacked. You could really get stuff in the way of the player mid screen hehe
oh trueee
yoo negative mspace also lets you escape
and mspace is less characters
nice
deploying flashbang
my biggest issue is the char limit and also trying to get more than one character on one line escaped
half credit
well i can escape 2 characters but theyre seperated like theyre in a long distance relationship
oh and theyre on 2 lines too...
oh piss off it works but only for up to -425 space
so close yet so far
what i currently have rn allows 3 characters btw
cause <align=justified> is so god damn fat
but ofc <space> is limited to -425 so i cant center it anyway
damnit <indent> is limited to -425 too... is it a hard limit?
they yearned for the custom ui
screen space sprites when 💔
nobr is a joke
who dwells t here
i saw someone typing
i can do this but what good is it without text
if i can make it have multiple characters on one line then it can be backgroundless text
screenspace crosshair?
you’ll be taking like a fourth of the screen with subtle message backgrounds but would be cool
pretty cursed
if its only the one it would be cool for heads up display info for modded values
as long as you can get enough characters
i give up on a background but if i can just get something like
[E]
Talk
then id be happy
i just need the multiple chars per line and centering it too
this char limit SUCKS
4 chars to work with
why does it even exist
because 🖕
is there an actual reason tho?
i dont know
the game CAN handle way more (even in official use) so
my best guess is 🖕
<nobr> for no line break is full of shit
it hasnt worked once in my use case
ez
lowk if i just keep throwing shit at the wall maybe it will eventually work
i haven't been at this for over 2 hours trust me
take a break
i wonder if a hyperlink would work
i forgot how to href
nvm
0-181 (182 glyphs total)
181 is empty it appears
118 is the warning symbol used when overlapping blocks are present in build mode
121 is a red/white circle thing
127 is the arrow key cluster
129 is XP
130 is gold
im afraid it isnt possible to make all the escaped text on one line
this is the closest i can get
z layering between subtle messages is random
if a completely transparent image is used, could have a slimmed down subtle message
HATRED
for some reason the header can go further before linewrap fucks it
this is the best i can do
Keyboard glyphs:
32 = ALL ARROW KEYS
98 = UP ARROW (small)
99 = DOWN ARROW (small)
112 = LEFT ARROW (small)
119 = CTRL (small)
120 = B (small)
122 = RIGHT ARROW (small)
127 = ALL ARROW KEYS (small)
128 = TAB (small)
142 = F
143 = 1
144 = 2
145 = ALT
146 = Y
147 = Z
148 = I
149 = R
150 = E
151 = CTRL
152 = W
153 = A
154 = S
155 = D
156 = SPACE
157 = B
158 = DEL
173 = TAB
175 = BACKSPACE
176 = F5
177 = INSERT
178 = F6
179 = F8
180 = C
Extraordinary glyphs:
13 = Hamburger menu (controller)
15 = Xbox logo
49 = Long empty key
50 = No access
51 = Caution
52 = Alert
53 = XP
54 = Gold
86 = No access (small)
87 = Caution (small)
109 = Square empty key (small)
110 = Rectangle empty key (small)
111 = Rectangle empty key (small)
121 = No access (small)
181 = Empty
Mouse glyphs:
28 = Mouse
29 = Left Button
30 = Middle Mouse Button
31 = Right Button
106 = Left Button (small)
107 = Middle Mouse Button (small)
108 = Right Button (small)
yeah the imgui is not richtext elements. They are ancient unity things :v
ohgod haha
NOOO
--
I have come to realise that I have communicated the next fixes will come in "next release cycle"
This was ambiguous and what I meant was whenever we have time served for modding programming.
There won't be anything for PvP part 2, but I can let you know there has been made things for after that.
known for a while: rotation seems to affect whether theyre in shade or not
and wavy plant prefabs are not correctly darkened as you go deeper into the water it seems
how do i get the complexity mod?
modding is PC-Steam only.
yea i have it now
might wanna update y our roles
they can be found either on the ingame workshop or steam worskho
i would recommend steam workshop
how?
i got it btw
thx
got it
Hey I'm having trouble with block health, it seems to be that blocks StartHealth and CurrentHealth for freshly spawned blocks don't match. Also using SetHealth only changes the start health and not the current health. Anyone have any insight?
health functions are known to be broken for ages, it'll probably be fixed in the update after pvp part 2
it now has a proper icon
options to control echo in a given area would be cool, like in caves and such
although so would darkness volumes / black fog
actually fog volumes/world fog controller in general
damnit why is this model cursed
its triangulated, its uvs arent completely cursed, the model faces and vertices are both way under 32767
Hey I've had some issues with clearing up the map of structures. When I clean up for example, the entire build gets removed but suddenly flashes back into existence a moment later. By which method are you successfuly clearing them up if you don't mind my asking
ModStructure.Dispose()
@scenic echo
local playerId = 0
tm.playerUI.AddUILabel(playerId, "header", "<b>Time of day presets</b>")
tm.playerUI.AddUIButton(playerId, "morning", "<color=#d0a000>Dawn</color>", SetTOD)
--tm.playerUI.AddUIButton(playerId, "early_noon", "<color=#70a0ff>Morning</color>", SetTOD, 45)
--tm.playerUI.AddUIButton(playerId, "default", "<color=#5080ff>Default</color>", SetTOD, 50)
--tm.playerUI.AddUIButton(playerId, "late_noon", "<color=#eedd99>Afternoon</color>", SetTOD, {tod = 60})
--tm.playerUI.AddUIButton(playerId, "sunset", "<color=#dd77aa>Sunset</color>", SetTOD, {tod = 65})
--tm.playerUI.AddUIButton(playerId, "evening", "<color=#503090>Dusk</color>", SetTOD, {tod = 70})
--tm.playerUI.AddUIButton(playerId, "midnight", "<color=#202050>Midnight</color>", SetTOD, {tod = 95})
--tm.playerUI.AddUIButton(playerId, "late_night", "<color=#102090>Night</color>", SetTOD, {tod = 5})
function SetTOD()
tm.world.SetTimeOfDay(34)
end
Wth
is this a good or bad thing lol
I have no idea why the hevk that error is a thing
EXACTLY
i am cursed with ui istg
every time ive tried doing stuff that involves callbacks or buttons/text in general it never works
@scenic echo FIXED IT
Me too lol
that makes so much sense
i just did:
function onPlayerJoined(callback)
tm.playerUI.AddUIButton(callback.playerId, "morning", "<color=#d0a000>Dawn</color>", SetTOD, nil)
tm.playerUI.AddUIButton(callback.playerId, "L1", "Switch active keybind", SwitchKey, 0)
end
the function needed to be initialized before you tried using it
fun fact i tried that earlier and it didnt work
so all i needed to do was ask tech support
as always
goodnight now, it's 11pm where i'm at
1:26pm moment
YO
setting time of day to 0/0 or math.huge makes the world completely black, but when setting it back to an in-bounds time, ambient light remains in a weird state
this works until the world goes in and then out of nighttime
entering and leaving water also fixes this (water probably has its own ambient light setting)
and during dusk (before the moon has come out) you can have no ambient light and no moonlight
@cinder spruce yo
reflections/cubemaps still work i believe
this only works when timeofday has been rendered in the broken state once
build mode corrects this bug
this bug affects tire tracks
particles are completely fucked
tire tracks render through things
@sleek apex this might be good for your darker night mod
particles and tire tracks are bugged though, exiting build mode resets it, entering water resets it, it's client side
Still cool
That seems pretty cool but a bit technical for me 🫠
I only know how to use trailmappers
it's pretty easy but still buggy and gets fixed client side really easy
what the
exactly vro
witchcraft
using structure.GetRotation().y%1==0 no longer works for quickly detecting structures in build mode?
@shadow iris What about just
tm.players.GetPlayerIsInBuildMode(playerId)
no. this mod needs to targets builds that are outside of build mode
and you cannot assume a player only ever has one structure
I see what you mean
add logs to see where execution is actually ending
does ModBlock.SetGyroPower() actually work? i cant get it to work on a regular gyro
at the very least it doesn't update in the settings menu of the gyro. at worst, it's not actually doing anything
ModBlock.GetGyroPower() works just fine at reading the in-menu value of the gyro
setting engine power to math.huge or 0/0 crashes the game while welding. who saw that coming 🤔
i have a solution to this bug
don’t use math.huge as an argument 
Yeah that seems the cause of most of the issues
And setting engine power to 0 always causes a crash
erm its actually undefined NaN and not 0
0 also crashes
header colors in subtle messages are just so god damn pretty
yo alvaro, you told me a while back to use deltatime to calculate server performance... that doesn't work
also apparently this happened
bump
I suspect SetGyroPower doesn’t work. I thought it was something else but I use that function in Aerobatic Aces mod and it does not set the gyro power
i see thats another bug off to #1123915629653667943... im aboutta get told off by dyno for spamming
For frans reference, you can see in my mod by starting the mod, flying around until you run out of fuel but make it back to the carrier. The gyros in the plane (Hellkite) don’t regain their power