#⌨coders-cave

1 messages · Page 32 of 1

barren shale
fallen siren
#

🤓

lapis flint
fallen siren
lapis flint
#

i guess it was made by someone localy just to make meme

fallen siren
#

k

#

??

barren shale
# lapis flint

bruh ngl i did something like that to a client's website

lapis flint
#

💀

barren shale
#

i accidently used && between the condition for the password and email

#

and you're not supposed to do that but how would i know

#

so you jsut need the right password to login and it doesnt matter what email you use

edgy flare
#

And tbh, if every password is unique, it’s probably safer

#

Only one guy can have password1 for a password

craggy coral
#

how hard would it be to do a gta like map zoom in on a sprite and u take controtl of them and now instead of a 1 player god game it becomes a 20000k multipalyer sprite game where veryone ahs there professions and building the ciurrecny and magic and otehr systems to make

#

i think its doable if someone had 50 million dollars to pay lol

tulip quest
#

this is not a worldbox related programming channel

#

just sayin, this is the one we chill out and show off really cursed code, that one's more specifically worldbox stuff

opaque ingot
#

This channel is dead

#

Only I can make it alive again

tulip quest
#

please do

#

I like talking about programming

opaque ingot
tulip quest
#

GDscript

opaque ingot
#

Yes

tulip quest
#

I don't really know it tho

opaque ingot
#

@barren shale remember me?

#

NYEHEHHEHEHEH

tulip quest
#

papyrus moment

#

anyway, I'm currently wrestling with a programming problem that is very vague

#

it's not small enough to ignore or big enough to easily diagnose, I'm not sure if it's a floating point precision error or something wrong with my code, and for my hobby project it's very important that I solve it

#

and I'm not going to share it here to spare you all the stress

edgy flare
#

How do I know how to make my code more efficient

#

I had a force on my horizontal vector, and one on the vertical, then I added one on the vertical, and it got all jittery

#

And one time I had some code in regular void update that was super laggy, but when I changed it to fixed update it stopped jittering

edgy flare
#

Or do I just mangle my code until it works

errant trail
#

they really think 20 million players are gonna play the game at the same time and think 20 million players are even possible to handle

#

well i mean its possible if you do chunking

#

hmm

#

but that's literally called an RPG

errant trail
karmic cave
lapis flint
#

💀

tulip quest
# karmic cave 👽

dudes be like: "it's ok if it's unreadable, as long as it works it's fine"
the code:

barren shale
#

no matter how much chunking you'd do and how much you shard your database

#

its just too much

#

there are games that can handle millions of players but not in one map

errant trail
#

the player's pc would crash too 👽

barren shale
#

but you need 50 supercomputers to run that server

quartz pumice
barren shale
#

probably not

#

joining these threads would require a thread too stronk

orchid frigate
#

Im not the one to judge unreadability but goddamn what situation requires this

errant trail
#

10000001 threads

#

is that what u wanna hear

barren shale
#

as it is more than 35k lines

#

so probably some sort of json save file

edgy flare
#

Game is just look at a picture

edgy flare
#

But it could hold 2 million people probably

errant trail
#

i meant like elaborate

edgy flare
#

Like wheres Waldo

#

But instead of book it is a picture on the internet

hardy field
#

Congratulations on learning what television is I guess?

errant trail
#

is it normal for unity to take ages to load

#

for an empty template

#

i didnt keep track of the time but

#

its been like an hour

tulip quest
#

that's not normal

#

how old is your pc?

errant trail
#

probably 9

tulip quest
#

sheesh

#

well, a new project always takes longer to load than a preexisting one

errant trail
#

nvm it started to actually do something

tulip quest
#

for me it takes 1 minute to open something, and like 5 to open a new one

#

my laptop's like 3-4 years old

#

maybe 5

#

but it's pretty good

errant trail
#

mine has no GPU

#

maybe thats why

tulip quest
#

it's probably just the general quality of your computer

#

GPU shouldn't have much to do with it

#

also is your computer high, low or mid-end for 9 years ago?

errant trail
#

probably

#

mid or low

#

definitely not high

tulip quest
#

well, if it works it works

#

I remember the computers I used to have

errant trail
#

@tulip quest @tulip quest @tulip quest @tulip quest @tulip quest @tulip quest

tulip quest
#

yes?

errant trail
#

WHY IS RB

#

NOT DEFINED

#

rb

tulip quest
#

you have declared rb privately and not set rb to anything

#

if you, say, set rb to the rigidbody of an object it'll work

errant trail
#

i followed a tutorial 😢

errant trail
tulip quest
#

to set rb to something you need either:

#
  1. An object reference
#
  1. A public variable to set rb to
errant trail
#

and how would i do that

#

in the code

tulip quest
#

#2 is easier

#

so let me tell you

#

public Rigidbody2D rb;

errant trail
#

how to do method 1

#

i wanna know for the sake of wanting to know

tulip quest
#

let me check

#

(I don't know off of the top of my head, which is one reason 2 is easier)

#

hang on a second

#

you can probably just use rb = GetComponent<Rigidbody2D>(); or similar

#

I'm not sure exactly what would go in the <> though

#

actually I think I got it right

#

maybe the capitalization is different, but that should be it

errant trail
#

2nd way didnt work

tulip quest
#

well, I didn't finish describing it

#

it's kinda easier shown than told tho

#

lemme open stuff up

tulip quest
#

it might be rigidbody2d or RigidBody2D or something like that instead

errant trail
#

Rigidbody2D

#

i checked

tulip quest
#

might as well check 2 or 3 different capitalizations

errant trail
#

[SerializeField] public Rigidbody2D = rb;

#

bro

tulip quest
#

you never know

#

sometimes it ends up being capitalized differently

errant trail
#

no i checked

tulip quest
#

I'm working on showing way #2 properly

errant trail
#

when i capitalize differently it says namespace not found

tulip quest
#

alr

#

let me show you stuff

#

after doing the first step I had in way 2, something changes on the script object

#

it might look like this, for example

errant trail
#

oh

#

now i have it

#

and i changed it

#

andddddddddddddddddddd

#

andddddddddddddddddddddd

#

yay worked

tulip quest
#

nice

#

what did you use?

#

kinda hard to keep track of it from my pov

errant trail
#

[SerializeField] public Rigidbody2D = rb;

#

in the script

#

then i simply go to the editor and changed the reference

tulip quest
#

nice

#

that's what I was about to explain

#

now I'm curious about if I can get the first way to work for me

#

yep, I got it

errant trail
#

show

tulip quest
#

I got it happening in 3d but it should be no different

#

private Rigidbody rb;

#

rb = GetComponent<Rigidbody>();

#

done

errant trail
#

its 10x easier to make an object move in unity than godot wow

tulip quest
#

true

#

apparently if you understand godot it's easier, but that's a bit of a barrier to entry

errant trail
#

my laptop doesnt even run godot

#

godot uses a opengl version my laptop cant support

tulip quest
#

no wonder you use the android verson of worldbox instead of the steam one

errant trail
#

theres a flag to make it use vulkan instead but when i wanna playtest it just uses opengl and crashes the whole thing

tulip quest
#

damn

errant trail
#

lol

tulip quest
#

I remember the computer I used to have to use

#

back in the day I'd try and get it to run roblox and it would lag so bad above minimum graphics

#

not even on hard-to-run games lol

errant trail
#

bro the unity documentation is so shit

#

how large is the sprite for a tile is

#

100x100?

lapis flint
errant trail
#

ok then 64x64 should work

#

but it leaves massive gaps

#

128 worked tho

#

but now it overflows

#

wtf

#

bitch wha

#

its not supposed to overlap

#

nvm just change PPU of the sprites to your resolution and it will be fixed

lapis flint
errant trail
#

the sprites have a property named "Pixels Per Unit"

#

basically if your sprite is 64x64 then you set it as 64

#

idk why we even have to set that

lapis flint
lapis flint
#

Wb have 1 ppu

#

for all sprites

#

Or almost for all

errant trail
#

it said pixel size was automatic lol so i got mislead

edgy flare
#

I was following a wall slide tutorial because my character was sticking to a wall if you input a horizontal input, but it didn’t work. I think the object is phasing through the wall a little bit, and it thinks it can stand on it.

#

I don’t really need wall sliding, I just don’t want it sticking to the wall

#

The tutorial clamped the velocity, but it wasn’t working because a y velocity of 0 wasn’t clamped

edgy flare
errant trail
#

ok

quartz pumice
#

That's funny

errant trail
#

real

#
        float fov = Camera.main.fieldOfView;
        fov -= Input.GetAxis("Mouse ScrollWheel") * 10f;
        //fov = Mathf.Clamp(fov, minFOV, maxFOV);
        Camera.main.fieldOfView = fov;
```???????????????????? why this not working? i have camera component and theres no errors too
#

im trying to zoom in and our using scrollwheel

errant trail
#

nvm fixed it

errant trail
#

thats my solution

#

no code cuz im learning too

errant trail
#

yes it does

#

you have to code it

tulip quest
#

you can probably make a tag to put on climbable walls, and if you touch a wall you can check if it has the tag

#

I have no idea how those extra words got in there

edgy flare
#

Oh

#

I can detect when it’s on a wall and when it’s on the ground

#

But Im still having trouble fixing it hitting the wall and changing its y velocity to 0

#

I’ve tried taking away the ability to move horizontally in one direction once you get too close to the wall, but you can still run into the wall quickly and shorten the jump

#

I don’t really care what happens on the descent, but I really don’t want the jump to stop early if the player doesn’t want it to

edgy flare
#

Nvm, I just made it stick to the wall wbsuffer

edgy flare
#

My game has been reloading domain for 40 minutes

errant trail
#

does unity load and run all scripts

#

even if they are not attached

lapis flint
#

Not run

#

How it can run if it is not attached?

errant trail
#

😔

errant trail
lapis flint
#

No

#

Unity doesn't run scripts that not on scene

#

If you mean monobehaviours

errant trail
#

wait theres more than one type???

lapis flint
#

Yes, but i am not about it

#

No script can run automatially if you didn't coded it by yourself

#

What's your issue?

edgy flare
#

My unity engine has been loading for 18 hours

#

And when I try to click on it, it just has a loading icon

lapis flint
#

uh

edgy flare
#

I mean the mouse turns to a loading icon

lapis flint
#

You sure you haven't some editor scripts on starting scene?

edgy flare
#

I coded it all myself and I don’t know what editor scripts are

#

Plus, even if I did, I can only edit one script because I can’t click anything in unity

lapis flint
#

Editor scripts runs in editor without need to press play button

#

If you don't know about them, i guess it is not your issue

#

Since when your unity started acting like that?

tender hedge
#

REAl

#

C++ is used in what?

edgy flare
errant trail
#

(gives u it not cure ut)

edgy flare
#

Me when I get brain damage induced by cancer

edgy flare
edgy flare
#

I can’t close the tab either because there’s a loading icon instead of the mouse

tulip quest
#

try task manager (if you're on windows)

#

ctrl-alt-delete opens a menu from which you can open it

#

then you can select the unity application and hit end task

#

this method is even more reliable than alt-f4

edgy flare
#

Thanks

#

That was confusedcat

lapis flint
elfin cargo
#

guys

#

how to download mods

bitter sedgeBOT
wet girder
tulip quest
#

shame, that might get in the way of my plans to cover france

tulip quest
#

I don't want to give them the victory of making me waste even more paper

static solar
# wet girder

My 145161 square kilometre large pdf image is still printing 🙄

prisma grail
static solar
#

They really need to make better printers smh

static solar
prisma grail
#

Also, 0/10, should be a power of 2.

static solar
#

I couldn’t survive without a PDF that covers the surface of the sun

prisma grail
errant trail
#

why is adobe limiting the size

#

like i get it if its 10m

#

or even 4m

#

but not 15 million kilometers

orchid frigate
#

nah just compiler nvm

#

I love c++ without all the OOP parts

#

They are ok but idk

tender hedge
edgy flare
#

It’s fixed now

flat valley
errant trail
#

i discovered the unity particle system

quartz pumice
barren shale
#

isnt new just malloc without all the parts you rewrite everytime

#

zig/rust are the new c/c++ anyway

limber oracle
#

Hi

edgy flare
limber oracle
#

How do I become a beta tester

#

Or stuff like that

edgy flare
#

For what

tranquil sun
#

hi

hardy field
#

You don't really apply for it

edgy flare
#

You could join their community if you want to test it

#

It’s much more likely than if you just sit around waiting for someone to contact you

wet girder
#

You gotta become an active member of the community and contribute a lot to become a beta tester

edgy flare
#

I’ve been messing with scriptable objects in unity, and I was wondering if there was a more efficient way of creating projectiles than just instantiating a prefab

barren shale
#

or become a translator xzibit

edgy flare
#

My enemy is phasing through the floor

#

When I look at the inspector, it looks like his box collider disappears randomly

#

This what he looks like >wbsuffer

#

I didn’t even change anything inside of his scripts

remote spruce
edgy flare
#

When I made clones to see how many bullets I could make, 3 clones fell through straight away, and two clones stayed

#

But then they fell later

#

This isn’t because I made clones though because it falls through even when I don’t make them

edgy flare
versed lantern
#

how does one achieve the modder role?

edgy flare
versed lantern
edgy flare
#

Can’t help past that then

prisma grail
# versed lantern how does one achieve the modder role?

Step 1: Read the description of this channel to realise that you're asking in a completely wrong place.
Step 2: Read #📕information message too, where you'll find out that getting the modder role requires you to apply to a mod manager on this server (either me, @north dune, or @torpid isle ) in DMs. When you do that and meet the requirements, you'll receive the role relatively quickly!
If you have any further questions, let's please move this to #🔧modding-talk , #🚑help-chat , or DMs to avoid filling this channel with more topics that it's not even supposed to focus around!

edgy flare
#

I don’t know why it was deleting the collider though

supple kiln
#

What

uncut frigate
#

E

tulip quest
#

try a modding channel, not the programming channel specifically for non-worldbox stuff

errant trail
static solar
#

I wanna make games but am too scared to actually switch to a game engine, instead confining myself to the MonoGame Framework

#

The struggle

errant trail
#

being scared of advancing

edgy flare
versed lantern
edgy flare
versed lantern
#

No what is a commitment

tulip quest
#

do you not know what a commitment is?

edgy flare
#

Commitment is when you must choose and you will be locked into the choice

tulip quest
#

you should at least know the one in the dictionary, which isn't that hard to access

tulip quest
#

well, there are a good few online ones

#

and I guess everyone has a first time with a word

versed lantern
heady lark
tulip quest
#

bro is your first message in this server calling someone stupid 💀

edgy flare
heady lark
wary jackal
#

nahh can anyone explain the singleton method?

#

shits confusing

edgy flare
#

Like a scriptable object in unity.

wary jackal
#

k

errant trail
#

you read and write in that one singular object

#

done

heady lark
#

im a coder and live in a cave

lapis flint
dreamy vortex
#

@orchid frigate come back

edgy flare
quartz pumice
# heady lark im a coder and live in a cave

does your internet travel through your water supply? I know some coders-cave people will put reflective sheeting around the hole in the stone where their water comes from, and then puts a badass laser at the top

prisma grail
errant trail
#

2012 worldbox

uncut frigate
#

Cool

barren shale
#

Basically taking money from rich people to pay for the €4 server in Germany instead of doing it yourself

wheat rain
#

Anyone want eg gthing

#

It turns numbers into strings

#

That look cool

kind shore
#

<!doctype html>
<html>
<title> gaeisbad </title>
<h1> no homo </h1>
<p> unsin ur homo </p>
</html>

errant trail
median saddle
#

Ooh is their a tutorial I didn't know we can mod this game

edgy flare
next lotus
#

a

edgy flare
#

I just got a new laptop, I downloaded unity, and I can’t find my projects

#

I have the same account

tulip quest
tulip quest
#

does it work still?

edgy flare
#

Yes

#

It’s on a not portable computer and the other one is portable

#

So I was wanting to switch

tulip quest
#

alr, it should be pretty simple

#

you just need to find where you have your projects stored and transfer them using a usb or email or something

#

personally, I send files using bluetooth, but only because I know how

edgy flare
#

aye alright

robust cliff
#

local tool = script.Parent
local model = tool.Model
local poison = model.poison
local sound1 = tool.drink
local sound2 = tool.ragequit
local trigger = tool.Trigger
local activated = tool.Used

function onActivation()
if activated == false then
print("you idiot")
poison:Destroy()
trigger.CanTouch = true
end
local function kill(hit)
wait(0.1)
activated = true
local character = hit.Parent
print(character)
local humanoid = character:FindFirstChild("Humanoid")
print(humanoid)
if humanoid then
sound1:Play() -- Play the first sound
wait(3)
humanoid.Health = 0 -- Kill the player
sound2:Play() -- Play the second sound
wait(3)
tool:Destroy()
end
end

trigger.Touched:Connect(kill)

end

tool.Activated:Connect(onActivation)

Can you guys see any issues with this script? I'm new to coding so the script doesnt work and I cannot see the issue.

edgy flare
#

Also, if the whole thing isn’t working, is there a debug log?

knotty root
robust cliff
#

i got it working

north apexBOT
#

error There is no player for this server

edgy flare
#

!level

#

!rank

split parrotBOT
edgy flare
#

!rank

split parrotBOT
edgy flare
#

!rank

split parrotBOT
knotty root
#

@edgy flare do !rank in #🤖bot-commands
Not here

edgy flare
tulip quest
#

fair

knotty root
errant trail
#

not impressive but im happy

#

!rank

split parrotBOT
errant trail
#

see its accurate

barren shale
errant trail
#

yes

split parrotBOT
shell osprey
#

!rank

split parrotBOT
quartz pumice
#

hol up

#

@errant trail you gave them ideas

#

also im listening to hatsune miku rn 😭

prisma grail
prisma grail
dusky sky
#

I dont watch anime

quartz pumice
dusky sky
#

Hihi

long lynx
#

… someone ik is named hy and ppl say hi hy

#

☠️

knotty root
#

Don't say that again

mighty void
#

!rank

split parrotBOT
dusky sky
#

!rank

split parrotBOT
dusky sky
#

Sorry wrong channel

errant trail
#

gojo is the demon i cling to

#

i cling to

eternal urchin
#

Idk if this is the right place to say this, but the tsar bomb in English says “Tsar Bomba”

tulip quest
#

I'm not sure where you would say that, but here isn't the right place. It's understandable you've made that mistake though, several people have done it for things far less relevant (like checking rank lol)

#

there are literally 7 instances of checking something not even relevant to programming right up there, so you're a lot more relevant

wet girder
#

Also this is not the right chat for this

lime knot
#

!rank

split parrotBOT
errant trail
#

LOW RANKS SHOO

#

SHOO

#

SHOO

#

mods delete all traces of mee6

dusky sky
#

!rank

split parrotBOT
dusky sky
#

Yas

prisma grail
prisma grail
dusky sky
#

Sorry i didnt know where that channel was

prisma grail
errant trail
#

person who uses bot command under this message is a dum dum and should have gone to #🤖bot-commands

dusky sky
#

Treu

split parrotBOT
errant trail
#

^^ dum dum

tulip quest
#

bruh

#

insert actual coding topic here

wet girder
#

Idk if it's a coding topic but I bought a framework 16 recently

prisma grail
wet girder
#

have you seen this btw

prisma grail
wet girder
#

It's a fork yeah

#

I think it has some changes to work with framework 16

#

Would be a pretty cool project tho to try and make a configurator desktop app for the keyboard

prisma grail
#

It's nice though that it just works with the built-in keyboard. Even more convenient than I would've imagined tbh.

strong reef
desert edge
#

@abstract veldt SHUT THE FUCK UP

#

RIGHT NOW

abstract veldt
#

whа

distant wraith
#

I hate integrating front and back ends so much

#

I'd remake the backend in Js if the docs aren't next to useless

wind scaffold
#

hi gang idk if this is coding or not but

#

nvm

barren shale
#

makes it very easy

quartz pumice
errant trail
#

why does this look so shit

errant trail
#

nvm im a wizard

#

contrast is underrated

edgy flare
#

I was wondering how I should go about setting spawn points for enemies in unity

#

I am able to have one enemy but with different abilities and sprites because of how I made them

#

But it seems bad to just have many different enemies loaded at the same time

errant trail
#

great question to ask chatgpt

errant trail
#

git is currently giving me brain cancer

#

THE FUCK YOU MEAN "UNRELATED HISTORY"

#

THE REPOSITORY HAVE 1 FUCKING FILE AND ITS A README

#

for other people heres the solution:

git pull --rebase origin main
git push -u origin main 
edgy flare
barren shale
#

just fetch origin and hard reset

#

your way requires a useless merge and fucks up the commits history

#

but tbh git is fucked

#

it has too many unnecessary things

edgy flare
errant trail
errant trail
edgy flare
errant trail
#

because im shit

#

problem?

edgy flare
#

Hi shit

#

I’m Bob

edgy flare
tulip quest
#

ChatGPT never has the best solution unless it's made extremely obvious over the web, but an answered prompt and an ability to bugfix goes a long way

#

even though the code it provides is best used as inspiration only

edgy flare
#

I’m don’t even want the code I can make it myself wbsuffer

#

I just want to know what I should be doing

tulip quest
#

alright, let me finally try and help directly

#

is the problem you have that you can spawn enemies but don't want the whole map's enemies loaded in at once?

edgy flare
#

Yes

tulip quest
#

alright

edgy flare
#

Plus I’m not sure if I should instantiate them or not

tulip quest
#

I've got a bit of a solution

#

If you instantiate enemy spawn points when you load the map instead of enemy spawns, you can make them keep track of the distance to the player and spawn an enemy when they get too close. You'll need to make sure a spawn point can only have 1 enemy to its name, but it's not too hard to make

#

and if you don't want to instantiate spawn points, you can just make a single gameobject that keeps track of all spawn points

timid field
#

Hello world to my fellow coding bros

timid field
#

Its alright for basic stuff but it can also use depracated info

distant wraith
#

I don't know if people still use ChatGPT for actual coding anymore, at least not reliably

#

For free version anyway. You either get an outdated one or the dumber gpt-4o-mini

#

That one can't do shit except being annoying

#

If you're going to pay for the pro version, you can just use Anthropic's Claude 3.5

quartz pumice
#

The outdated one used to be really good, but then they made it really fucking dumb

#

The entire reason chatgpt got popular was because it was actually good, now it's worse than the old stuff

quartz pumice
#

like the old one was better than gpt4

quartz pumice
#

I think that was too early for that though, it was the chatgpt developers trying to make it more woke (best word) because it would sometimes spout stuff

grim saffron
orchid frigate
#

I'm still waiting for the day the numbers align just right for it to spout something absolutely outrageous

versed lantern
#

ive got a complicated question that i have no idea on how to solve.. how would you rotate a point a certain DISTANCE on the surface of a ellipsoid? i could only rotate a degree with this: (ive already asked forums that did not solve it)

versed lantern
barren shale
#

but what i would do

barren shale
#

i'd get a ray to the point

#

wait

#

what's the question

barren shale
versed lantern
#

this was the best i could do

barren shale
#

what do you mean by rotate a distance

#

you rotate angles not distances

versed lantern
#

move* not rotate

barren shale
versed lantern
#

yes

barren shale
#

im sure there's a solution

#

just gotta figure out how to explain it to ChatGPT

versed lantern
#

Vincenty's formulae are two related iterative methods used in geodesy to calculate the distance between two points on the surface of a spheroid, developed by Thaddeus Vincenty (1975a). They are based on the assumption that the figure of the Earth is an oblate spheroid, and hence are more accurate than methods that assume a spherical Earth, such ...

#

well it only works in certain cases tho :/

#

the spheroid has to be oblate

barren shale
#
using UnityEngine;

public class EllipsoidMover : MonoBehaviour
{
    // Function to move a point on an ellipsoid in a specific axis direction
    public Vector3 MovePointOnEllipsoid(
        float a, float b, float c, 
        Vector3 initialPoint, float distance, 
        string direction = "x")
    {
        // Calculate the normal vector at the initial point
        Vector3 normal = new Vector3(
            2 * initialPoint.x / (a * a),
            2 * initialPoint.y / (b * b),
            2 * initialPoint.z / (c * c)
        );

        // Choose a primary direction vector aligned with the specified axis
        Vector3 primaryDirection;
        switch (direction.ToLower())
        {
            case "x":
                primaryDirection = Vector3.right;
                break;
            case "y":
                primaryDirection = Vector3.up;
                break;
            case "z":
                primaryDirection = Vector3.forward;
                break;
            default:
                throw new System.ArgumentException("Direction must be one of 'x', 'y', or 'z'.");
        }

        // Project the primary direction onto the tangent plane
        Vector3 tangent = primaryDirection - Vector3.Dot(primaryDirection, normal) / Vector3.Dot(normal, normal) * normal;

        // Normalize the tangent vector
        Vector3 tangentUnit = tangent.normalized;

        // Move the point in the direction of the tangent vector
        Vector3 newPoint = initialPoint + distance * tangentUnit;

        // Project the new point back onto the ellipsoid surface
        float scale = Mathf.Sqrt(
            (newPoint.x / a) * (newPoint.x / a) +
            (newPoint.y / b) * (newPoint.y / b) +
            (newPoint.z / c) * (newPoint.z / c)
        );

        newPoint.x /= scale;
        newPoint.y /= scale;
        newPoint.z /= scale;

        return newPoint;
    }
}
#

a, b, c are just the dimensions of the ellipsoid

#

you can replace that with a vector3

versed lantern
versed lantern
barren shale
#

test it with known values

#

make the ellipsoid a sphere with a radius of 1

versed lantern
#

oh wait a minute i messed it up

barren shale
#

and then move it in one direction by PI

versed lantern
#

i messe up the input

barren shale
#

ahhh ok

versed lantern
# barren shale ahhh ok

well it moves in the right direction but wrong distance, the distance it travels depends on where it is on the sphere...

barren shale
versed lantern
#

ok

barren shale
#

if you make an ellipsoid with a radius of 1

versed lantern
#

fine

barren shale
#

and moveit by 2PI

#

you should get the same point

#

make sure that the initial point is on the ellipsoid

versed lantern
barren shale
#

2 x PI

versed lantern
#

yea i know that

#

well uhmmm, it moved

#

1.298325 units

barren shale
#

what do you mean

#

it should be at the same spot it started at

versed lantern
#

its not

barren shale
#

can i see all the inputs

#

that you are giving the function

versed lantern
#

Vector3 vector = EllipsoidMover.MovePointOnEllipsoid(SphereSize.x, SphereSize.y, SphereSize.z, new Vector3(0, SphereSize.y, 0), Mathf.PI*2);

#

Spheresize = 1,1,1

barren shale
#

what is the returned vector?

versed lantern
#

0.9875705, 0.1571767, 0

barren shale
#

also weird

#

why is there 3 possible directions you can input

#

when you can only move in two if you want to stay on an ellipsoid

versed lantern
#

what

#

ohh

#

idk

#

i just asked chatgpt again and it game me this @barren shale

quartz pumice
tulip quest
tulip quest
errant trail
#

chatgpt is simply just a tool

tulip quest
errant trail
#

chatgpt should be taken with a grain of salt

#

think of its responses as a guidance instead of the absolute truth

tulip quest
#

at the moment I'm trying to think about a solution to the original problem posed here, but it might not be solvable because there is no mathematical formula for the perimeter of an oval

barren shale
#

I’ve solved all of these simple function problems with ChatGPT

#

I know it can’t solve everything but it can solve most of them

#

Never failed me at least with the right prompt

errant trail
#

same

quartz pumice
tulip quest
#

if it's general programming related, it belongs here. If it's Worldbox modding related, it's in #🔧modding-talk. If it's to do with Worldbox or this discord server, ask #🚑help-chat.

desert edge
#

remind me whats the code to make globgolabglam in vidogames

timid field
quartz pumice
timid field
#

It just how facebook embeds look like in discord

#

They dont show anything

#

But the login thing

quartz pumice
timid field
#

Welp rip

timid field
quartz pumice
#

I'm on data so I guess my IP is suspicious

quartz pumice
#

I do have a Facebook account but it won't let me login

quartz pumice
knotty root
#

is making scratch projects considered as coding?

tulip quest
errant trail
edgy flare
#

Tbh it’s pretty great

static solar
subtle cliff
#

how to code

#

in 5 minutes pls

edgy flare
#

For 5 minutes

#

Bam

#

You can code

#

Go outside without any precautions for virus’

errant trail
# subtle cliff in 5 minutes pls

coding is basically giving the computer every single instruction and details about something then it shits itself

just watch a beginner guide on something like c# or javascript

edgy flare
#

Bam

#

Youb god a code

errant trail
#

bob is 10

#

ignore him

quartz pumice
#

I wonder if it's easier to teach asm or python in 5 minutes

edgy flare
#

That’s against discord TOS

errant trail
#

atleast hes smart enough to know that smh

edgy flare
#

And then saying atleast?

quartz pumice
orchid frigate
#

imagine trying to explain that ah is a container

quartz pumice
#

tell them rax is a bunch of bits

orchid frigate
#

for data that is pretty much solely numbers

edgy flare
#

Should teach him assembly

#

Simplest one

quartz pumice
#

Don't get them on decimal, they'll learn that after the 5 minutes

orchid frigate
#

for python you just tell them to write an essay and filmanise it

#

make it look like it comes from a hacker movie and boom working python code

quartz pumice
#

Lol

orchid frigate
#

unless its those one line abominations or the string manipulation symbols

quartz pumice
#

Just tell them ; counts as a new line

orchid frigate
#

thats not python

#

python hates semicolons

quartz pumice
#

The one line abominations don't use ; ??!?!

orchid frigate
#

In C they do

#

idk how they work in python I think it uses spaces and tabs and shi

#

nvm I dont think python can do one liners

quartz pumice
#

I think interpreter in Python just pretends ; is /n

orchid frigate
#

Python

#

I think that just writes individual bytes but instead of writing the bytes it uses random calculations

quartz pumice
orchid frigate
#

explain that in 5 minutes

#

to a person whose work on a computer only includes word, excel and google

quartz pumice
#

I could but I'm on a cruise and the Buffet is a 1 minute walk from the aft

quartz pumice
#

If that's their only experience don't even try

tulip quest
# orchid frigate Python

this is the most terrifying piece of python (or any other programming language) that I've ever seen

tired needle
#
print("hi chat")
tulip quest
#

ok

knotty root
narrow tendon
#

you think someone might be mental enough to try to add first-person to the game? someone did that with the binding of isaac and turned the game into an FPS

#

they did it in a cool way where the walls were made up of small slices of part of the texture and copy-pasted to look like a 3D wall

#

and then the floor is just a flat color

slow junco
solar epoch
blazing current
#

i wanna post the cool macos rice i made in bash and c but no image perm 😭

feral bramble
#

need to be lvl 10

sick berry
halcyon yew
#

Mod

queen zodiac
#

@feral bramble hello

feral bramble
#

ello

queen zodiac
feral bramble
#

doin fine

flat crescent
#

Coding yes yes

edgy flare
dusty sapphire
#

Ah yes, most readable lamda expression in c++ : cpp const auto it = std::find_if((*struct_it).vars.cbegin(), (*struct_it).vars.cend(), [&](const auto& var) { return std::visit([&](const auto& element) { return element.name == expected; }, var);});

feral bramble
#

wut

dusty sapphire
#

I would have never thought to actually use something like this abomination

#

but I did, and I dont know how I feel about it

oblique rose
#

What langage is used for coding Worldbox ?

edgy flare
knotty root
tulip quest
#

maybe I'm wrong, but if it's something else it'd be good if somebody else explained it here

quartz pumice
#

Its probably c# or java or both

feral bramble
#

c#

#

if have the steam game can actually look at the code via dnspy

tulip quest
#

average programmer naming scheme:

errant trail
#

Bitlocker
Drive
Encryption
Hard
Drive
Con
Fi
G

tulip quest
#

I know, and it's terrible

#

you can't really do much better for naming it, but it's so vague without being told

errant trail
#

should have been PREP-BDE

#

prepare bitlocker drive encryption

tulip quest
#

or just prepbde

#

bdehdcfg is amazingly bad

wet girder
barren shale
#

i mean 5 letters is not even that uncommon

#

its just that there's no better way

tulip quest
#

Prepbde

barren shale
#

why is that better

tulip quest
#

more readable

barren shale
#

i dont think the point is for it to be readable

tulip quest
#

the reason it's a bad command is because it's unreadable

barren shale
#

you will not know the meaning of 99% of commands without reading the docs

#

so doesnt really matter

tulip quest
#

the reason commands and things are named as they are is to give you an idea of what the command does when you re-read the code you've made

barren shale
#

yeah its for memorability

tulip quest
#

prepbde tells you that it prepares/configures a bde (bitlocker drive encryption) while bdehdcfg doesn't

barren shale
#

but you could also argue that prepbde doesn't include "hard drive"

tulip quest
#

you pretty much need to know the command well to remember what it does

tulip quest
#

drive as in hard drive nvm dumb

#

wait actually good point

barren shale
#

i mean i agree its stupid

#

but there it cant really get much better

#

its a systemitical problem

#

and programmers love backwards compatability so they wont change it

#

backwards compatbility is the dumbest thing ever

tulip quest
#

I think it's just that someone at microsoft decades ago named it badly and nobody wanted to break everything with an update

tulip quest
barren shale
#

then dont update xzibit

#

and if you want to update migrate your code

tulip quest
# barren shale then dont update <:xzibit:535205877108572189>

you technically can go without updating in that case, but a lot of the time very useful services are developed for later versions of OSes and stuff that would be quite efficient to fit on the same machines as the older stuff, except for a lack of forwards-compatibility (which is much harder)

quartz pumice
#

fsck is superior

errant trail
#

brainfuck

barren shale
#

i think i still have the code for the brainfuck parser i've built

#

here if anyone wants to interpret some brainfuck

wet girder
barren shale
#

well if its just 2 versions then its not really called backwards compatible

#

its just that you dont change something for 2 versions

#

but when you dont change anything for ever that's backwards comptibility aand yeah i agree its trash stupidd

#

makes programming languages bloated or bad after 10 years

#

im just ranting because i used Zig and its so good and C# will never be good like it because of systematical things that can't be changed now xzibit

oblique rose
barren shale
#

But the biggest difference is that the memory is managed for you in C#

#

And there are no pointers

tulip quest
oblique rose
#

Okay thanks you all !

quartz pumice
#

I kept adding more things to it lol

#

"naw bf needs the ability to syscall too!! Wait but how do I do registers? What do I do if I'm targeting bare metal?"

#

Then my school blocked every website that wasn't on their list of whitelisted websites and the teachers had to throw every research project out the window

feral bramble
#

didn't even consult the teachers properly about the whitelist it seems

quartz pumice
feral bramble
#

...

wet girder
#
barren shale
earnest rose
#

What are you yapping about guys

quartz pumice
worldly stump
#

I take it back then

tulip quest
worldly stump
tulip quest
#

if you have a programming meme, we'll take it

#

unless it's that one gif of a guy trying to look like a hacker

worldly stump
#

alr

#

knotty root
#

Anyone mess around in godot

#

Been tryna learn it

edgy flare
#

I can’t figure out how to play an animation in unity

#

I already have a gif of it

#

And it’s in the game

#

But I don’t know how to access it

edgy flare
#

Why is unity deleting stuff when I apply a transform to a prefab

errant trail
#

my ssh keeps crashing

shy zealot
#

guys i cant update my world box (mobile) how can i update world box or update is come?

quartz pumice
knotty root
#

What’s the reason you can’t download steam mods on mobile?

#

Is mobile just missing some necessary framework to run those things?

#

Because I can definitely figure out how to modify files I think so what’s stopping me

#

If I can get a detailed explanation that would be helpful

knotty root
#

Please tell me

#

If anyone knows a reason

edgy flare
feral bramble
knotty root
#

I haven’t actually tried to mod pc myself

feral bramble
knotty root
#

If someone can send me a screenshot of how mods are stored on pc along with whatever framework is needed to run them that would be nice

feral bramble
knotty root
feral bramble
#

What little I do know is that

  1. BepinEX mods directly use the built in mod loader of worldbox

  2. NML is a mod for worldbox that uses said built in mod loader

knotty root
# feral bramble thing is i don't have a method

Ah well if you or someone else can tell me how android does it that’d be a great start, also just a screenshot of how mods are stored on PC would be dope, because I don’t see any reason I can’t open up worldbox file and stick mods into it

feral bramble
knotty root
feral bramble
#

unless it's an old unity game or has built in mod support, going have to decode with multiple steps somehow

knotty root
#

I’m trying to see if it’s possible for iOS

#

I could try and replicate the methodology

feral bramble
#

Also there's the fact people tend to mod games just to pirate the in-app purchases

#

Not much beyond that

knotty root
#

No promises but I did find imazingapp so I’m not completely hopeless

#

Pretty sure you can enable disable the premium from the files with .imazingapp but I’ve never tested myself because such things don’t interest me

feral bramble
feral bramble
knotty root
feral bramble
#

Couldn't get it to work

knotty root
#

Dang

#

I take it, it has to do somehow, with how mod loaders actually intergrate the mod file into the game?

#

Can’t get mod loaders to work on mobile at all

feral bramble
#

to get it to work probably will have to directly mod the game itself

#

and iirc can only download that on iOS if jailbroken

knotty root
#

Oh dang experimental mode also

knotty root
#

However

feral bramble
#

hmm actually never checked if the latest version of worldbox be a mono game...

#

welp I'll do that when back at my computer

knotty root
#

I’m starting to think the only way I’ll ever download a mod on mobile is if somehow i download an apk complete with all the changes that’s not possible

#

It’s basically missing the ability to even use mod loaders

#

So working around that is kind of huge

knotty root
#

I think i probably could legit just injected modded code into the base code very carefully

#

But no idea how to get it to work otherwise

#

See why others say it’s not practical

feral bramble
# knotty root Wydm

In short just has the code readily accessible if you have the right tool like dnSPY for example

#

Huh there's already a mods folder within the apk

#

hmmmmm

#

though won't be able to edit the game itself it seems

way beyond my level

#

So going have to activate experimental mode somehow ...

#

very interestin

edgy flare
#

@tulip quest I need help

#

It’s an emergency

#

I made a unity build

#

And in the game I put it so the mouse is invisible

#

And when I press escape it doesn’t escape

#

And my build glitched out and started making infinite prefabs

#

I think I accidentally made a virus wbsuffer

#

Phew I think I fixed it

tulip quest
#

When in doubt, open task manager using ctrl-alt-delete and kill the process

errant trail
#

When in doubt, spam alt+f4*

errant trail
tulip quest
edgy flare
#

I couldnt even open task manager because it was full screen

fleet warren
feral bramble
fleet warren
#

Aww 😦

karmic cave
tulip quest
errant trail
#

replit mobile app

#

literally runs on the same thread as the thing im running

#

so whenever theres an endless loop the whole app freezes

tulip quest
#

if x doesn't catch 0, if x != None does

timid field
#

But there's different causes

edgy flare
#

I made a game for a game jamaye

#

Am I allowed to put it here?

timid field
#

Go ahead if its coding stuff

edgy flare
#

It’s my first one

tulip quest
#

Nice! I think it could definitely use a tutorial for the controls and aim and stuff (even just in the description) but it's more functional than a ton of things I've made.

edgy flare
#

Didn’t really think about it much after that

tulip quest
#

yeah, I was just thinking it'd be nice if it had something just telling you you're meant to not crash into anything

#

I was wondering for a bit if there was more to control than avoiding stuff but yeah

#

it's cool that you've got proper physics between the planetoids/planets

edgy flare
royal dust
#

tomorrow will be the first day of game design class

edgy flare
#

but otherwise yeah

tulip quest
edgy flare
tulip quest
errant trail
#

like a white trail

#

easier to track movements and also would look very nice

errant trail
#

my fucking DEVTOOL is getting an error

#

?????

#

THE DEVELOPER TOOL

#

????

#

ITSELF

#

???????

karmic cave
#

what developer tool

errant trail
#

chrome

frigid cairn
tulip quest
#

honestly, using chrome today is an issue

#

for anything

#

why pay to have a better experience for each individual website you use (and suffer when there's no option) when you can just get firefox and ublock origin?

barren shale
#

chrome still has the best user experience

tulip quest
#

yeah, you can pay for youtube premium and stuff, but that doesn't cover every site

barren shale
#

ublock origin lite works

#

i've been on it for a week now

tulip quest
barren shale
#

sometimess i get ads but its still a work in progress

#

google banned manifest v2

#

ublock origin is manifest v2

#

ublock origin lite is manifest v3

#

and manifest v2 is not getting banned until june 2025

tulip quest
#

ahh, ok

#

manifest v2 isn't going to be banned for non-chromium browsers though, right?

barren shale
#

no other browser is planning to ban it

tulip quest
#

nice

barren shale
#

but some browsers that use chromium like brave and opera have built in ad blockers that will still work

tulip quest
#

looks like it's just a future thing instead of a present thing for them then

barren shale
#

yeah but they have built in ad blockers its not an extension so chromium cant ban it

tulip quest
#

ahh, ok

#

good to hear chromium is still gonna be bearable for a while longer

#

although I thought like over half of the "adblock detection" on youtube was just chrome/chromium snitching

quartz pumice
tulip quest
quartz pumice
#

edge is the best

#

it supports firefox and opera plugins too

#

and when you run out of space it will automatically delete history and older cookies n shit

tulip quest
#

I thought it was chock-full of popups of microsoft telling you what to do

quartz pumice
#

its not

#

its actually really nice

#

and everything can be disabled

tulip quest
#

or at least, that's what I got in the short time I spent getting firefox from it

quartz pumice
#

that was the update thing you can just close that

tulip quest
#

plus, even if it can be disabled... I have enough annoying things I have to disable to worry about already

quartz pumice
#

lol

#

yeah

tulip quest
#

I already have to sit through finding all the windows options for stopping this and that, (not all of the options even work) and then I have to deal with MS Edge

quartz pumice
#

yeah why tf does nothing work

#

the amount of times I had settings crash on me right after a clean install

tulip quest
#

I've got a whole news section on my toolbar even after I toggled an option literally to turn off the news and interests section in the toolbar

quartz pumice
#

and all the bluetooth did was break the fucking thing and wifi because it was the same chip

quartz pumice
#

everythings so laggy too

#

thank god I use linux now

tulip quest
quartz pumice
#

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

#

I fucking hate that shit man

tulip quest
#

it sucks

#

also for some reason the section to change my computer's timezone is greyed out

quartz pumice
#

that thing freezes whenever I try to sync time after i switch to windows to play helldivers

tulip quest
#

hang on

#

now the option is available

#

but only after I had to look up how to change it with the command prompt

quartz pumice
#

average windows behavior

tulip quest
#

actually

#

and then there's all the trouble I had removing McAfee from this computer

quartz pumice
#

oh I just reinstalled windows

#

I dont think microsoft has anything to do with mcafee

tulip quest
#

the command prompt with administrator permission couldn't get rid of it

quartz pumice
#

had to wipe the hard drive and reinstall windows to delete mcaffeee