I'm the only programmer in a different world~ The knowledge of my previous life, reincarnated and revived, is demon king class. I was abandoned by my family, but I feel like the law of the world liked me. Even if you asked me to come back, it would be too late. Strongest matchless with programmed spells~ - Episode 35 Stove with Fire Power Adjustment, Flash, and Radar
- Home
- I'm the only programmer in a different world~ The knowledge of my previous life, reincarnated and revived, is demon king class. I was abandoned by my family, but I feel like the law of the world liked me. Even if you asked me to come back, it would be too late. Strongest matchless with programmed spells~
- Episode 35 Stove with Fire Power Adjustment, Flash, and Radar
Since I had some free time until the next game, I decided to design a magic tool.
It’s a stove with adjustable heat.
extern void magic_delete(MAGIC *mp);
extern MAGIC *ring_fire_make(float mana);
extern void time_wait(long time_ms);
extern int mclose(MAGIC *mp);
extern void magic_trans(MAGIC *mp);
int slide_touch(MAGIC *mp)
{
int i; /*counter*/
for(i=0;i<mp->magicbufsize;i++){ /*Repeat only the area of the button*/
if(*(mp->magicbuf+i) & TOUCH_ON != 0){ /*Did you touch the button?*/
return(i); /*If touched, return the location*/
}
}
return(0); /*Not touched. return 0*/
}
MAGIC *obj_make(long objsize,int image,int attri)
{
char *obj; /*Magic data*/
MAGIC *mp; /*Magic definition*/
long i; /*Counter*/
obj=(char*)malloc(objsize); /*Secure magic area*/
if(obj == NULL) { /*Security failure In this case, magic power is exhausted*/
exit(EXIT_FAILURE); /*End of processing*/
}
mp=magic_make(obj,objsize,image); /*Make magic*/
for(i=0;i<objsize;i++){
*(&obj[i])=attri; /*Make area a setting attribute*/
}
magic_trans(mp); /*Convert to phenomenon*/
return(mp); /*Return magic information*/
}
void main(void)
{
MAGIC *mp1,*mp2; /* definition of magic */
int onoff,old;
mp1=obj_make(10,IMAGEBLOCK,HOLOGRAPHY); /*Create slide button*/
onoff=0;
while(1){
old=onoff; /*Save previous state*/
onoff=slide_touch(mp1); /*touched slide button*/
if(old!=onoff){ /*Different from previous state*/
if(old==0){ /*Not lit*/
mp2=ring_fire_make(0.00001*onoff);
}
else{ /*The fire is on*/
magic_delete(mp2); /*delete fire*/
if(onoff!=0) mp2=ring_fire_make(0.00001*onoff);
}
}
time_wait(10); /*Wait 0.01 seconds*/
}
mclose(mp1); /*Magic end processing*/
mclose(mp2); /*Magic end processing*/
}
I feel like I’ve put together a long program for the first time in a while.
I don’t think anyone would make such a complicated magic tool.
If this product doesn’t win, I’d like to praise its competitors.
I turned the magical fire into a light and created a light with adjustable brightness.
Well, it looks like it’s my turn.
Your opponent is the emitter.
Explosions are powerful, but magic with high lethality is prohibited.
That magic won’t be able to break through my barrier.
“Sister, do your best!”
“do your best!”
Two children raise their voices.
They look like Emitter’s younger siblings.
“Are you ready? Let’s get started.”
Emitter touched a magic tool.
There was a strong explosion of light, and I couldn’t see well.
But there’s no need to worry.
I made magic so that I can fight even in the dark.
“[Alarm device modification]. Over there [Electric induction]”
Using a radar that was an improved warning magic, the location was determined and an electric shock was fired.
“It just clicked.”
“Winner Tight”
“Sister, I lost.”
“Sister, don’t worry.”
My eyes finally came into sight.
“That’s just me. I didn’t think my trump card wouldn’t work.”
“What is that?”
“I was researching flammable metals and was able to extract it. It’s a soft metal, but it burns well.”
Maybe it’s the magnesium.
As expected of a student at a magic school.
Science is at the cutting edge in this world.
If they win two more times, they will win.
Apparently niobium is also a winner.
Since it’s about him, I don’t know what kind of dirty tricks he’s using.
The fifth day of the ranking match has ended.