~ubuntu-branches/ubuntu/raring/rss-glx/raring

« back to all changes in this revision

Viewing changes to src/PixelCity/Random.h

  • Committer: Bazaar Package Importer
  • Author(s): Fabrice Coutadeur
  • Date: 2010-07-22 06:50:37 UTC
  • mfrom: (1.1.6 upstream) (2.2.4 sid)
  • Revision ID: james.westby@ubuntu.com-20100722065037-094eshi3ljwbtfa1
Tags: 0.9.1-3ubuntu1
* Merge from Debian unstable (LP: #604945). Remaining changes:
  - Added an apport package hook
  - Changed libgl1-mesa-swx11-dev to libgl1-mesa-dev in Build-Depends
* Dropped changes:
  - Drop dependency on openal. As the package is in universe now, it's not 
    mandatory anymore
  - src/skyrocket.{cpp,xml}: Disable sound by default. Same reason.
  - Add --disable-sound configure flag to debian/rules. Same reason.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#ifndef _RANDOM_H_
 
2
#define _RANDOM_H_
 
3
 
 
4
#include <stdlib.h>
 
5
 
 
6
#define COIN_FLIP     (RandomVal (2) == 0)
 
7
 
 
8
inline long int RandomVal (long int range) { return range ? random() % range : 0; }
 
9
inline long int RandomVal (void) { return random(); }
 
10
 
 
11
#endif