Hi, I am coding a multiplayer board game, similiar to chess...
I need to host an array 10x10 on the server and the client should be able to change things. Like a class with Get and Set, just accessable fron the Home network.

I know nothing about this kind of stuff, so I need a begginer tutorial or even better if you guys can help me :]

Dani AI

Generated

— For a simple turn-based 10x10 board the cleanest pattern is an authoritative server that keeps the board array in memory. Clients send "move" requests; the server validates the move, updates the array, and broadcasts the new state. For beginners building a web client, WebSockets give realtime updates and work in browsers; Socket.IO is a beginner-friendly wrapper. If you prefer simpler request/response logic, use an HTTP REST endpoint and poll occasionally.

A minimal architecture and workflow:

  • Server holds the board (a 10x10 array) and current turn.
  • Client sends messages like "get" (full board) and "move" (proposed move).
  • Server checks legality and turn order, updates the board, then broadcasts an "update" to all clients.

Example pseudocode:

on 'move' message:
  if not legal(move, board, player): send {type:'error', reason:'illegal'}
  apply move to board
  broadcast({type:'update', board: board})

Practical tips: bind the server to 0.0.0.0 or your machine LAN IP to allow other devices on the home network to connect; test locally first with 127.0.0.1. If clients cannot connect, check firewall rules and router port forwarding. Never trust the client for validation — always enforce rules server-side and serialize access (mutexes or a single-threaded event loop) to avoid race conditions. For WebSocket basics see the WebSocket API and for a helpful wrapper see Socket.IO docs. For port-forwarding background see Port forwarding.

bump after 1 day

Some help please :X?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.