Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int roll_skill(const struct char_data *actor,int sact, const struct char_data *resistor, int sres)
- {
- int roll = 0, i, j, whowin;
- int sktot = 0;
- int restot = 0;
- for(i = 0, i < GET_CLASS_RANKS(actor, sact), i++) {
- roll = rand_number(1, 10);
- if (roll > 7)
- sktot += 1;
- }
- for(j = 0, j < GET_CLASS_RANKS(resistor, sres), j++){
- roll = rand_number(1, 10);
- if (roll > 7)
- restot += 1;
- }
- whowin = sktot - restot;
- return whowin;
- }
Add Comment
Please, Sign In to add comment