I had been having low storage issues on my root partition so I tried out some cleaning advice from this forum, including (Root drive is running out of disk space. How can I free up space?) and also (https://maryrosecook.com/blog/post/freeing-disk-space-on-your-linux-server), and the following ordered list of (I realised, dangerous) commands:
apt-get autoclean
sudo du -sh /var/cache/apt/archives
sudo apt-get autoremove --purge
sudo rm -rf ~/.cache/thumbnails/*
sudo du -h --max-depth=1
dpkg -l 'linux-*' | sed '/^ii/!d;/'"$(uname -r | sed "s/\(.*\)-\([^0-9]\+\)/\1/")"'/d;s/^[^ ]* [^ ]* \([^ ]*\).*/\1/;/[0-9]/!d' | xargs sudo apt-get -y purge
sudo dpkg -l 'linux-*' | sed '/^ii/!d;/'"$(uname -r | sed "s/\(.*\)-\([^0-9]\+\)/\1/")"'/d;s/^[^ ]* [^ ]* \([^ ]*\).*/\1/;/[0-9]/!d' | xargs sudo apt-get -y purge
sudo dpkg -l 'linux-*' | sed '/^ii/!d;/'"$(uname -rm | sed "s/\(.*\)-\([^0-9]\+\)/\1/")"'/d;s/^[^ ]* [^ ]* \([^ ]*\).*/\1/;/[0-9]/!d' | xargs sudo apt-get purge
sudo shutdown -rf
In particular, I think what messed things up was the long 'sudo dpkg...' command, which is supposed to remove old kernels; I think it could've removed the kernel and some important drivers.
Now, I have a dual windows boot, but my grub has disappeared, in the sense that it automatically goes to ubuntu(even though i can access windows through F2 bios); to try and fix the kernel, I followed (How to restore a system after accidentally removing all kernels?) with little success, meaning linux-image-generic is installed now but that didn't fix things.
The experienced issues in Ubuntu are:
-Screen Resolution stuck at 800x600
-Not recognising any internet peripherals, including internal wifi, external wifi adapter, ethernet
-touchpad not working
--The rest of the system is working, it seems.
other solutions i could try are using the boot-repair tool, but without internet i don't know how to install it(same with removed packages although i might be able to do that from live usb), and i am not sure how to use it/whether that could help.
Also, should I try following the answer in (How to restore deleted files in /boot? (vmlinuz missing, system does not boot))?
P.S. I have home and root folders on separate partitions