Networking 101.
Networks aren't magic - for two devices to communicate they have to have different IP addresses, and either:
A. be in the same subnet and connected to the same logical segment, or
B. be in different subnets, but connected via a router that understands the existence of and relationship between subnet 1 and subnet 2
Ignore B (that's way beyond anything you're likely to see in a home network), you need option A.
To be in the same subnet two devices have to have the same subnet mask, and the same address prefix when their IP addresses are ANDed with the subnet mask. If you use a home router / switch with DHCP it sorts this out for you. However, as you don't have a router to do this, you have to manually set the IP address and subnet mask for your Xbox and your PC so they are different, but in the same subnet, otherwise they can't talk to each other.
So, set your Xbox to 192.168.1.10, your PC to 192.168.1.11, subnet mask on both to 255.255.255.0. The prefix is 192.168.1.0 so they are in the same subnet, but the individual addresses are 10 and 11, so they are different, and hence the devices can uniquely address each other.
/Networking 101