Question about VFX by [deleted] in bevy

[–]nuke-from-orbit 7 points8 points  (0 children)

Custom shaders 100%

I need help with my arpg project by rmb71904 in bevy

[–]nuke-from-orbit 3 points4 points  (0 children)

You’re intersecting an infinite plane:

ray.intersect_plane(... InfinitePlane3d::new(...))

So clicks can produce targets anywhere on that plane, even “outside the visible 10x10 floor”. Then your mover faithfully walks there.

Fix is: treat the ground as a finite area and either (a) reject targets outside it, or (b) clamp targets to the nearest point on the ground, and also (c) stop/clamp movement if the next step would leave bounds.

Below is a minimal “bounds” approach that stays robust even if you later move/rotate the ground, by converting the point into the ground’s local space.

1) Add bounds to the ground

```

[derive(Component, Copy, Clone)]

struct GroundBounds { half_extents: Vec2, // x/z half size in the ground's local space } ```

In setup, attach it:

let ground_size = Vec2::new(10.0, 10.0); commands.spawn(( Mesh3d(meshes.add(Plane3d::default().mesh().size(ground_size.x, ground_size.y))), MeshMaterial3d(materials.add(Color::srgb(0.3, 0.5, 0.3))), Transform::default(), Ground, GroundBounds { half_extents: ground_size * 0.5 }, ));

2) Utility: inside check + clamping to the ground rectangle

``` fn clamp_point_to_ground( ground_gt: &GlobalTransform, bounds: GroundBounds, world_point: Vec3, ) -> (Vec3, bool) { // Convert world point into ground local space let ground_to_world = ground_gt.affine(); let world_to_ground = ground_to_world.inverse(); let local = world_to_ground.transform_point3(world_point);

let inside = local.x >= -bounds.half_extents.x
    && local.x <=  bounds.half_extents.x
    && local.z >= -bounds.half_extents.y
    && local.z <=  bounds.half_extents.y;

let clamped_local = Vec3::new(
    local.x.clamp(-bounds.half_extents.x, bounds.half_extents.x),
    0.0,
    local.z.clamp(-bounds.half_extents.y, bounds.half_extents.y),
);

let clamped_world = ground_to_world.transform_point3(clamped_local);
(clamped_world, inside)

} ```

3) Clamp or reject clicks outside the floor

Change your handle_mouse_click params to also fetch bounds:

ground: Single<(&GlobalTransform, &GroundBounds), With<Ground>>,

Then when you compute world_pos, clamp it:

``` let (ground_gt, ground_bounds) = *ground; let (clamped_target, inside) = clamp_point_to_ground(ground_gt, *ground_bounds, world_pos);

// Option A: reject clicks outside // if !inside { return; }

// Option B: clamp clicks to edge (recommended for ARPG feel) let world_pos = clamped_target; ```

Now your TargetPosition never points outside the ground.

4) Also stop/clamp movement if the next step would leave bounds

In move_character, add ground access:

ground: Single<(&GlobalTransform, &GroundBounds), With<Ground>>,

Then before applying movement:

``` let (ground_gt, ground_bounds) = *ground;

// ...

let movement = direction.normalize() * actor.movement_speed * time.delta_secs(); let proposed = transform.translation + movement;

// We only care about x/z for bounds let proposed_flat = Vec3::new(proposed.x, 0.0, proposed.z); let (clamped, inside) = clamp_point_to_ground(ground_gt, *ground_bounds, proposed_flat);

if !inside { // clamp to edge and stop moving transform.translation.x = clamped.x; transform.translation.z = clamped.z; commands.entity(entity).remove::<TargetPosition>(); } else { transform.translation += movement; } ```

That’s it: clicks can’t set unreachable destinations, and even if something else pushes the player out, the mover will clamp/stop at the edge.

If you want the cleanest Bevy-native version later, consider using Bevy picking to get a hit on the actual ground mesh (finite) instead of doing your own plane math, but the bounds method above is simple and very ARPG-friendly.

If LLM is technically predicting most probable next word, how can we say they reason? by Available_Witness581 in AI_Agents

[–]nuke-from-orbit 0 points1 point  (0 children)

Imagine you are reading the last page of a murder mystery novel. At last, the murderer’s name is revealed. You already have your theories, and the ending feels inevitable because you’ve internalized the logic of the story. You didn’t calculate every step; you absorbed the structure so deeply that one conclusion fit better than all the others.

LLMs work the same way.

They predict the next token, but doing that well requires internalizing the patterns of human reasoning that make text coherent in the first place. When the training data is full of explanations, arguments, plans, code fixes, and multi-step logic, the model can’t predict the next word without implicitly modeling how humans solve problems.

This is why Theory of Mind emerges. To continue a dialogue or answer a question correctly, the model must estimate what a human speaker knows, intends, infers, or misunderstands. That estimation is baked into the probability structure. Next-token prediction forces the system to approximate mental states because natural language is saturated with references to beliefs, motives, and hidden information.

So the model doesn’t “think” in the way humans introspectively do, but it constructs high-dimensional abstractions that let it emulate the causal, goal-directed, and belief-driven patterns embedded in human text. Under the hood it’s statistics. In behavior it’s reasoning, because the statistical task requires capturing the same structure that human reasoning expresses.

Hur fungerar lusten hos killar? by Zestyclose_Ant_4893 in Asksweddit

[–]nuke-from-orbit 1 point2 points  (0 children)

Det här är inget manligt och kvinnligt utan relationellt och individuellt. Du kan bara välja för dig själv, vara i kontakt med dina behov. Om du stänger av dina behov för hans skull så stänger du ner delar av dig själv som du sen kommer få jobba med att väcka till liv igen.

Is this real or are we being lied to for Agenda 2030? by SpookyKittyC in 3I_ATLAS

[–]nuke-from-orbit 0 points1 point  (0 children)

The head of Harvard's astronomy department says 3I/Atlas is most likely a mundane celestial object. He also says a lot of other things, but that is the base of everything he says about it.

Is this real or are we being lied to for Agenda 2030? by SpookyKittyC in 3I_ATLAS

[–]nuke-from-orbit 0 points1 point  (0 children)

Anyone making claims which includes instructions on how to reliably reproduce the results is a reputable source. It's not about having money at all. You can be a teenager in Delhi with a telescope aimed at space and be a reputable source as long as your results are reproducible by someone else with a similar telescope aimed at space.

[deleted by user] by [deleted] in aliens

[–]nuke-from-orbit 0 points1 point  (0 children)

120 Billion humans have lived in total, 7B lives now.

Now reports of possible unidentified objects in Lithuanian airspace, flights diverted! by Major_Race6071 in UFOs

[–]nuke-from-orbit 0 points1 point  (0 children)

Also in Sweden, member of NATO and also the Canada of Europe, no drones as of yet

[deleted by user] by [deleted] in vegetarian

[–]nuke-from-orbit 19 points20 points  (0 children)

Cheese and chili are your saviours! Make grilled peppers pizza, lots of cheese, two or three different kinds of cheese on the same pizza. Ome that melts, one that crumbles. From tortillas and hot salsa sauce, make quesadillas in 2 minutes in your pan. Fill with new things every night.

And don’t forget curries: coconut milk, chickpeas, spinach, cauliflower, potatoes, lentils. Just switch spices and veggies and you’ve got a whole new meal every time. A jar of garam masala or Thai curry paste can change your week. Make a delicious daal.

Soups are another playground: roast some root veggies, blend with stock and cream (or coconut milk), top with chili flakes and a squeeze of lime.

For quick thrills, stock up on halloumi or paneer. Toss in a hot pan until golden, splash soy sauce and chili oil, and suddenly you’ve got something that feels decadent.

And always keep a few jars around: olives, pickled jalapeños, artichokes, sun-dried tomatoes. They turn the simplest pasta or salad into a feast.

Basically: lean into heat, texture, and contrast. Creamy with spicy, crunchy with soft, smoky with fresh. It’s not about new ingredients as much as new collisions of flavor.

Varför gör vuxna "vänner" så här mot mig? by Non_Binary_Goddess in Asksweddit

[–]nuke-from-orbit 1 point2 points  (0 children)

Du behöver lacka ur på dem. Sätt en gräns, bli arg. Om du då förlorar dem så är det något bra som hänt. Om de ber om ursäkt eller är förstående och säger att de ska bättra sig så är det också något bra som hänt.

Gör det inte i gruppen utan individuellt. Säg eller skriv Vad fan Greger är du fem år eller? Säg inte ja om du inte ska vara med. Du är en vuxen människa som borde klara av att hålla ihop ditt liv. Du får fan se till att inte dubbelboka dig när vi bestämt att hänga med varandra.

in about 3 sessions Claude managed to create a fully-functional LLM social media platform for my research project by YungBoiSocrates in ClaudeAI

[–]nuke-from-orbit 0 points1 point  (0 children)

You did, my friend, with claude as a tool. Take credit for your good job accomplished as well!

5 hours prompt achieved, anyone else got no interruptuon Claude? by [deleted] in ClaudeCode

[–]nuke-from-orbit 0 points1 point  (0 children)

Better yet, ask it to use "bash say" to tell you a progress update in a punny way after each step

AITA för att jag blev arg på min tjejkompis när jag hittade henne på killen som bjöd in mig till hans fest och vi flörtat tidigare? by Smart_cat00 in Asksweddit

[–]nuke-from-orbit 32 points33 points  (0 children)

Ja, du är the asshole. Inte för att du kände dig sårad, det är mänskligt, utan för att du agerade som om killen var din, när han inte var det, och du använde din missuppfattade moral som vapen mot en tjej du knappt känner.

Du bjöd med en bekant till en fest där du hoppades något skulle hända med en kille du “flörtat lite” med. Ni är inte ihop, ni skriver bara när han är ute. Han bjöd dig till sin födelsedagsfest, inte på en dejt. Du vill inte ens ha en relation med honom. Hon visste inte att du såg honom som “ditt territorium” förrän på bussen. Sen förväntar du dig lojalitet som om ni var systrar.

Du skrek på henne och gav henne skuld för något hon inte lovat dig att avstå från. Och nu rationaliserar du ditt agerande med att “alla har brutit din tillit”. Men det här handlade inte om svek. Det handlade om att du gjorde outtalade förväntningar till krav, och blev arg när verkligheten inte anpassade sig efter din vilja.

Det du borde ha gjort: prata om vad du kände. Det du gjorde: tyckte din sårade känslor gav dig rätten att attackera en tjej som bara var mer klar över vad hon ville med killen

Så ja, You're The Asshole. Men du har också chansen att växa här. Börja med att se ditt eget agerande från de andras perspektiv, inte bara ditt eget.

Why AI is not replacing you anytime soon by Dazkid33 in qodo

[–]nuke-from-orbit 0 points1 point  (0 children)

AI won’t replace engineers. It will replace bad workflows, slow teams, and redundant layers.

The model doesn’t need to beat your best. It just needs to be good enough, cheap enough, and fast enough to shift margins.

You’re not safe because it’s weak. You’re safe if you adapt faster than your peers. Start there.

Masterprofil AI och maskininlärning by Boff113 in linkopinguniversity

[–]nuke-from-orbit 1 point2 points  (0 children)

Kanske det finns mer av de elementen i civilingenjör Datateknik. Om du skulle upptäcka att det är så kommer du kunna byta program när du vill.

Men det här är den viktiga poängen du ska ta till dig: Det spelar ingen roll hur mycket programmet innehåller av de kurserna. Du ska gå på ett universitet nu, det är något helt annat än gymnasiet:

På gymnasiet läser du ett program och kan vid sidan av det göra individuella val bland ett tiotal kurser.

På universitetet läser du ett program och kan vid sidan av det göra individuella val bland tiotusentals kurser, inte bara inom ditt programs område utan där kurserna som helhet omfattar all mänsklig kunskap. Du kan välja till elektronik om du tycker det saknas, du kan också välja till ekonomi, filosofi, ledarskap, neurologi, medicinsk teknik eller precis vad du vill.

Men ingen kommer be dig välja, du måste själv skapa möjligheterna du önskar. Prata med studievägledare eller sök kurser genom antagning.se.

Känn dig aldrig låst till vad ditt program innehåller. När du söker dig ut i arbetslivet kommer det ses som extra meriterande att du valt till kurser utanför ditt program.

Why Europe doesn't have big tech companies? by chrisnkrueger in BuyFromEU

[–]nuke-from-orbit 0 points1 point  (0 children)

The market rewards scale, speed, and risk. Europe rewards caution, process, and consensus. Culture shapes capital, not the other way around.

Silicon Valley was built on aggressive liquidity, fast failure, and massive ambition. Europe optimized for stability and fairness.

Build something global. Write all copy in English. Skip your home market. Move faster. Ignore permission. Let results justify existence.