TobiaszPL Posted April 2, 2019 Share Posted April 2, 2019 Int* MyPointer;Int MyArray[25]; MyPointer = &MyArray; can i somehow use it ? Link to comment Share on other sites More sharing options...
foamyesque Posted April 2, 2019 Share Posted April 2, 2019 No. Papyrus does not allow direct memory address math or access. However, object and array variables are, themselves, effectively pointers and not distinct memory reservations, so for example if you do ArrayX = ArrayY, any changes made to the elements in ArrayY will show up in anything accessing the elements of ArrayX. Link to comment Share on other sites More sharing options...
TobiaszPL Posted April 2, 2019 Author Share Posted April 2, 2019 Y but i wanted Pointer to FormList... but k :c... GetAt is so slow T_T Link to comment Share on other sites More sharing options...
foamyesque Posted April 2, 2019 Share Posted April 2, 2019 Y but i wanted Pointer to FormList... but k :c... GetAt is so slow T_T Mechanically GetAt() is, I believe, working with a pointer, but a lot of function calls in Skyrim are frame-linked -- i.e. they will require at least one frame to complete. FormLists calls also have some overhead to avoid data trampling. All of that slows things down. If you really need maximum speed out of something, convert it to an array and work on that. Arrays aren't framelinked or policed, so they're very, very quick to access, but they also remove all the safety precautions FormLists have. There are SKSE functions to convert back and forth in one go. Link to comment Share on other sites More sharing options...
TobiaszPL Posted April 3, 2019 Author Share Posted April 3, 2019 Y i know and im gonna do it... but one long function that move objects from FormList to Array is less epic that single Pointer :P Link to comment Share on other sites More sharing options...
Recommended Posts