Raised This Month: $ Target: $400
 0% 

Rate map


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
reinert
Veteran Member
Join Date: Feb 2007
Old 05-07-2011 , 12:05   Re: Rate map
Reply With Quote #9

The server I'm making this plugin for, contains only steamed players.

So I've a rating system with

5 stars,
Quote:
1. #####_[5/5]
2. ####__[4/5]
3. ###___[3/5]
4. ##____[2/5]
5. #_____[1/5]
6. ______[0/5]
I've every star vote count, like
Quote:
5stars - 25votes
4stars - 10votes
3stars - 40votes
2stars - 38 votes
1star - 51 votes
0stars - 19 votes
total = 183 votes.

I would like to show the rating in percents,
Code:
5stars = 25/183*100;
4stars = 10/183*100;
Quote:
1. 5stars ( 13.6% )
2. 4stars ( 5.4% )
PHP Code:
formatex(5stars192"##### ( %1.f%% )"i5 iVoteCount 100.0
I'm doing it like this but percent value is always 0. I don't know why.

Last edited by reinert; 05-07-2011 at 12:21.
reinert is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 04:22.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode