Yeah, I worked for about 6 years as a programmer. I worked in the defense industry.
Holy crap thatās cool bro lol sounds like some interesting work!!!
Yeah Iām hardly following you.
Structs are something I missā¦
Never used field vars or lambdas⦠So yeah not my language over my head.
Oh okā¦was just trying to hold a reference to a variable in another script in the first script.
I wanted to be able to not have to call my get method Everytime I needed to change data
We both know nothing I will say is over your head lol
That sort of makes more sense⦠But yeah thats a difference in languages there for sure.
The scripting environement/game engine has all the scripts running in tandem⦠Sort of a sand box. Lots of different ways to establish references like that. I do have to do that sort of thing all the time.
Yea man ⦠It felt kind of basic but believe it or not Iāve never tried to use the ref function in unity c#. I think before I just always created a new array in the calling script and synced it with the other arrays in other scripts lol so I never used references In the way I wanted to this time.
I know this will make me sound really basic but I had actually forgotten that you could hold a (copy) reference that effected an original variable declared in another scriptā¦
And yea ..I think my first post was a little messy but both basically said the same thing bro
at least in my mind.
Anyways because structs can hold multiple types I was having issues with nullvalues . I would declare the struct in the data script and then try to pass it as an argument but because arrays act differently than other types across scripts my values kept coming up null. That was what got me on the path to use the ref function.
This was the first time I used enums and structs to hold and organize all my data so I was kinda bound to run into the array issue across scripts. Anyways ..that operator is going to be really useful until unity actually supports c#11+
Btwā¦thanks for baring with my ignorance/messy mind. Like I said Iām not the brightest person but I legit love to dev man !!!
Youāre good I havent coded in a while so its cool to think about.
Structs are nifty but hard to impliment. Good for storing things but manipulating and moving them declaring arrays of them⦠Pretty fragile.
Iām stuck declaring new classes to do such things.
Yeaā¦I think thatās what Iām gonna do from now on lol itās the best option. Itās unfortunate but my exposure to more efficient techniques is pretty minimal.
Iām trying to move towards more elegant less stupid ways of programming but itās a learning process I guess.
On the bright side Iām leaning alot of new techniques fast using AI. But the original strategy was to declare a reference field variable. If I could use c#11+ I guess it would have been as easy as creating a class but I could use a struct like you would use a class ā¦
Idk broā¦Iām gonna use ai alotmore to learn better ways of coding. Anywaysā¦Iām happy with the result so far.
I have a c# masters class on udemy. Thinking I need to take that seriously like Iām taking music study more seriously
Edit: guys I might be a basic ā ā ā ā ā lol and lazy ![]()
Iām just learning you can use singletons and scriptable objects in unity for data structures. On my racing game all the vehicles attributes were handled straight from a save file and synced across scripts when using arrays.
This is my first time using structs and not Iām realizing you can use singletons instead of classes and scriptableobjects for persistent data across scenes and game exit.
I feel like Iām just now ready to really be a good programmer but AI is taking over ⦠possibly. Fml
I think you might be making it too complicated with the ref thing. Maybe youāre applying concepts from C/C++ in C# ? Iām doing a bit of C# lately and i donāt think unity supports entity framework which is more common in the wider .net ecosystem. It might be best to just serialize and deserialize your objects to JSON files, that should be easier. Ask AI to go that route.
Its a struggle similar to what I went through. I wish I could do bit wise operations and make super effecient storage systems but godot more or less runs everything at 64 bit⦠You can get more efficient arrays going buts all baked in. Best that can be done is use basic stuff in unintended ways⦠Like Color var being a 4 vector.
Code looks odd declaring a color when you mean to be doing a spatial vector⦠Like unit vector with magnitude⦠Gotta wrap a class around it but that kind of stuff is still fun.
I need to start coding. Ive taken a couple days break from 3d stuff. Just been chilling and playing video games. Gotta finish retexturing that boat. Gonna be a pain.
Thatās whatās up man I think they call it hacking basically. And Iāve rarlycome across that makeshift necessary dynamic in code but I definitely know what u mean and it is fun.
And also ..chilling sounds good bro. Iāve been trying to also. I wish I could choose between game dev or music so I can get deeper faster but I canāt..Iām stuck switching focus ā¦
Off topicā¦will AI make programmers obsolete?
AI is better at chess.. People still play. Cameras take perfect portraits people still paint.
Really though I think AI as it is is basically a smokescreen⦠Itās sort of a farse. The big companies love it because the moat is already there⦠But building data centers the size of small cities just to have computers approximate intelligence⦠Thatās a bad trade off and an obvious sign that weāre getting ahead of ourselves.
I mean its a glaring gap of inneficiency.
So whatever it is that makes AI more portable and modular⦠I think that AI construction just becomes a more common branch of programming⦠Its more like algorithmic construction and less func by function coding. Nueral nets sitting next to nested statements in the coders tool box.
Frontier models⦠Sounds cool today but I bet it looks like a stupid idea in hindsight.
And its not really intelligent when it becomes a frozen binary. Itās something else⦠Like a mirror of intelligence⦠Or a ghost.
I got a copy of your post before via email. I can ignore it. I wouldnāt want to derail the thread.
But in brief. Things can be intelligent without consciousness. This is the bridge into philosophy⦠How do you define intelligence? How do you define consciousness?
I donāt think the AIs are conscious but they are self-aware. That is objectively⦠They can identify themselves and what they are and even their roles in a greater system. But they do this without the integral deep self awareness that we have⦠They can do all that because its all been explained to them. Theyāre more like virtual intelligences from Mass Effect.
I think this guy has the right approach.
Quite unique. Can sort of looks like itād be a drone. Is that a full on vehicle?
I got back to coding yesterday⦠Should have something to post within a couple days.
Only 4 or 5 major steps.
Sort of wondering how itāll work as a playable space. I mean what Iām working on will temporarily pass through a phase that is something like super mario galaxy.
The planet will be large enough that it doesnt feel that way but I want to get on to skeletal rigs and animations.
Later Iāll have to double back and set up some sort of stream/loading with all the spatial projections redone so it functions more like a flat plane that pulls in the location specifics.
This should let me mess around with the oddities of navigating on the surface of a sphere⦠Tracking compass directions etc.
Instead of trying to reverse engineer all the reference factors⦠Just build it out and at least have it to refer to when making the more āshortcutedā scene construction.
As always its more complicated than it seems⦠Got 3 days off after tonight I should have timeto work on it.

