void main()
{
    object oArea = GetArea(OBJECT_SELF);
    object oPlayer = GetFirstPC();
    int iStopPoint = GetLocalInt(OBJECT_SELF, "WHEEL_STOP_POINT");
    SendMessageToPC(oPlayer, "Script entered.");
    
    while (GetIsObjectValid(oPlayer))
    {
        if (GetDistanceBetween(OBJECT_SELF, oPlayer) < 10.0) // Assuming 10.0 as the proximity range
        {
            // Delete WHEEL_BET variable
            DeleteLocalInt(oPlayer, "WHEEL_BET");
            SendMessageToPC(oPlayer, "WHEEL_BET variable deleted.");

            // Check for correct WHEEL_BET
            int iBet = GetLocalInt(oPlayer, "WHEEL_BET");
            if (iBet == iStopPoint)
            {
                int iBetAmount = GetLocalInt(oPlayer, "WHEEL_BET_AMOUNT");
                int iReward = iBetAmount * 4;
                // Implement your reward logic here, for example:
                // GiveGoldToCreature(oPlayer, iReward);
                SendMessageToPC(oPlayer, "You won " + IntToString(iReward) + " tickets!");
            }
        }
        oPlayer = GetNextPC();
    }
}