HSP¥Ý¡¼¥¿¥ë
¥µ¥¤¥È¥Þ¥Ã¥× ¤ªÌ䤤¹ç¤ï¤»


HSPTV!·Ç¼¨ÈÄ


̤²ò·è ²ò·è Ää»ß ºï½üÍ×ÀÁ

2012
0924
kohkiinput¤ËÌ¿ÎáÆþÎÏ8²ò·è


kohki

¥ê¥ó¥¯

2012/9/24(Mon) 18:43:42|NO.49526

¤¿¤È¤¨¤Ð¡¢

a=0 input v
¤¬¡¢¤¢¤Ã¤¿¤È¤·¤Æ¡¢
user¤¬input¤Ë¡Öa¡á3¡×
¤ÈÆþÎϤ·¤¿¤È¤·¤Þ¤¹¡£
¤½¤·¤¿¤é¡¢ÊÑ¿ô¤Îa¤Ë3¤òÂåÆþ¤¹¤ë...
Ū¤Ê¤³¤È
¤Ç¤­¤Þ¤»¤ó¤«¤Í¡©
¤´¶µ¼ø¤è¤í¤·¤¯¤ª´ê¤¤¤·¤Þ¤¹m(_ _)m



¤³¤Îµ­»ö¤ËÊÖ¿®¤¹¤ë


@key

¥ê¥ó¥¯

2012/9/24(Mon) 19:06:36|NO.49527

¤½¤â¤½¤âinput¤ËÆþ¤ì¤¿¤â¤Î¤Ï¥×¥í¥°¥é¥àÆâ¤Ç¿ôÎó¤ËÃÖ¤­´¹¤ï¤ë¤Î¤Çʸ»úÎó¤ÏÆþÎϤǤ­¤Þ¤»¤ó
mesbox¤ò»È¤¤¤Þ¤·¤ç¤¦



CON

¥ê¥ó¥¯

2012/9/24(Mon) 19:16:36|NO.49531

´Ö°ã¤¨¤Æ¤¿¤Î¤ÇÄûÀµ

a=0: v="a="+a input v button "ÂåÆþ",*set stop *set split v,"a=",a a=int(a.1) mes "a¤Ë"+a+"¤òÂåÆþ¤·¤Þ¤·¤¿" x="" repeat a:x+="¢£":loop:mes x stop



¤Æ¤ó

¥ê¥ó¥¯

2012/9/24(Mon) 19:18:47|NO.49532

javascript¤Îeval¤Î¤è¤¦¤Ê¤â¤Î¤È¤¤¤¦¤³¤È¤Ç¤è¤í¤·¤¤¤Ç¤·¤ç¤¦¤«¡©

a="1+2+3+4" b=10 c=20 d="b+c" dialog( eval(a) ) //·×»»·ë²Ì¤Î10¤òɽ¼¨¤·¤¿¤¤ dialog( eval(d) ) //·×»»·ë²Ì¤Î30¤òɽ¼¨¤·¤¿¤¤(·×»»¤ËÊÑ¿ô¤â»È¤¨¤ë¡¢¤È¤¤¤¦¤³¤È¡Ë
·×»»¤¬¤·¤¿¤¤¤À¤±¤Ê¤éjavascript¤Îeval´Ø¿ô¤Î¤è¤¦¤Ê¤â¤Î¤òƳÆþ¤¹¤ë¥×¥é¥°¥¤¥ó¤¬¤¢¤Ã¤¿¤È»×¤¤¤Þ¤¹¡£
ÊÑ¿ô¤òÍøÍѤ·¤¿·×»»¤â¤Ç¤­¤¿¤Ï¤º¤Ê¤Î¤Ç¡¢Ãͤò¼èÆÀ¤¹¤ë¤À¤±¤Ê¤é¤³¤ì¤Ç½½Ê¬¤Ç¤·¤ç¤¦¡£

ÌäÂê¤Ï¡¢·×»»¤·¤¿·ë²Ì¤òÊÑ¿ô¤ËÂåÆþ¤¹¤ëÃʳ¬¤Ç¤¹¡£
Î㤨¤Ð

a=0 txt="a=1+2+3" eval txt
¤È¤ä¤Ã¤Æ¤â¡¢ÊÑ¿ôa¤Ë6¤òÂåÆþ¤¹¤ë¤³¤È¤Ï¤Ç¤­¤Þ¤»¤ó¡£

¤³¤ì¤ò²ò·è¤¹¤ë¼ê¤Ã¼è¤êÁᤤÊýË¡¤Ï
­¡splitÌ¿Îá¤Ç·×»»¼°txt¤ò=¤ÎÁ°¸å¤Ëʬ¤±¤ë¡£
­¢Á°È¾¤¬ÂåÆþ¤µ¤ì¤ëÊÑ¿ô¤Î̾Á°¤È¤Ê¤ë¡£
­£¸åȾ¤¬·×»»¼°¤È¤Ê¤ë
­¤¸åȾ¤Î·×»»¼°¤ÎÃͤÏeval»È¤Ã¤Æµá¤á¤Æ¡¢Á°È¾Éôʬ¤Î̾Á°¤Ç¾ò·ïʬ´ô¤·¤¿Àè¤ÇÂåÆþ
¤È¤¤¤Ã¤¿´¶¤¸¤Ç¤·¤ç¤¦¤«¡£
¤³¤ì¤À¤È¡¢ÂåÆþ¤µ¤ì¤ëÊÑ¿ô̾¤¬Í½¤á¤ï¤«¤Ã¤Æ¤¤¤ëɬÍפ¬¤¢¤ê¤Þ¤¹¡£



¤¿¤À¡¢¥¤¥ó¥¿¥×¥ê¥¿¸À¸ì¤Ç¤¢¤ë°Ê¾å¡¢´èÄ¥¤ì¤Ð¤Ç¤­¤Ê¤¯¤â¤Ê¤¤µ¤¤¬¤·¤Þ¤¹¤¬¤½¤³¤Þ¤Ç¤ä¤ë¤°¤é¤¤¤Ê¤éÊ̤ÎÊýË¡¤ò¹Í¤¨¤¿¤Û¤¦¤¬¤¤¤¤µ¤¤¬¤·¤Þ¤¹¡£



¤Æ¤ó

¥ê¥ó¥¯

2012/9/24(Mon) 19:22:20|NO.49534

input¤Ç¤âʸ»úÎó¤òÆþÎϤǤ­¤Þ¤¹¤è¡£¥Þ¥ë¥Á¥é¥¤¥ó¤ËÂбþ¤·¤Æ¤¤¤Ê¤¤¤È¤¤¤¦ÅÀ¤¬mesbox¤È¤Î°ã¤¤¤Ç¤¹¡£

sdim txt, 64 : input txt, 100, 20 button gosub "ɽ¼¨", *push stop *push dialog txt return
¥Ý¥¤¥ó¥È¤Ïinput¤ÇÍѤ¤¤ë¥Ð¥Ã¥Õ¥¡ÊÑ¿ô¤òͽ¤á»ÈÍѤ·¤¿¤¤·¿¡Ê¿ôÃÍorʸ»úÎó)¤Ç½é´ü²½¤·¤Æ¤ª¤¯¤³¤È¤Ç¤¹¤Í¡£



¤Æ¤ó

¥ê¥ó¥¯

2012/9/24(Mon) 23:28:28|NO.49544

¤Þ¤¿¤¤¤é¤Ì¥â¥¸¥å¡¼¥ë¤ò¤Ä¤¯¤Ã¤Æ¤·¤Þ¤Ã¤¿¡£(¡­¡¦¦Ø¡¦¡®)
¤³¤¦¤¤¤¦°ì¸«ÉÔ²Äǽ¤½¤¦¤Ê¤³¤È¤Û¤É¡¢Ç³¤¨¤ë¤ó¤Ç¤¹¤è¤Í¡£


//=================================================================== // ÊÑ¿ô̾¤òÍøÍѤ·¤ÆÊÑ¿ô¤Ë¥¢¥¯¥»¥¹¤¹¤ë¥â¥¸¥å¡¼¥ë //=================================================================== // // name = getvn(v1) // ÊÑ¿ô¤Î̾Á°¤ò¼èÆÀ¤¹¤ë // v1 : ÊÑ¿ô // // ÊÑ¿ôv1¤Î¥¹¥¯¥ê¥×¥È¾å¤Ç¤Î̾Á°¤ò¼èÆÀ¤·¤Þ¤¹¡£ // Âçʸ»ú¤ÏÁ´¤Æ¾®Ê¸»ú¤ËÊÑ´¹¤µ¤ì¤Þ¤¹¡Ê¸À¸ì»ÅÍÍ¡Ë¡£ // //------------------------------------------------------------------- // // dupptr_byname v1, name // »ØÄꤷ¤¿Ì¾Á°¤ÎÊÑ¿ô¤Î¡¢¥¯¥í¡¼¥óÊÑ¿ô¤òºîÀ®¤¹¤ë // v1 : ¥¯¥í¡¼¥ó¤Ë¤¹¤ëÊÑ¿ô // name: ¥¯¥í¡¼¥óÂоݤÎÊÑ¿ô̾ // // name¤Ç»ØÄꤷ¤¿Ì¾Á°¤ÎÊÑ¿ô¤Î¡¢¥¯¥í¡¼¥óÊÑ¿ô¤òºîÀ®¤·¤Þ¤¹¡£ // »ØÄꤷ¤¿Ì¾Á°¤ÎÊÑ¿ô¤¬¡¢¥¹¥¯¥ê¥×¥ÈÆâ¤Ç // ͽ¤áÄêµÁ¤µ¤ì¤Æ¤¤¤ëɬÍפ¬¤¢¤ê¤Þ¤¹¡£ // // Ìá¤êÃÍ // 0 : À®¸ù // 1 : ¼ºÇÔ // //=================================================================== //¥â¥¸¥å¡¼¥ë¤³¤³¤«¤é¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§¢§ #uselib "user32" #func global CharLowerA "CharLowerA" sptr #module VNGetter #deffunc local init_getvn if f_init : return 0 f_init = 1 logmes "======================================" logmes "³°Éô¤«¤é¤ÎÆâÉôÊÑ¿ô¥¢¥¯¥»¥¹Íѥ⥸¥å¡¼¥ë" logmes "¡¡VNGetter" logmes "--------------------------------------" logmes "Date: 2012/09/24" logmes "Author: ¤Æ¤ó" logmes "======================================" exist "obj" if strsize < 0 { logmes "obj¥Õ¥¡¥¤¥ë¤¬¸«¤Ä¤«¤é¤Ê¤¤¤Ç¤¹¡£" logmes "²òÀϤòÃÇÇ°¤·¤Þ¤¹¡£(¡­¡¦¦Ø¡¦¡®)Ž¼Ž®ŽÎŽÞŽ°ŽÝ¡Ä" f_init = 0 return 1 } sdim buf, strsize : bload "obj", buf max_val = lpeek(buf, 8) pt_ds = lpeek(buf, 24) max_ds = lpeek(buf, 28) pt_dinfo = lpeek(buf, 40) max_dinfo = lpeek(buf, 44) sdim DebugInfo, max_dinfo memcpy DebugInfo, buf, max_dinfo, 0, pt_dinfo sdim DataSection, max_ds memcpy DataSection, buf, max_ds, 0, pt_ds logmes "DataSection: "+strf("$%04X", pt_ds)+" - "+strf("$%04X", pt_ds+max_ds) logmes ""+max_val+"¸Ä¤ÎÊÑ¿ô¤ò»ÈÍÑ" logmes "--------------------------------------" sdim varnames, 64, max_val i = 0 repeat max_dinfo char = peek(DebugInfo, cnt) if char = 255 : break if char = 254 : continue cnt+1+3+2 if char = 253 { offset = lpeek(DebugInfo, cnt+1) & 0x00FFFFFF getstr varnames(i), DataSection, offset, $00 i++ continue cnt+1+3+2 } if char == 252 : continue cnt+1+2 loop repeat max_val logmes "ID:"+strf("%03d", cnt)+" "+varnames(cnt) loop return 0 #defcfunc local getvid var v1 v1_pt = varptr(v1) mref HSPCTX, 68 sdim Mem_var, 29 dupptr Mem_var, lpeek(HSPCTX, 44), max_val*48 res = -1 repeat max_val v2_pt = lpeek(Mem_var, cnt*48+28) if v1_pt = v2_pt : res=cnt : break loop return res #defcfunc getvn var v1 id = getvid(v1) if id = -1 : return "NOT FOUND" return varnames(id) #deffunc dupptr_byname var v1, str s1 s2 = s1 : CharLowerA varptr(s2) id = -1 repeat max_val if varnames(cnt) = s2 : id = cnt : break loop if id = -1 : dialog "NOT FOUND" : return 1 mref HSPCTX, 68 sdim Mem_var, 29 dupptr Mem_var, lpeek(HSPCTX, 44), max_val*48 dupptr v1, lpeek(Mem_var, id*48+28), lpeek(Mem_var, id*48+24), wpeek(Mem_var, id*48) return 0 #global init_getvn@VNGetter //¥â¥¸¥å¡¼¥ë¤³¤³¤Þ¤Ç¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥¢¥ //--------------------°Ê²¼¡¢¥µ¥ó¥×¥ë---------------------------------------------------- #const BASE_X 400 #const BASE_Y 320 screen 0, BASE_X, BASE_Y title "ÊÑ¿ô̾¤ò»È¤Ã¤¿ÊÑ¿ô¤Î´ÉÍý" font "¥á¥¤¥ê¥ª", 12 color $F0, $F0, $F0 : boxf color pos 20, 15 : mes "ÂåÆþ¼°( [ÊÑ¿ô̾]=[ÃÍ] ¤Î·Á¼°¡¡¶õÇò¡¦¿ô¼°ÉÔ²Ä )" objsize 70, 25 pos BASE_X-90, 10 : button gosub "ÂåÆþ", *parse sdim txt, 64 : txt = "a=30" : pos 20, 40 : input txt, BASE_X-40, 20 pos 20, 75 : mes "Ãͤò³Îǧ¤·¤¿¤¤ÊÑ¿ô¤Î̾Á°" sdim v_name, 64 : v_name="a" : pos ginfo_mesx+30, 75 : input v_name, BASE_X-(ginfo_mesx+50), 20 objsize BASE_X-40, 50 pos 20, 130 : button gosub "Ãͤò³Îǧ", *push color $60, $60, $60 : boxf 20, 190, BASE_X-20, BASE_Y-20 color $C0, $F0, $FF : pos 30, 200 mes "¥¹¥¯¥ê¥×¥ÈÆâ¤ÇÄêµÁ¤µ¤ì¤Æ¤¤¤ëÊÑ¿ô¤Ë¤·¤«»ÈÍѤǤ­¤Þ¤»¤ó¡£" mes "Îã¤È¤·¤Æ a, b, c, d, e, f ¤Î6¤Ä¤ÎÊÑ¿ô¤òÄêµÁ¤·¤Æ¤ª¤­¤Þ¤·¤¿¡£" mes "\ta=30" mes "\tb=20 mes "¤Ê¤É¡¢»î¤·¤Æ¤ß¤Æ²¼¤µ¤¤¡Ê½é´üÃͤÏÁ´¤Æ10¤Ë¤Ê¤Ã¤Æ¤¤¤Þ¤¹¡Ë¡£" a=10 : b=10 : c=10 d=10 : e=10 : f=10 stop *parse split txt, "=", args //args(0)¤ËÊÑ¿ô̾¡¢args(1)¤ËÃͤ¬Æþ¤Ã¤Æ¤¤¤ë¡£ //ÊÑ¿ôv¤ò¡¢¡Öargs(0)¤Ç»ØÄꤵ¤ì¤¿Ì¾Á°¤ÎÊÑ¿ô¡×¤Î¡¢¥¯¥í¡¼¥óÊÑ¿ô¤Ë¤¹¤ë dupptr_byname v, args(0) //v¤ØÂåÆþ¡£¤³¤ì¤Ç¡Öargs(0)¤Ç»ØÄꤵ¤ì¤¿Ì¾Á°¤ÎÊÑ¿ô¡×¤ËÃͤ¬ÂåÆþ¤µ¤ì¤¿¤³¤È¤Ë¤Ê¤ë¡£ v = int(args(1)) //¼°¤Îºï½ü txt = "" : objprm 1, txt return *push //ÊÑ¿ôv¤ò¡¢¡Öv_name¤Ç»ØÄꤵ¤ì¤¿Ì¾Á°¤ÎÊÑ¿ô¡×¤Î¡¢¥¯¥í¡¼¥óÊÑ¿ô¤Ë¤¹¤ë dupptr_byname v, v_name if stat : return //¼ºÇԡʤª¤½¤é¤¯¡¢»ØÄꤷ¤¿Ì¾Á°¤ÎÊÑ¿ô¤¬Â¸ºß¤·¤Ê¤«¤Ã¤¿¤³¤È¤Ëµ¯°ø¡Ë dialog v_name+"¤ÎÃͤÏ"+v return



3k

¥ê¥ó¥¯

2012/9/25(Tue) 01:35:40|NO.49545

HSPÆâ¤ÇưŪ¤Ë¥¹¥¯¥ê¥×¥È¤ò¼Â¹Ô¤·¤¿¤¤or·×»»¤µ¤»¤¿¤¤¡¢¤È¤¤¤¦»Ý¤Î¥¹¥ì¤ÏÄê´üŪ¤Ë½Ð¸½¤·¤Æ¤ëµ¤¤¬¤·¤Þ¤¹¤Í¡Ä¡£

ËÜÍè¤Ê¤é¤Ð¥¹¥¯¥ê¥×¥È¸À¸ì¦¤¬eval¤Î¤è¤¦¤Ê¤â¤Î¤ò¼ÂÁõ¤¹¤ë¤Î¤òÂԤĤ٤­¤À¤È»×¤¤¤Þ¤¹¤¬¡¢¸½¾õ¤ò´Õ¤ß¤ë¤Ë¤½¤ì¤ÏÂçʬÀè¤Ë¤Ê¤ê¤½¤¦¤Ê¤Î¤Ç¡Ä¡£
¡¡¡ÊEXE²½¤¹¤ë¤È¤­¤ËÊÑ¿ô̾¤ä´Ø¿ô̾¤Î¾ðÊ󤬺ï½ü¤µ¤ì¤ë¡¢Ãæ´Ö¥³¡¼¥É¤òÀ¸À®¤¹¤ë¥³¡¼¥É¤¬ÉÕ°¤·¤Ê¤¤¡¢Åù¡Ë


²áµî¤Ë¤â´ö¤Ä¤«¡Ê¡©¡Ë¼ÂÁõ¤Î»î¤ß¤¬¤¢¤ê¡¢»ä¤¬³Ð¤¨¤Æ¤¤¤ë¸Â¤ê¤Ç°ìÈֿʤó¤Ç¤¤¤¿¤Î¤Ï

¡¡HSP³«È¯Wiki¡¡¡ÖMath/ʸ»úÎ󲽤·¤¿¿ô¼°¤ÎȽÊÌ¡×
¡¡http://hspdev-wiki.net/?Math%2F%CA%B8%BB%FA%CE%F3%B2%BD%A4%B7%A4%BF%BF%F4%BC%B0%A4%CE%C8%BD%CA%CC

¤Ê¤ó¤¸¤ã¤Ê¤¤¤«¤Ê¡¢¤È»×¤¤¤Þ¤¹¡£
ºÇ¸å¤Ë¥ê¥ê¡¼¥¹¤µ¤ì¤¿¥Ð¡¼¥¸¥ç¥ó¤Ç¤ÏHSP¤Îʸˡ¸ß´¹¤Ç´Êñ¤Ê·×»»¤¬¤Ç¤­¤ë¤â¤Î¤Ë¤Ê¤Ã¤Æ¤¤¤¿¤«¤È¡£

Åö»þ»ä¤È¤·¤Æ¤Ï¤«¤Ê¤ê´üÂÔ¤·¤ÆÂԤäƤ¤¤¿¤Î¤Ç¤¹¤¬¡¢»ÄÇ°¤Ê¤¬¤é³«È¯¤ÎÊý¤Ïº£Ää»ß¤·¤Æ¤·¤Þ¤Ã¤Æ¤¤¤ë¤è¤¦¤Ç¤¹¤Í¡Ä¡£
¤´»²¹Í¤Þ¤Ç¤Ë¡£



>¤Æ¤ó¤µ¤ó

¤³¤Î¥¹¥¯¥ê¥×¥È¡¢À¨¤¤¤Ç¤¹¤Í¡ª
¤Þ¤µ¤«obj¥Õ¥¡¥¤¥ë¤òÆɤ߼è¤Ã¤ÆÊÑ¿ô¤òÆɤ߽Ф¹¤È¤Ï¡Ä¡£

¤¿¤À¡¢a¤ò¿ôÃÍ·¿°Ê³°¤ÎÊÑ¿ô¤Ë¤·¤Æ¤·¤Þ¤¦¤È¡¢ÂåÆþ¤¬¤¦¤Þ¤¯¤¤¤«¤Ê¤¤¡Ê¡©¡Ë¤ß¤¿¤¤¤Ç¤¹¡£
¿ʬdup·Ï¼þÊÕ¤ÎÆ°ºî¤À¤È»×¤ï¤ì¤Þ¤¹¤¬¡£


//a = 0.0// ¤³¤¦¤¹¤ë¤ÈÂåÆþ¤µ¤ì¤Ê¤¤¡Á dup b, a b = 20 dialog "a="+a
»ÅÍͤʤó¤Ç¤¹¤«¤Í¡¢¤Ã¤Ý¤¤¤Ç¤¹¤¬¡£



KA

¥ê¥ó¥¯

2012/9/25(Tue) 06:10:39|NO.49546


A=0 B="A=3" input B C=strmid(B,0,1) if C="A" : D=strmid(B,2,1) A=D mes A
¤³¤ó¤Ê´¶¤¸¤«¤È



kohki

¥ê¥ó¥¯

2012/9/25(Tue) 07:10:40|NO.49549

¤ª¤ª¤ª
¤Ê¤ó¤À¤«¤¹¤´¤¤¤³¤È¤Ëwww
³§¤µ¤ó¤Î¤¤¤Ã¤Æ¤ë¤³¤È¤òÍý²ò¤¹¤ë¤À¤±¤Ç°ì¶ìÏ«¤Ç¤¹...ww
¤ï¤¶¤ï¤¶¥â¥¸¥å¡¼¥ë¤Þ¤Çºî¤Ã¤Æ¤¤¤¿¤À¤¤¤Æ¡¢¤¢¤ê¤¬¤È¤¦¤´¤¶¤¤¤Þ¤¹m(_ _)m
¤³¤ì¤Ç¡¢Â³¤­¤¬ºî¤ì¤Þ¤¹w



ONION software Copyright 1997-2023(c) All rights reserved.