what is this?

Everything technical and nerdy stuff here plz !

what is this?

Postby SteveMcqueen » 06.25.09

1mapcyle.jpg
(4.4 KiB) Downloaded 8162 times
SteveMcqueen
 

Re: what is this?

Postby wurst » 06.25.09

ah good that u ask, i normally wanted to ask that blinky just but when u ask ok:

theres a green and a red dot.
if user has voted there should be shown green, else red.
yesterday ana told me: wow i have there a green AND a red button.

hm?
but the script was like "!= 1" and "= 1" for the one or the other image.
a look in the database showed me that the values are stored as binary, the table cells contain "0x30" or "0x31"
so i started to monitor the output of the php by calling the same again, just writing "echo" in front of it.

so the secret is: its debuging.

btw:
oki np i thought: php bindec() will translate me that.
hah! it gives me 49! (whatever 49 may mean now)

the value btw get called through the phpbb as allways in phpbb, the data is a column in phpbb_users table.
i must look what the phpbb does there with the database query since in plain sql i can say him "where user_voted = '0x31'
Image
User avatar
wurst
Godlike
 
Posts: 4648
Joined: 07.15.08
Location: Behind U
-----tdm:  
nick: [dswp]GewitterOma
skill: 1122.83
kills: 25960
deaths: 19847
ratio: 1.30
-----bomb:  
nick: [dswp]GewitterOma
skill: 812.172
kills: 3885
deaths: 3541
ratio: 1.09

Re: what is this?

Postby SteveMcqueen » 06.25.09

now i have a blinking red dot in front of a "1"....


OFFTOPIC: ich bin noch orange weil mit rechte = 100 gamemode wechseln geht und ich so sehen kann wie train in den modes mit der flagge läuft. und in CAH ists mal wirklich ultra gut geworden....... tobi war mit aufm server, so wie unser lieblingsfranzose svarox. zu CTF kann ich noch nicht soo viel sagen.
SteveMcqueen
 

Re: what is this?

Postby SteveMcqueen » 06.25.09

flashing red 00
SteveMcqueen
 

Re: what is this?

Postby wurst » 06.25.09

hehe.

oki for reminding:
Code: Select all
   <!-- PHP -->
  $voted = ((int)$user->data['voted_for_maps']);
  //debug :)
  //echo $voted;
   if ($voted > "0" ) echo "<img border="0" src="./images/icons/user_voted.gif" ></font>";
  if ($voted < "1" ) echo "<img border="0" src="./images/icons/user_not_voted.gif" ></font>";
  //mit != / = funktionierts komischerweise trotzdem nicht...
   <!-- ENDPHP -->


the funny thing is that i get with that an output of 1/0 for voted/not voted but i cant work with = and !=
greater then works, so we have "bigger then 0" for voted and "smaller then 1" for non- voters...
Image
User avatar
wurst
Godlike
 
Posts: 4648
Joined: 07.15.08
Location: Behind U
-----tdm:  
nick: [dswp]GewitterOma
skill: 1122.83
kills: 25960
deaths: 19847
ratio: 1.30
-----bomb:  
nick: [dswp]GewitterOma
skill: 812.172
kills: 3885
deaths: 3541
ratio: 1.09

Re: what is this?

Postby AimMe » 06.25.09

I've got only green dot.
Image
User avatar
AimMe
Godlike
 
Posts: 2318
Joined: 09.28.08
Location: Solar System

Re: what is this?

Postby wurst » 06.25.09

did u mapvote allready?

if yes, it should be Image
if no, it should be Image

btw im looking forward to mark important things with this flashing dots, anyone got an opinion on that?

---------edit---------
i included little map images with the check boxes, im sry u cant test it till friday, hope you enjoy...

mapcycle_design.jpg
Image
User avatar
wurst
Godlike
 
Posts: 4648
Joined: 07.15.08
Location: Behind U
-----tdm:  
nick: [dswp]GewitterOma
skill: 1122.83
kills: 25960
deaths: 19847
ratio: 1.30
-----bomb:  
nick: [dswp]GewitterOma
skill: 812.172
kills: 3885
deaths: 3541
ratio: 1.09

Re: what is this?

Postby XTJ7 » 06.25.09

Why don't you just work with if and else? If you are able to make only the green dot appear, why not work with else instead? :D
<XTJ7> !penis
<CuntBot> XTJ7, your penis is 23.3 cm long. 8=========D
<XTJ7> !8ball do i rock?
<CuntBot> XTJ7: OH YEAH !
<BEH> !8ball you lieing too?
<CuntBot> BEH: Totally not.
<BEH> -_-''
User avatar
XTJ7
Kanzlerin
 
Posts: 1063
Joined: 07.24.08
Location: Germany
-----tdm:  
nick: [dswp]xtj7
skill: 753.35
kills: 98
deaths: 95
ratio: 1.03

Re: what is this?

Postby AimMe » 06.25.09

I did vote and it is OK.
Image
User avatar
AimMe
Godlike
 
Posts: 2318
Joined: 09.28.08
Location: Solar System

Re: what is this?

Postby wurst » 06.25.09

hm cause there could be another state in future i thought.
dunno its blinkys moped i wanna just not to cross his plans...

btw. if/else didnt workout too.
now where i call (int) of that value i get a 0/1 result.
if = 1 bring me both, if = 0 too, else just bring me the first one cause allways valid somehow...

whatever, if u like look it, id like to understand what goes on with the bin value.
to define 1 as > 0 is ok but i think to say 1=1 is no basically new thing...
Image
User avatar
wurst
Godlike
 
Posts: 4648
Joined: 07.15.08
Location: Behind U
-----tdm:  
nick: [dswp]GewitterOma
skill: 1122.83
kills: 25960
deaths: 19847
ratio: 1.30
-----bomb:  
nick: [dswp]GewitterOma
skill: 812.172
kills: 3885
deaths: 3541
ratio: 1.09

Next

Who is online

Users browsing this forum: No registered users and 23 guests

Misc

cron